mirror of
https://gitlab.com/lunovox/e-urn.git
synced 2025-03-15 07:21:22 +00:00
75 lines
1.7 KiB
Lua
75 lines
1.7 KiB
Lua
modEUrn.FormSpecs = {
|
|
showHypertext = function(playername)
|
|
--Fonte:
|
|
-- * https://minetest.gitlab.io/minetest/formspec/
|
|
-- * https://minetest.gitlab.io/minetest/formspec/#hypertextxywhnametext
|
|
-- * https://github.com/minetest/minetest/blob/master/doc/lua_api.md
|
|
local myFormSpec = ""
|
|
myFormSpec = myFormSpec
|
|
--.."formspec_version[5.6.0]"
|
|
.."formspec_version[6]"
|
|
.."size[16,8,false]"
|
|
.."background[0,-8;16,16;text_eurn_front.png]"
|
|
--.."bgcolor[000000;false;FFFFFF]"
|
|
--.."bgcolor[#00880044;false;#000000]"
|
|
--.."bgcolor[#636D7600;true]"
|
|
--.."position[0,0]"
|
|
--.."container[0,0]"
|
|
--.."image[0,-8;16,16;text_eurn_front.png]"
|
|
.."vertlabel[15.75,0.5;"..minetest.formspec_escape(modEUrn.translate("E-URN")).."]"
|
|
.."hypertext[0.5,0.5;15,7;myPage;"
|
|
--..minetest.formspec_escape("<global margin=10 valign=0 color=#FF00FF hovercolor=#00FFFF size=12 font=normal halign=center >")
|
|
.."<global valign=middle halign=left margin=10 background=#FFFFFFCC color=#000000 hovercolor=#00FF00 size=12 font=normal>"
|
|
.."<tag name=action color=#FF0000 hovercolor=#00FF00 font=normal size=12>"
|
|
..minetest.formspec_escape(([[
|
|
|
|
|
|
|
|
<center>
|
|
<img name=favicon.png float=center width=96 height=96>
|
|
<style font=mono color=#FF0000 size=24><b>OLÁ %s!</b></style>
|
|
</center>
|
|
|
|
Esse é um <action name=lnkExemplo1><item name=default:sword_wood valign=middle width=14 height=14> Exemplo de Link</action> em formato hyperlink. (Não é funcional!)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<center>
|
|
-= Fim =-
|
|
<bigger>=D</bigger>
|
|
</center>
|
|
|
|
]]):format(playername:upper()))
|
|
.."]" -- Fim de hypertext[]
|
|
--.."container_end[]"
|
|
|
|
|
|
|
|
|
|
--"hypertext[<X>,<Y>;<W>,<H>;<name>;<text>]"
|
|
minetest.show_formspec(playername, "frmEUrnInit", myFormSpec)
|
|
end,
|
|
}
|