|
Re: How To Attach Walking Entity to Path?
[Re: Cristiano_Iost]
#412122
11/22/12 23:52
11/22/12 23:52
|
Joined: Jul 2001
Posts: 4,801 netherlands
Realspawn
Expert
|
Expert
Joined: Jul 2001
Posts: 4,801
netherlands
|
perhaps a dummie question. But how to make it follow a predefined path without using WED. so how to make it follow auto for example a path called : path_000 (if this model is created during game) and superku also thx from me
|
|
|
Re: How To Attach Walking Entity to Path?
[Re: Realspawn]
#415330
01/17/13 14:37
01/17/13 14:37
|
Joined: Dec 2010
Posts: 224 NRW, Germany
NeoJones
Member
|
Member
Joined: Dec 2010
Posts: 224
NRW, Germany
|
I have a question, too. I have the problem, that my entity having always not the same speed on the path. For example, i have a short edge, it runs fast. If i have a long edge on the path, it runs slow... here is my code:
//create a path
path_create(stones[new_stone].entname, 3, 2);
path_setnode(stones[new_stone].entname, 1, start_pos.x, NULL);
path_setnode(stones[new_stone].entname, 2, checkpoint_pos1.x, NULL);
path_setnode(stones[new_stone].entname, 3, end_pos.x, stones[new_stone].entname);
//follow path
var distance = 0;
while(1)
{
path_spline(stones[new_stone].entname, stones[new_stone].entname.x, distance += 5*time_step);
wait(1);
}
Errors are the engine of progress.
Version: A8 Commercial OS: Win 7 64bit Models: Cinema 4D
|
|
|
Moderated by mk_1, Perro, rayp, Realspawn, Rei_Ayanami, rvL_eXile, Spirit, Superku, Tobias, TSG_Torsten, VeT
|