View Single Post
Old 14.10.2005, 19:37   #7
Phantom2005
Архивный участник
 
Join Date: Aug 2005
Posts: 394
Default

Quote:
Originally Posted by top-gear
I managed to summon cat the kat with correct skin again. Mp recharge does nothing at all though
Ok first step has been fixed... now for the second one....

for the AI:
Code:
class summon_heal : default_npc
parameter_define_begin
	int HealMagic 1030401
parameter_define_end
handler 13	//  CREATED
	variable_begin
		"myself"
		"_choiceN"
		"_code"
		"_from_choice"
	variable_end

	shift_sp 1
	push_const xx.xx0000
	func_call 14	//  func[AddPetDefaultDesire_Follow]
	shift_sp -1
	shift_sp -1
handler_end

handler 0	//  NO_DESIRE
	variable_begin
		"myself"
		"_choiceN"
		"_code"
		"_from_choice"
	variable_end

	shift_sp 1
	push_const xx.xx0000
	func_call 14	//  func[AddPetDefaultDesire_Follow]
	shift_sp -1
	shift_sp -1
handler_end

handler 32	//  MENU_SELECTED
	variable_begin
		"ask"
		"reply"
		"myself"
		"_choiceN"
		"_code"
		"_from_choice"
	variable_end

	shift_sp 1
	push_parameter HealMagic
	func_call 155	//  func[Skill_GetConsumeMP]
	shift_sp -1
	push_event	//  myself
	push_const 28
	add
	fetch_i	//  sm
	push_const 2400
	add
	fetch_i	//  mp
	push_const 352
	add
	fetch_d
	less
	push_reg_sp
	fetch_i
	branch_false L2092
	shift_sp 1
	push_parameter HealMagic
	func_call 154	//  func[Skill_GetConsumeHP]
	shift_sp -1
	push_event	//  myself
	push_const 28
	add
	fetch_i	//  sm
	push_const 2400
	add
	fetch_i	//  hp
	push_const 344
	add
	fetch_d
	less
	and
	push_reg_sp
	fetch_i
	branch_false L2092
	shift_sp 1
	push_parameter HealMagic
	func_call 160	//  func[Skill_InReuseDelay]
	shift_sp -1
	push_const 0
	equal
	and
L2092
	branch_false L2094
L2093
	shift_sp 1
	push_parameter HealMagic
	func_call 155	//  func[Skill_GetConsumeMP]
	shift_sp -1
	push_event	//  myself
	push_const 28
	add
	fetch_i	//  sm
	push_const 2400
	add
	fetch_i	//  mp
	push_const 352
	add
	fetch_d
	less
	push_reg_sp
	fetch_i
	branch_false L2095
	shift_sp 1
	push_parameter HealMagic
	func_call 154	//  func[Skill_GetConsumeHP]
	shift_sp -1
	push_event	//  myself
	push_const 28
	add
	fetch_i	//  sm
	push_const 2400
	add
	fetch_i	//  hp
	push_const 344
	add
	fetch_d
	less
	and
	push_reg_sp
	fetch_i
	branch_false L2095
	shift_sp 1
	push_parameter HealMagic
	func_call 160	//  func[Skill_InReuseDelay]
	shift_sp -1
	push_const 0
	equal
	and
L2095
	branch_false L2097
L2096
	shift_sp 1
	push_event	//  myself
	push_const 28
	add
	fetch_i	//  master
	push_const 2404
	add
	fetch_i
	push_parameter HealMagic
	push_const 1
	push_const 1
	push_const 1000000
	func_call 10	//  func[AddUseSkillDesire]
	shift_sp -5
	shift_sp -1
L2097
L2094
handler_end

class_end
IF it still doesn't heal ur MP:
(skilldata.txt)
Code:
skill_begin	skill_name = [s_cat_recharge1]	/* [캣더캣리차지] */	skill_id = 4025	level = 1	operate_type = A1	magic_level = 10	effect = {{i_mp_by_level;23}}	is_magic = 1	mp_consume1 = 5	mp_consume2 = 19	cast_range = 400	effective_range = 600	skill_hit_time = 2.5	skill_cool_time = 0	skill_hit_cancel_time = 0.5	reuse_delay = 8	attribute = attr_none	effect_point = 137	target_type = target	affect_scope = single	next_action = none	skill_end	
skill_begin	skill_name = [s_cat_recharge2]	/* [캣더캣리차지] */	skill_id = 4025	level = 2	operate_type = A1	magic_level = 20	effect = {{i_mp_by_level;38}}	is_magic = 1	mp_consume1 = 8	mp_consume2 = 31	cast_range = 400	effective_range = 600	skill_hit_time = 2.5	skill_cool_time = 0	skill_hit_cancel_time = 0.5	reuse_delay = 8	attribute = attr_none	effect_point = 203	target_type = target	affect_scope = single	next_action = none	skill_end	
skill_begin	skill_name = [s_cat_recharge3]	/* [캣더캣리차지] */	skill_id = 4025	level = 3	operate_type = A1	magic_level = 30	effect = {{i_mp_by_level;52}}	is_magic = 1	mp_consume1 = 11	mp_consume2 = 42	cast_range = 400	effective_range = 600	skill_hit_time = 2.5	skill_cool_time = 0	skill_hit_cancel_time = 0.5	reuse_delay = 8	attribute = attr_none	effect_point = 285	target_type = target	affect_scope = single	next_action = none	skill_end	
skill_begin	skill_name = [s_cat_recharge4]	/* [캣더캣리차지] */	skill_id = 4025	level = 4	operate_type = A1	magic_level = 40	effect = {{i_mp_by_level;70}}	is_magic = 1	mp_consume1 = 14	mp_consume2 = 56	cast_range = 400	effective_range = 600	skill_hit_time = 2.5	skill_cool_time = 0	skill_hit_cancel_time = 0.5	reuse_delay = 8	attribute = attr_none	effect_point = 379	target_type = target	affect_scope = single	next_action = none	skill_end	
skill_begin	skill_name = [s_cat_recharge5]	/* [캣더캣리차지] */	skill_id = 4025	level = 5	operate_type = A1	magic_level = 50	effect = {{i_mp_by_level;90}}	is_magic = 1	mp_consume1 = 18	mp_consume2 = 72	cast_range = 400	effective_range = 600	skill_hit_time = 2.5	skill_cool_time = 0	skill_hit_cancel_time = 0.5	reuse_delay = 8	attribute = attr_none	effect_point = 476	target_type = target	affect_scope = single	next_action = none	skill_end	
skill_begin	skill_name = [s_cat_recharge6]	/* [캣더캣리차지] */	skill_id = 4025	level = 6	operate_type = A1	magic_level = 60	effect = {{i_mp_by_level;110}}	is_magic = 1	mp_consume1 = 22	mp_consume2 = 88	cast_range = 400	effective_range = 600	skill_hit_time = 2.5	skill_cool_time = 0	skill_hit_cancel_time = 0.5	reuse_delay = 8	attribute = attr_none	effect_point = 566	target_type = target	affect_scope = single	next_action = none	skill_end	
skill_begin	skill_name = [s_cat_recharge7]	/* [캣더캣리차지] */	skill_id = 4025	level = 7	operate_type = A1	magic_level = 70	effect = {{i_mp_by_level;129}}	is_magic = 1	mp_consume1 = 26	mp_consume2 = 104	cast_range = 400	effective_range = 600	skill_hit_time = 2.5	skill_cool_time = 0	skill_hit_cancel_time = 0.5	reuse_delay = 8	attribute = attr_none	effect_point = 635	target_type = target	affect_scope = single	next_action = none	skill_end
(And if it still doesn't work i can post my npcdata....)
Phantom2005 is offline