i have tried to find out whats causing the error but i cant figure it out. it says that it wants an = sign near end but when i put it there its says that an unexpected symbol is there. (my code may be fairly messy so any extra clean up help would be good as well). tbh it might not even do what its supposed to do to begin with but what ive managed to do so far before this error was like 90% of what i wanted.
function update(self, dt)
self.input.x = 0
self.input.y = 0
local seed = math.random(6 * 10)
local mov = math.random(1 * 4)
local timeeer = timer.delay(0.5, true, function(self)
local xpos = math.random(1 * 4)
local ypos = math.random(1 * 4)
local xposb = math.random(1 * 4)
local yposb = math.random(1 * 4)
local tim = timer.delay(seed, true, function(self)
for i=1, mov do
if mov == 1 then
self.input.y = ypos
elseif mov == 2 then
self.input.y = -yposb
elseif mov == 3 then
self.input.x = -xposb
elseif mov == 4 then
self.input.x = 1 xpos
= end
local pos = go.get_position()
pos = pos + self.dir * self.speed * dt
go.set_position(pos)
end
end)
end)
end