Stormworks - Lua GPS Display Tutorial
4.6 هزار بار بازدید -
پارسال
-
This guide will show you
This guide will show you how to create a display that will output your current GPS coordinates using LUA.
This is the LUA code used in the tutorial.
function onTick()
gpsx = input.getNumber(1)
gpsy = input.getNumber(2)
end
function onDraw()
w = screen.getWidth()
h = screen.getHeight()
screen.setColor(0, 255, 0)
screen.drawTextBox(2,2,w,h,string.format("X:%.f\nY:%.f", gpsx, gpsy))
end
This is the LUA code used in the tutorial.
function onTick()
gpsx = input.getNumber(1)
gpsy = input.getNumber(2)
end
function onDraw()
w = screen.getWidth()
h = screen.getHeight()
screen.setColor(0, 255, 0)
screen.drawTextBox(2,2,w,h,string.format("X:%.f\nY:%.f", gpsx, gpsy))
end
پارسال
در تاریخ 1402/04/09 منتشر شده
است.
4,684
بـار بازدید شده