Discuss Scratch

Tr43212
Scratcher
24 posts

Bot moving

I'm make a shooting game with a bot but i don't know how to make a bot move and shoot
ForegoingAZA909
Scratcher
52 posts

Bot moving

I'm not sure if this will help entirely because I don't know how much of your project you've finished yet (like if you've already coded shooting) but assuming you have, try a
point towards [sprite v]

when I receive [cool idea v]
if <(pick random (1) to (2)) = [1]> then
set [ambition v] to [99999]
wait (1) weeks
set [motivation v] to [0]
end
Hi! I'm ForegoingAZA909, who also goes by names such as: Fore, AZA, 909 (by like, one guy), ToaSt, Storyboard, ToaSb (???), and more(probably).
Scratchsanity
Scratcher
9 posts

Bot moving

For the movement:
point towards [ mouse-pointer]
Scratchsanity
Scratcher
9 posts

Bot moving

And for the shooting create a new sprite called enemy bullet and put this code:
when green flag clicked

[forever
wait (3) secs
create clone of [ myself]
end]

[when I start as a clone
point towards [Player]
move (2) steps
if <touching [ player or edge] ?> then
delete this clone
end]

Then in the player sprite put If touching enemy bullet then die

Powered by DjangoBB