Code: function onInit() font = rpg.graphics.newFont("Picture/font.png") windowSkin = rpg.graphics.newWindowSkin("Picture/windowskin.png") end function onFrame() if rpg.scene == "map" then local text = "Hello, my name is " .. rpg.map.hero.name .. "!" local textWidth = font:getStringWidth(text) local x, y = rpg.map.hero:getScreenPosition() rpg.graphics.drawWindow(windowSkin, x - 80, y - 60, textWidth, font.maxCharHeight) rpg.graphics.drawText(font, x - 80, y - 60, text) end end Coming soon...
function onInit() font = rpg.graphics.newFont("Picture/font.png") windowSkin = rpg.graphics.newWindowSkin("Picture/windowskin.png") end function onFrame() if rpg.scene == "map" then local text = "Hello, my name is " .. rpg.map.hero.name .. "!" local textWidth = font:getStringWidth(text) local x, y = rpg.map.hero:getScreenPosition() rpg.graphics.drawWindow(windowSkin, x - 80, y - 60, textWidth, font.maxCharHeight) rpg.graphics.drawText(font, x - 80, y - 60, text) end end
Geändert von Kyuu (23.02.2014 um 19:16 Uhr)
Foren-Regeln