The Un-Named
2006-03-14 07:14:26
I'm making an auto fighter and getting an error.
Failed when compiling
Line 29: [Error] (9029:10): Assignment expected in script C:\*****\*****\Desktop\NoobFighter.scar
The part is this:
repeat
Time:=Time+1
RandomNPC;
until(Time=Random(200))
All I think it needs is somthing to do to add 1 to Time but not sure what to put/do.
I've tried somthing like Wait(1, Time:-Time+1) but with no success. All I want from this is to wait 1, then add 1 to time until time is a random number upto 200.
I've fixed it with this:
begin
Time:=0
repeat
Wait(1)
Time:=Time+1
until(Time=Random(50)) //This could be any number but I wanted it 50 insted of 200 now
end;
Failed when compiling
Line 29: [Error] (9029:10): Assignment expected in script C:\*****\*****\Desktop\NoobFighter.scar
The part is this:
repeat
Time:=Time+1
RandomNPC;
until(Time=Random(200))
All I think it needs is somthing to do to add 1 to Time but not sure what to put/do.
I've tried somthing like Wait(1, Time:-Time+1) but with no success. All I want from this is to wait 1, then add 1 to time until time is a random number upto 200.
I've fixed it with this:
begin
Time:=0
repeat
Wait(1)
Time:=Time+1
until(Time=Random(50)) //This could be any number but I wanted it 50 insted of 200 now
end;