View Single Post
Old 26.11.2006, 20:47   #6
kin
Архивный участник
 
Join Date: Sep 2006
Posts: 882
Default

And here for the small one:
Code:
class 1 event_tree : default_npc
handler 13 13	//  CREATED
	variable_begin
		"myself"
		"_choiceN"
		"_code"
		"_from_choice"
	variable_end

	push_event	//  myself
	push_const 704
	add
	fetch_i
	push_const 5001
	push_const 1000
	push_const 60
	mul
	push_const 20
	mul
	func_call 184680487	//  func[AddTimerEx]
	shift_sp -2
	shift_sp -1
handler_end

handler 12 16	//  TIMER_FIRED_EX
	variable_begin
		"timer_id"
		"myself"
		"_choiceN"
		"_code"
		"_from_choice"
	variable_end

	push_event	//  timer_id
	push_const 236
	add
	fetch_i4
	push_const 5001
	equal
	branch_false L20682
L20681
	push_event	//  myself
	push_const 704
	add
	fetch_i
	func_call 184549616	//  func[Despawn]
	shift_sp -1
L20682
	call_super
handler_end

class_end
Here is my npcdata:

Code:
npc_begin	holything	12619	[x_mas_tree_a]	level=70	acquire_exp_rate=0.1	acquire_sp=10	unsowing=1	clan={}	ignore_clan_list={}	clan_help_range=300	slot_chest=[]	slot_rhand=[]	slot_lhand=[]	shield_defense_rate=0	shield_defense=0	skill_list={@s_race_divine;@s_full_magic_defence}	npc_ai={[x_mas_tree_a]}	category={}	race=divine	sex=male	undying=1	can_be_attacked=0	corpse_time=7	no_sleep_mode=0	agro_range=1000	ground_high={120;0;0}	ground_low={30;0;0}	exp=429634528	org_hp=2444.5	org_hp_regen=7.5	org_mp=1345.8	org_mp_regen=2.7	collision_radius={0;0}	collision_height={0;0}	str=40	int=21	dex=30	wit=20	con=43	men=10	base_attack_type=sword	base_attack_range=40	base_damage_range={0;0;80;120}	base_rand_dam=30	base_physical_attack=6xx.xx	base_critical=4	physical_hit_modify=4.75	base_attack_speed=253	base_reuse_delay=0	base_magic_attack=470.4	base_defend=2xx.xx	base_magic_defend=2xx.xx	physical_avoid_modify=0	soulshot_count=0	spiritshot_count=0	hit_time_factor=0.52	item_make_list={}	corpse_make_list={}	additional_make_list={}	additional_make_multi_list={}	hp_increase=0	mp_increase=0	safe_height=100	npc_end
npc_begin	xmastree	12620	[x_mas_tree_b]	level=70	acquire_exp_rate=0.1	acquire_sp=10	unsowing=1	clan={}	ignore_clan_list={}	clan_help_range=300	slot_chest=[]	slot_rhand=[]	slot_lhand=[]	shield_defense_rate=0	shield_defense=0	skill_list={@s_race_divine;@s_full_magic_defence}	npc_ai={[x_mas_tree_b]}	category={}	race=divine	sex=male	undying=1	can_be_attacked=0	corpse_time=7	no_sleep_mode=0	agro_range=1000	ground_high={120;0;0}	ground_low={30;0;0}	exp=429634528	org_hp=2444.5	org_hp_regen=7.5	org_mp=1345.8	org_mp_regen=2.7	collision_radius={0;0}	collision_height={0;0}	str=40	int=21	dex=30	wit=20	con=43	men=10	base_attack_type=sword	base_attack_range=40	base_damage_range={0;0;80;120}	base_rand_dam=30	base_physical_attack=6xx.xx	base_critical=4	physical_hit_modify=4.75	base_attack_speed=253	base_reuse_delay=0	base_magic_attack=470.4	base_defend=2xx.xx	base_magic_defend=2xx.xx	physical_avoid_modify=0	soulshot_count=0	spiritshot_count=0	hit_time_factor=0.52	item_make_list={}	corpse_make_list={}	additional_make_list={}	additional_make_multi_list={}	hp_increase=0	mp_increase=0	safe_height=100	npc_end
kin is offline