|
4 registered members (VoroneTZ, kiamonster, Grant, 1 invisible),
3,511
guests, and 3
spiders. |
|
Key:
Admin,
Global Mod,
Mod
|
|
|
Re: Basic Patrol and Following
[Re: Bone]
#365553
03/27/11 14:04
03/27/11 14:04
|
Joined: Mar 2011
Posts: 28 Deutschland
Nog
Newbie
|
Newbie
Joined: Mar 2011
Posts: 28
Deutschland
|
Bone can you explain me this abit more? (i mean how to make the AI follow you)
YIPIIE YAY YEY, SCHWEINEBACKR!!! _________________________ Nog  !
|
|
|
Re: Basic Patrol and Following
[Re: Widi]
#365559
03/27/11 14:37
03/27/11 14:37
|
Joined: Mar 2011
Posts: 28 Deutschland
Nog
Newbie
|
Newbie
Joined: Mar 2011
Posts: 28
Deutschland
|
YIPIIE YAY YEY, SCHWEINEBACKR!!! _________________________ Nog  !
|
|
|
Re: Basic Patrol and Following
[Re: Nog]
#374656
06/20/11 19:11
06/20/11 19:11
|
Joined: Jun 2011
Posts: 133
nomis23uk
Member
|
Member
Joined: Jun 2011
Posts: 133
|
rather than the basic reply of read the manual which is everyones default reply here allow me to be abit more helpful.(not just this forum but in all forums ive seen here on 3dgs.)
You want Aum 97 and you looking for pathfinder...some other exampels within that same article can be very helpful.
hope this gives you a better example of how paths work.
im still learning about them myself so sorry I cant be more helpful but atleast I didnt say "read the manual".
A8 Pro Windows 7 64bit QuadCore i7, 6 gb ram, ATI 5970
|
|
|
Re: Basic Patrol and Following
[Re: nomis23uk]
#374742
06/21/11 12:28
06/21/11 12:28
|
Joined: Jul 2008
Posts: 2,111 Germany
rayp

X
|

X
Joined: Jul 2008
Posts: 2,111
Germany
|
Iam not at home else i would post a path-follow code. But i can give u a very basic player following:
entity* Player;
action My_Player
{
Player = ME;
}
action Follow_Player
{
WHILE(1)
{
//look into players direction
vec_set(temp,player.x);
vec_sub(temp,my.x);
vec_to_angle(my.pan,temp); // now MY looks at PLAYER
//move me in that direction
C_MOVE(me, vector(5*time_step,0,0), nullvector, IGNORE_ME);
WAIT(1);
}
}
Edit: Just checked out the Breadcrumb script (aum76). Man that is awesome working well ! Brought it into c-script, just running fine. Great thing ! MfG
Last edited by rayp; 06/21/11 14:57.
Acknex umgibt uns...zwischen Dir, mir, dem Stein dort... "Hey Griswold ... where u gonna put a tree that big ?" 1998 i married my loved wife ... Sheeva from Mortal Kombat, not Evil-Lyn as might have been expected rayp.flags |= UNTOUCHABLE;
|
|
|
|