View Single Post
Old 26.10.2005, 15:03   #12
Gremilcar
Архивный участник
 
Join Date: Oct 2005
Posts: 6
Default

Well i think that when Orfen spawns she starts with a 4 sets of clean coordinates, because they're defined as 0's...
Code:
parameter_define_begin 
   int b03_x1 0 
   int b03_y1 0 
   int b03_z1 0 
   int b03_x2 0 
   int b03_y2 0 
   int b03_z2 0 
   int b03_x3 0 
   int b03_y3 0 
   int b03_z3 0 
   int b03_x4 0 
   int b03_y4 0 
   int b03_z4 0 
parameter_define_end
but, after she's spawned, it records the coordinates for the teleport
Code:
   shift_sp 1 
   push_parameter b03_x2 
   push_parameter b03_y2 
   push_parameter b03_z2 
   func_call 27   //  func[SetTeleportPosOnLost] 
   shift_sp -3 
   shift_sp -1
// I think that "shift_sp 1" and "shift_sp -1" are used as brackets, correct me if im wrong...

So later she can teleport back using
Code:
	shift_sp 1
	push_event	//  myself
	push_const 28
	add
	fetch_i	//  sm
	push_const 2400
	add
	fetch_i
	push_parameter b03_x2
	push_parameter b03_y2
	push_parameter b03_z2
	func_call 46	//  func[InstantTeleport]
	shift_sp -4
	shift_sp -1
AND there is a timer there:
Code:
	shift_sp 1
	push_const 3001
	push_const 10000
	func_call 28	//  func[AddTimerEx]
	shift_sp -2
	shift_sp -1
Yet im not a good programmer, but maybe using common sense i could figure this out to make other mobs to teleport back...

If there is any type of explanation of all these ai.obj language send me a link, i might be stupid but i'll learn fast :wink:
Gremilcar is offline