Can I use wander?
SLOCM3Z
Member Posts: 797
I was building my game the other day and was wondering if there is a way to make a npc(non-playing character) wander around and throw things like grenades. Anything to the effect of wander would be great. Thanks
Comments
Sure you can
Wander is just a word though... When you go to approach the system you'll want to think more about the specifics. Such as does it wander on just x or x+y. Is it 100% random, or does it need to be within certain positions or constraints, how often does it change directions, how often does it throw grenades, is there a follow like state, or just wander, etc.
Follow us: Twitter - Website
Thanks for the help
I can use a timer for the grenades(hopefully)
Like @AlchimiaStudios says it's not clear what you want, 'wander around' could mean anything.
Okay. So, I could use timers that change linear.velocity.x. But I understand that it NEEDS to be thought through thoroughly.
And I understand that 'wander' can mean anything
Thanks for the help
Yes that's a start, you're on the right track I think. Timers and the various "movement" methods (interpolate, move to, move, accelerate, etc) are probably the simplest implementation for this.
Follow us: Twitter - Website
Sweet. I never thought making a video game would be this "easy"(it is not "easy", just a lot easier than writing and learning the actual code).
Thanks a bunch