Gamestudio Links
Zorro Links
Newest Posts
Zorro 2.70
by jcl. 09/29/25 09:24
optimize global parameters SOLVED
by dBc. 09/27/25 17:07
ZorroGPT
by TipmyPip. 09/27/25 10:05
assetHistory one candle shift
by jcl. 09/21/25 11:36
Plugins update
by Grant. 09/17/25 16:28
AUM Magazine
Latest Screens
Rocker`s Revenge
Stug 3 Stormartillery
Iljuschin 2
Galactic Strike X
Who's Online Now
0 registered members (), 17,416 guests, and 5 spiders.
Key: Admin, Global Mod, Mod
Newest Members
krishna, DrissB, James168, Ed_Love, xtns
19168 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
Pls, I really need some codes.... #390291
12/26/11 02:40
12/26/11 02:40
Joined: May 2010
Posts: 23
M
Mandeville Offline OP
Newbie
Mandeville  Offline OP
Newbie
M

Joined: May 2010
Posts: 23


I want a car to go down the street. When the car is at the end of the street, I want him to be teleport at the start point. I tried so many crazy things, please help me!

There is my action for the car;




Code:
Code:action car()
{	
my.emask |= ENABLE_IMPACT;   

	ENTITY* enemy = NULL; // spell target
	my.STATE = 1;
	VECTOR vFeet;
	vec_for_min(vFeet,me); // vFeet.z = distance from player origin to lowest vertex
	VECTOR move_me;
	while(1)
	{



	

	
			VECTOR target_node_pos;
			
			var temp;
			var target_node_num = 1;//start at node 1

			path_set(me,"path_000");
			path_nextnode(my,1,1);
			path_getnode(me,1,target_node_pos.x,NULL);
		

			 into target_node_pos		
		
			
		
		
		
			
			move_me.x = 0.25;
			c_trace(my.x,vector(my.x,my.y,my.z-1000),IGNORE_ME | IGNORE_PASSENTS);
			my.z = hit.z - vFeet.z; // always place player's feet on the ground
			c_move(me,vector(move_me.x,0,0),NULL, GLIDE);
	
					

	
			wait(1);	



		


	}
	 	
}



Now how should I insert this line when the car have finish his path?




Code:
Code:ent_remove(me);
				ent_create("car1.mdl",vector(-260,165,-



Re: Pls, I really need some codes.... [Re: Mandeville] #390293
12/26/11 06:55
12/26/11 06:55
Joined: May 2010
Posts: 23
M
Mandeville Offline OP
Newbie
Mandeville  Offline OP
Newbie
M

Joined: May 2010
Posts: 23
Nevermind, i get it!


Gamestudio download | Zorro platform | shop | Data Protection Policy

oP group Germany GmbH | Birkenstr. 25-27 | 63549 Ronneburg / Germany | info (at) opgroup.de

Powered by UBB.threads™ PHP Forum Software 7.7.1