Let me preface by saying that I have no experience in coding, aside from basics. As I am sure everyone has been at one point, I don't even know how to learn it. Is the docs provided in Leadwerks enough for the non programmer to learn? Do I need to learn Lua outside of leadwerks in order to learn to script within it? I ask this loosely as I know that knowledge is king. If I base my learning purely off the script documentation provided, is that enough to make a game?
Example of my current headache regarding set input.
function Script:Start()
self.camera = Camera:Create()
self:UpdateCamera()
player = Pivot:Create()
end
function Script:UpdatePhysics()
local jump = ((window:KeyDown(Key.Space) and 1 or 0))
player:SetInput(0,jump)
end
function Script:UpdateCamera()
self.camera:SetRotation(20,90,0)
self.camera:SetPosition(self.entity:GetPosition())
self.camera:Move(0,0,-3)
end
function Script:UpdateWorld()
self:UpdateCamera()
end
Looking at the the documentation, the example code for SetInput shows the player, world, and controls being created via script, rather than using a model and the editor to create the world. I struggle with understanding how to implement it to work with created models. As you guys would probably be able to understand why, the above code is incorrect. I'm sure its simple, but even the most simple task is a nightmare for me. I've wanted to learn to script for over a decade and have made numerous attempts to make sense of it all. The internet is flooded with resources for learning, but that even seems to make it even more overwhelming. I once had a friend who was a coder and for a short time he was great at helping me with trying to learn, but unfortunately he passed away.
I appreciate in advance for your responses.