Jump to content

Recommended Posts

Posted

Playing with waypoints after checking out Nick's tutorial (Thanks Nick!) and thought I'd play with them using a different method.

With this script you can use any entity as a waypoint, including the player, barrels, pivots, etc. Remember the larger the entity the larger the range detection must be.

They can be a child of anything or not a child. Just don't make it a child of a moving entity.

They will go in order of targets entered or if Random roaming is checked it will be (duh) random.

Make sure to create a navmesh. So far I've only tested with 5 entities roaming simultaneously.

Fun to mess around with tongue.png

 

Edit: Added simple smoothing

post-12583-0-15445100-1424376007_thumb.png

AIwaypoint.lua

  • Upvote 4

---

Scott

 

Using Windows 7 Ultimate 64 bit/Core I7-2700K @ 4312mhz/24G RAM/Nvidia GTX 1060

Posted

Is the path navigation smoothed like a curve to avoid sudden direction change at each point ?

Making and using waypoints hsould be part of the editor and the engine.

Stop toying and make games

Posted

No. I haven't tried that yet and so far I don't require it. Could always smooth it by making more waypoints.

---

Scott

 

Using Windows 7 Ultimate 64 bit/Core I7-2700K @ 4312mhz/24G RAM/Nvidia GTX 1060

Posted
Could always smooth it by making more waypoints.

It's more non required work compared t oa simple smooth.

I don't need it , i have already my AI and system, but it could had been good for people using it with characters.

Stop toying and make games

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...