Jump to content
  • 0

npc dont showing hi page [epilogue]


girogius

Question

my buffer npc have no reaction when i try to talk, its not showing buffer_npc001.htm

 

here is my ai script.
 

class 0 buffer : citizen
parameter_define_begin
    string fnHi "buffer_npc001.htm"
    string fnYouAreChaotic "buffer_npc002.htm"
    string fnNotEnoughAdena "buffer_npc003.htm"
    string fnWait "buffer_npc004.htm"
    int ItemBuff 57
    int Amount 1000
    int Delay 500
parameter_define_end


handler 13 11 // CREATED
    variable_begin
        "myself"
        "_choiceN"
        "_code"
        "_from_choice"
    variable_end


    push_event // myself
    push_const 728
    add
    fetch_i // i_ai0
    push_const 308
    add
    push_reg_sp
    fetch_i
    push_const 0
    assign4
    shift_sp -1
handler_end


handler 3 38 // TALKED
    variable_begin
        "talker"
        "myself"
        "_choiceN"
        "_code"
        "_from_choice"
    variable_end


    push_event // talker
    push_const 40
    add
    fetch_i // karma
    push_const 468
    add
    fetch_i4
    push_const 0
    greater
    branch_false L2
L1
    push_event // myself
    push_const 728
    add
    fetch_i
    push_event // talker
    push_const 40
    add
    fetch_i
    push_parameter fnYouAreChaotic
    func_call 235012165 // func[ShowPage]
    shift_sp -2
    shift_sp -1
    jump L3
L2
    push_event // myself
    push_const 728
    add
    fetch_i
    push_event // talker
    push_const 40
    add
    fetch_i
    push_parameter fnHi
    func_call 235012165 // func[ShowPage]
    shift_sp -2
    shift_sp -1
L3
handler_end


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


    push_event // ask
    push_const 160
    add
    fetch_i4
    push_const 201
    negate
    equal
    push_reg_sp
    fetch_i
    branch_false L4
    shift_sp 1
    push_event // myself
    push_const 704
    add
    fetch_i
    push_event // talker
    push_const 40
    add
    fetch_i
    push_parameter ItemBuff
    func_call 184680579 // func[OwnItemCount]
    shift_sp -2
    push_parameter Amount
    greater_equal
    and
L4
    branch_false L5
L6
    push_event // myself
    push_const 704
    add
    fetch_i // i_ai0
    push_const 308
    add
    fetch_i4
    push_const 0
    equal
    branch_false L8
L7
    push_event // myself
    push_const 704
    add
    fetch_i // i_ai0
    push_const 308
    add
    push_reg_sp
    fetch_i
    push_const 1
    assign4
    shift_sp -1
    push_event // myself
    push_const 704
    add
    fetch_i
    push_event // talker
    push_const 40
    add
    fetch_i
    push_parameter ItemBuff
    push_parameter Amount
    func_call 184746114 // func[DeleteItem1]
    shift_sp -3
    shift_sp -1
    push_event // myself
    push_const 704
    add
    fetch_i
    push_event // talker
    push_const 40
    add
    fetch_i
    push_event // reply
    push_const 164
    add
    fetch_i
    push_const 1
    push_const 1
    push_const 1000000
    func_call 184877074 // func[AddUseSkillDesire]
    shift_sp -5
    shift_sp -1
    push_event // myself
    push_const 704
    add
    fetch_i
    push_event // talker
    push_const 40
    add
    fetch_i
    push_parameter fnHi
    func_call 235012165 // func[ShowPage]
    shift_sp -2
    shift_sp -1
    push_event // myself
    push_const 704
    add
    fetch_i
    push_const 1
    push_parameter Delay
    func_call 184680487 // func[AddTimerEx]
    shift_sp -2
    shift_sp -1
    jump L9
L8
    shift_sp 1
    push_event // myself
    push_const 704
    add
    fetch_i
    push_event // talker
    push_const 40
    add
    fetch_i
    push_parameter fnWait
    func_call 235012165 // func[ShowPage]
    shift_sp -2
    shift_sp -1
L9
    jump L10
L5
    shift_sp 1
    push_event // myself
    push_const 704
    add
    fetch_i
    push_event // talker
    push_const 40
    add
    fetch_i
    push_parameter fnNotEnoughAdena
    func_call 235012165 // func[ShowPage]
    shift_sp -2
    shift_sp -1
L10
handler_end


handler 12 20 // 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 1
    equal
    branch_false L12
    L11
    push_event // myself
    push_const 704
    add
    fetch_i // i_ai0
    push_const 308
    add
    push_reg_sp
    fetch_i
    push_const 0
    assign4
    shift_sp -1
L12
handler_end


class_end

 

Edited by Vision
Link to comment
Share on other sites

Recommended Posts

  • 0
4 minutes ago, slavergigi said:

Man... go in npcdata.txt and go to on the npc where you want put the ai .... and search npc_ai={[yourainameforbuffer]};{[fnHi]=[yourhtm.htm]};{[MoveAroundSocia ect.....]}

 

now i have like this :d

 

npc_ai={[myainame]};

 

ok i will add fnHi also but i dont think it it solves problem

Edited by girogius
Link to comment
Share on other sites

  • 0
7 minutes ago, slavergigi said:

Man... go in npcdata.txt and go to on the npc where you want put the ai .... and search npc_ai={[yourainameforbuffer]};{[fnHi]=[yourhtm.htm]};{[MoveAroundSocia ect.....]}


npc_begin	merchant	7100	[__emilia]	level=70	acquire_exp_rate=0	acquire_sp=0	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_undead;@s_full_magic_defence}	npc_ai={[npc_buffer];{[fnHi]=[npc_buffer_main.htm]};{[MoveAroundSocial]=0};{[MoveAroundSocial1]=0};{[MoveAroundSocial2]=0}}	category={}	race=human	sex=female	undying=1	can_be_attacked=0	corpse_time=7	no_sleep_mode=0	agro_range=1000	ground_high={120;0;0}	ground_low={50;0;0}	exp=429634528	org_hp=2444.46819	org_hp_regen=7.5	org_mp=10000	org_mp_regen=200	collision_radius={7;7}	collision_height={23;23}	str=60	int=90	dex=50	wit=90	con=60	men=40	base_attack_type=sword	base_attack_range=40	base_damage_range={0;0;80;120}	base_rand_dam=30	base_physical_attack=688.86373	base_critical=4	physical_hit_modify=4.75	base_attack_speed=253	base_reuse_delay=0	base_magic_attack=470.40463	base_defend=295.91597	base_magic_defend=216.53847	physical_avoid_modify=0	soulshot_count=0	spiritshot_count=0	hit_time_factor=0.6	item_make_list={}	corpse_make_list={}	additional_make_list={}	additional_make_multi_list={}	hp_increase=0	mp_increase=0	safe_height=100	npc_end

This is my npc.. see?

 

 

this is mine now but still empty window ..

 

npc_begin	citizen	37017	[server_manager]	category={}	level=80	exp=4200000000	ex_crt_effect=1	unique=0	s_npc_prop_hp_rate=1	race=construct	sex=female	skill_list={@s_npc_prop_race_construct;@s_npc_prop_hp_lv_p0;@s_npc_prop_mp_lv_p0;@s_npc_prop_pa_lv_p0;@s_npc_prop_ma_lv_p0;@s_npc_prop_pd_lv_p0;@s_npc_prop_md_lv_p0;@s_npc_prop_armor_type_n;@s_npc_prop_weapon_type_sword;@s_npc_abnormal_immunity;@s_full_magic_defence}	slot_chest=[]	slot_rhand=[]	slot_lhand=[]	collision_radius={25;25}	collision_height={47.5;47.5}	hit_time_factor=0.6	hit_time_factor_skill=-1	ground_high={1;0;0}	ground_low={1;0;0}	str=40	int=21	dex=30	wit=20	con=43	men=20	org_hp=3290.11306877694	org_hp_regen=8.5	org_mp=1674.8	org_mp_regen=3	base_attack_type=sword	base_attack_range=40	base_damage_range={0;0;80;120}	base_rand_dam=30	base_physical_attack=970.537548504614	base_critical=4	physical_hit_modify=5	base_attack_speed=253	base_reuse_delay=0	base_magic_attack=662.751329129412	base_defend=341.375	base_magic_defend=249.80341	base_attribute_attack={none;0}	base_attribute_defend={20;20;20;20;20;20;0}	physical_avoid_modify=0	shield_defense_rate=0	shield_defense=0	safe_height=100	soulshot_count=0	spiritshot_count=0	clan={}	ignore_clan_list={}	clan_help_range=0	undying=1	can_be_attacked=0	corpse_time=7	no_sleep_mode=0	agro_range=0	passable_door=0	can_move=0	flying=0	has_summoner=0	targetable=1	show_name_tag=1	npc_ai={[server_manager]};{[fnHi]=[server_manager.htm]};	unsowing=1	acquire_exp_rate=0	acquire_sp=0	acquire_rp=0	corpse_make_list={}	additional_make_list={}	additional_make_multi_list={}	ex_item_drop_list={}	npc_end

 

i restarted cached and l2server but its same 😭

 

Link to comment
Share on other sites

  • 0
On 1/24/2021 at 8:00 PM, girogius said:

my buffer npc have no reaction when i try to talk, its not showing buffer_npc001.htm

 

here is my ai script.
 


class 0 buffer : citizen
parameter_define_begin
    string fnHi "buffer_npc001.htm"
    string fnYouAreChaotic "buffer_npc002.htm"
    string fnNotEnoughAdena "buffer_npc003.htm"
    string fnWait "buffer_npc004.htm"
    int ItemBuff 57
    int Amount 1000
    int Delay 500
parameter_define_end


handler 13 11 // CREATED
    variable_begin
        "myself"
        "_choiceN"
        "_code"
        "_from_choice"
    variable_end


    push_event // myself
    push_const 728
    add
    fetch_i // i_ai0
    push_const 308
    add
    push_reg_sp
    fetch_i
    push_const 0
    assign4
    shift_sp -1
handler_end


handler 3 38 // TALKED
    variable_begin
        "talker"
        "myself"
        "_choiceN"
        "_code"
        "_from_choice"
    variable_end


    push_event // talker
    push_const 40
    add
    fetch_i // karma
    push_const 468
    add
    fetch_i4
    push_const 0
    greater
    branch_false L2
L1
    push_event // myself
    push_const 728
    add
    fetch_i
    push_event // talker
    push_const 40
    add
    fetch_i
    push_parameter fnYouAreChaotic
    func_call 235012165 // func[ShowPage]
    shift_sp -2
    shift_sp -1
    jump L3
L2
    push_event // myself
    push_const 728
    add
    fetch_i
    push_event // talker
    push_const 40
    add
    fetch_i
    push_parameter fnHi
    func_call 235012165 // func[ShowPage]
    shift_sp -2
    shift_sp -1
L3
handler_end


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


    push_event // ask
    push_const 160
    add
    fetch_i4
    push_const 201
    negate
    equal
    push_reg_sp
    fetch_i
    branch_false L4
    shift_sp 1
    push_event // myself
    push_const 704
    add
    fetch_i
    push_event // talker
    push_const 40
    add
    fetch_i
    push_parameter ItemBuff
    func_call 184680579 // func[OwnItemCount]
    shift_sp -2
    push_parameter Amount
    greater_equal
    and
L4
    branch_false L5
L6
    push_event // myself
    push_const 704
    add
    fetch_i // i_ai0
    push_const 308
    add
    fetch_i4
    push_const 0
    equal
    branch_false L8
L7
    push_event // myself
    push_const 704
    add
    fetch_i // i_ai0
    push_const 308
    add
    push_reg_sp
    fetch_i
    push_const 1
    assign4
    shift_sp -1
    push_event // myself
    push_const 704
    add
    fetch_i
    push_event // talker
    push_const 40
    add
    fetch_i
    push_parameter ItemBuff
    push_parameter Amount
    func_call 184746114 // func[DeleteItem1]
    shift_sp -3
    shift_sp -1
    push_event // myself
    push_const 704
    add
    fetch_i
    push_event // talker
    push_const 40
    add
    fetch_i
    push_event // reply
    push_const 164
    add
    fetch_i
    push_const 1
    push_const 1
    push_const 1000000
    func_call 184877074 // func[AddUseSkillDesire]
    shift_sp -5
    shift_sp -1
    push_event // myself
    push_const 704
    add
    fetch_i
    push_event // talker
    push_const 40
    add
    fetch_i
    push_parameter fnHi
    func_call 235012165 // func[ShowPage]
    shift_sp -2
    shift_sp -1
    push_event // myself
    push_const 704
    add
    fetch_i
    push_const 1
    push_parameter Delay
    func_call 184680487 // func[AddTimerEx]
    shift_sp -2
    shift_sp -1
    jump L9
L8
    shift_sp 1
    push_event // myself
    push_const 704
    add
    fetch_i
    push_event // talker
    push_const 40
    add
    fetch_i
    push_parameter fnWait
    func_call 235012165 // func[ShowPage]
    shift_sp -2
    shift_sp -1
L9
    jump L10
L5
    shift_sp 1
    push_event // myself
    push_const 704
    add
    fetch_i
    push_event // talker
    push_const 40
    add
    fetch_i
    push_parameter fnNotEnoughAdena
    func_call 235012165 // func[ShowPage]
    shift_sp -2
    shift_sp -1
L10
handler_end


handler 12 20 // 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 1
    equal
    branch_false L12
    L11
    push_event // myself
    push_const 704
    add
    fetch_i // i_ai0
    push_const 308
    add
    push_reg_sp
    fetch_i
    push_const 0
    assign4
    shift_sp -1
L12
handler_end


class_end

 

Bump

 

4 minutes ago, girogius said:

 

 

this is mine now but still empty window ..

 


npc_begin	citizen	37017	[server_manager]	category={}	level=80	exp=4200000000	ex_crt_effect=1	unique=0	s_npc_prop_hp_rate=1	race=construct	sex=female	skill_list={@s_npc_prop_race_construct;@s_npc_prop_hp_lv_p0;@s_npc_prop_mp_lv_p0;@s_npc_prop_pa_lv_p0;@s_npc_prop_ma_lv_p0;@s_npc_prop_pd_lv_p0;@s_npc_prop_md_lv_p0;@s_npc_prop_armor_type_n;@s_npc_prop_weapon_type_sword;@s_npc_abnormal_immunity;@s_full_magic_defence}	slot_chest=[]	slot_rhand=[]	slot_lhand=[]	collision_radius={25;25}	collision_height={47.5;47.5}	hit_time_factor=0.6	hit_time_factor_skill=-1	ground_high={1;0;0}	ground_low={1;0;0}	str=40	int=21	dex=30	wit=20	con=43	men=20	org_hp=3290.11306877694	org_hp_regen=8.5	org_mp=1674.8	org_mp_regen=3	base_attack_type=sword	base_attack_range=40	base_damage_range={0;0;80;120}	base_rand_dam=30	base_physical_attack=970.537548504614	base_critical=4	physical_hit_modify=5	base_attack_speed=253	base_reuse_delay=0	base_magic_attack=662.751329129412	base_defend=341.375	base_magic_defend=249.80341	base_attribute_attack={none;0}	base_attribute_defend={20;20;20;20;20;20;0}	physical_avoid_modify=0	shield_defense_rate=0	shield_defense=0	safe_height=100	soulshot_count=0	spiritshot_count=0	clan={}	ignore_clan_list={}	clan_help_range=0	undying=1	can_be_attacked=0	corpse_time=7	no_sleep_mode=0	agro_range=0	passable_door=0	can_move=0	flying=0	has_summoner=0	targetable=1	show_name_tag=1	npc_ai={[server_manager]};{[fnHi]=[server_manager.htm]};	unsowing=1	acquire_exp_rate=0	acquire_sp=0	acquire_rp=0	corpse_make_list={}	additional_make_list={}	additional_make_multi_list={}	ex_item_drop_list={}	npc_end

 

i restarted cached and l2server but its same 😭

 

Have you see what is going wrong??

You put on ai fnHi  Buffernpc_001.htm and on your npc you put fnHi = server_manager.htm  lol man

Link to comment
Share on other sites

  • 0
16 minutes ago, slavergigi said:

Good xD

 

sho me what you got in npcpos.txt this npc part only..

 

i think there is a problem.. this is mine:

territory_begin	[npc_buffer_kamael_village_01]	{{-117369;46603;360;660};{-116969;46603;360;660};{-116969;47003;360;660};{-117369;47003;360;660}}	territory_end
npcmaker_begin	[npc_buffer_kamael_village_01]	initial_spawn=all	maximum_npc=1
npc_begin	[server_manager]	pos={-117169;46803;360;49420}	total=1	respawn=1min	ai=[server_manager];	npc_end
npcmaker_end

 

2 minutes ago, slavergigi said:

 

Have you see what is going wrong??

You put on ai fnHi  Buffernpc_001.htm and on your npc you put fnHi = server_manager.htm  lol man

 

buffer npc is in old ai forget it fnHi now is server_manager.htm

 

string fnHi = "server_manager.htm";

Edited by girogius
Link to comment
Share on other sites

  • 0
1 minute ago, girogius said:

 

sho me what you got in npcpos.txt this npc part only..

 

i think there is a problem.. this is mine:


territory_begin	[npc_buffer_kamael_village_01]	{{-117369;46603;360;660};{-116969;46603;360;660};{-116969;47003;360;660};{-117369;47003;360;660}}	territory_end
npcmaker_begin	[npc_buffer_kamael_village_01]	initial_spawn=all	maximum_npc=1
npc_begin	[server_manager]	pos={-117169;46803;360;49420}	total=1	respawn=1min	ai=[server_manager];	npc_end
npcmaker_end

 

Is not the problem of the territoy ..

Link to comment
Share on other sites

  • 0
territory_begin	[giran11_npc2222_tk01]	{{83260;147804;-3457;-3257};{83460;147804;-3457;-3257};{83460;148004;-3457;-3257};{83260;148004;-3457;-3257}}	territory_end	
npc_begin	[__emilia]	pos={83087;148388;-3464;0}	total=1	respawn=1min	npc_end
npc_begin	[__emilia]	pos={83277;147917;-3400;0}	total=1	respawn=1min	npc_end

 

class 0 buffer : citizen

 

you have this wrong too

If you called ai buffer you need put all named buffer on ai npcdata and npcpos ai youn cant name on ai buffer and name server_manager......

 

You need put only one same name....

Link to comment
Share on other sites

  • 0
17 minutes ago, slavergigi said:


territory_begin	[giran11_npc2222_tk01]	{{83260;147804;-3457;-3257};{83460;147804;-3457;-3257};{83460;148004;-3457;-3257};{83260;148004;-3457;-3257}}	territory_end	


npc_begin	[__emilia]	pos={83087;148388;-3464;0}	total=1	respawn=1min	npc_end
npc_begin	[__emilia]	pos={83277;147917;-3400;0}	total=1	respawn=1min	npc_end

 



class 0 buffer : citizen

 

you have this wrong too

 

fck i will share every part of this nc code from ai to html everything looks correct

17 minutes ago, slavergigi said:


territory_begin	[giran11_npc2222_tk01]	{{83260;147804;-3457;-3257};{83460;147804;-3457;-3257};{83460;148004;-3457;-3257};{83260;148004;-3457;-3257}}	territory_end	


npc_begin	[__emilia]	pos={83087;148388;-3464;0}	total=1	respawn=1min	npc_end
npc_begin	[__emilia]	pos={83277;147917;-3400;0}	total=1	respawn=1min	npc_end

 



class 0 buffer : citizen

 

you have this wrong too

 

compiled ai:

class 0 server_manager : default_npc
parameter_define_begin
	string fnHi "server_manager.htm"
	string fnShop "server_manager_shop.htm"
	string fnShopArmor "server_manager_shop_armor.htm"
	string fnShopWeapon "server_manager_shop_weapon.htm"
	string fnShopJewel "server_manager_shop_jewel.htm"
	string fnShopConsumables "server_manager_shop_consumables.htm"
	string fnProfession "server_manager_class.htm"
	string fnBuffs "server_manager_buffs.htm"
	string fnYouAreChaotic "server_manager_chaotic.htm"
	int firstClassPrice 500000
	int secondClassPrice 3000000
	int thirdClassPrice 30000000
	int buffPrice 1000
parameter_define_end
handler 3 38	//  TALKED
	variable_begin
		"talker"
		"myself"
		"_choiceN"
		"_code"
		"_from_choice"
	variable_end

	push_event	//  talker
	push_const 40			//talker
	add
	fetch_i			//karma
	push_const 528			//karma
	add
	fetch_i4
	push_const 0			//unary->INTEGER_CONST
	greater
	branch_false L1
L0
	push_event	//  myself
	push_const 784			//ShowPage
	add
	fetch_i			//ShowPage
	push_event	//  talker
	push_const 40			//talker
	add
	fetch_i
	push_parameter fnYouAreChaotic
	func_call 235012165	//  func[ShowPage]
	shift_sp -2
	shift_sp -1
	jump L2
L1
	push_event	//  myself
	push_const 784			//ShowPage
	add
	fetch_i			//ShowPage
	push_event	//  talker
	push_const 40			//talker
	add
	fetch_i
	push_parameter fnHi
	func_call 235012165	//  func[ShowPage]
	shift_sp -2
	shift_sp -1
L2
handler_end

handler 31 185	//  MENU_SELECTED
	variable_begin
		"talker"
		"ask"
		"reply"
		"fhtml0"
		"myself"
		"_choiceN"
		"_code"
		"_from_choice"
	variable_end

	push_event	//  ask
	push_const 160			//ask
	add
	fetch_i4
	push_const 601			//unary->INTEGER_CONST
	negate
	equal
	branch_false L4
L3
	push_event	//  reply
	push_const 272			//reply
	add
	fetch_i
	push_reg_sp
	fetch_i			//select_case compare
	push_const 1			//select_case
	equal
	branch_false L7
L6
	push_event	//  myself
	push_const 784			//ShowPage
	add
	fetch_i			//ShowPage
	push_event	//  talker
	push_const 40			//talker
	add
	fetch_i
	push_parameter fnShop
	func_call 235012165	//  func[ShowPage]
	shift_sp -2
	shift_sp -1
	jump L5
	jump L8
L7
	push_reg_sp
	fetch_i			//select_case compare
	push_const 2			//select_case
	equal
	branch_false L9
L8
	push_event	//  myself
	push_const 784			//ShowPage
	add
	fetch_i			//ShowPage
	push_event	//  talker
	push_const 40			//talker
	add
	fetch_i
	push_parameter fnProfession
	func_call 235012165	//  func[ShowPage]
	shift_sp -2
	shift_sp -1
	jump L5
	jump L10
L9
	push_reg_sp
	fetch_i			//select_case compare
	push_const 11			//select_case
	equal
	branch_false L11
L10
	push_event	//  myself
	push_const 784			//ShowPage
	add
	fetch_i			//ShowPage
	push_event	//  talker
	push_const 40			//talker
	add
	fetch_i
	push_parameter fnShopArmor
	func_call 235012165	//  func[ShowPage]
	shift_sp -2
	shift_sp -1
	jump L5
	jump L12
L11
	push_reg_sp
	fetch_i			//select_case compare
	push_const 12			//select_case
	equal
	branch_false L13
L12
	push_event	//  myself
	push_const 784			//ShowPage
	add
	fetch_i			//ShowPage
	push_event	//  talker
	push_const 40			//talker
	add
	fetch_i
	push_parameter fnShopWeapon
	func_call 235012165	//  func[ShowPage]
	shift_sp -2
	shift_sp -1
	jump L5
	jump L14
L13
	push_reg_sp
	fetch_i			//select_case compare
	push_const 123			//select_case
	equal
	branch_false L15
L14
	push_event	//  myself
	push_const 784			//ShowMultisell
	add
	fetch_i			//ShowMultisell
	push_const 803			//unary->INTEGER_CONST
	push_event	//  talker
	push_const 40			//talker
	add
	fetch_i
	func_call 235012182	//  func[ShowMultisell]
	shift_sp -2
	shift_sp -1
	jump L5
	jump L16
L15
	push_reg_sp
	fetch_i			//select_case compare
	push_const 13			//select_case
	equal
	branch_false L17
L16
	push_event	//  myself
	push_const 784			//ShowPage
	add
	fetch_i			//ShowPage
	push_event	//  talker
	push_const 40			//talker
	add
	fetch_i
	push_parameter fnShopJewel
	func_call 235012165	//  func[ShowPage]
	shift_sp -2
	shift_sp -1
	jump L5
	jump L18
L17
	push_reg_sp
	fetch_i			//select_case compare
	push_const 14			//select_case
	equal
	branch_false L19
L18
	push_event	//  myself
	push_const 784			//ShowPage
	add
	fetch_i			//ShowPage
	push_event	//  talker
	push_const 40			//talker
	add
	fetch_i
	push_parameter fnShopConsumables
	func_call 235012165	//  func[ShowPage]
	shift_sp -2
	shift_sp -1
	jump L5
	jump L20
L19
	push_reg_sp
	fetch_i			//select_case compare
	push_const 3			//select_case
	equal
	branch_false L21
L20
	push_event	//  myself
	push_const 784			//ShowPage
	add
	fetch_i			//ShowPage
	push_event	//  talker
	push_const 40			//talker
	add
	fetch_i
	push_parameter fnBuffs
	func_call 235012165	//  func[ShowPage]
	shift_sp -2
	shift_sp -1
	jump L5
	jump L22
L21
L22
L5
	shift_sp -1
L4
handler_end

class_end

 

decompiled ai:

set_compiler_opt base_event_type(@NTYPE_NPC_EVENT)

class server_manager : default_npc {
parameter:
    string fnHi = "server_manager.htm";
    string fnShop = "server_manager_shop.htm";
    string fnShopArmor = "server_manager_shop_armor.htm";
    string fnShopWeapon = "server_manager_shop_weapon.htm";
    string fnShopJewel = "server_manager_shop_jewel.htm";
    string fnShopConsumables = "server_manager_shop_consumables.htm";
    string fnProfession = "server_manager_class.htm";
    string fnBuffs = "server_manager_buffs.htm";
    string fnYouAreChaotic = "server_manager_chaotic.htm";
    int firstClassPrice = 500000;
    int secondClassPrice = 3000000;
    int thirdClassPrice = 30000000;
    int buffPrice = 1000;

handler:
    EventHandler TALKED(talker) {

        if(talker.karma > 0){
            ShowPage(talker, fnYouAreChaotic);
        }
        else{
            ShowPage(talker, fnHi);
        }
        
    }    
	
    EventHandler MENU_SELECTED(talker, ask, reply, fhtml0) {
        if (ask == -601) {
            select (reply) {
                case 1:
                    ShowPage(talker, fnShop);
                    break;
                case 2:
                    ShowPage(talker, fnProfession);
                    break;  
                case 11:
                    ShowPage(talker, fnShopArmor);
                    break;       
                case 12:
                    ShowPage(talker, fnShopWeapon);
                    break;
                case 123:
                    ShowMultisell(803, talker);
                    break;                 
                case 13:
                    ShowPage(talker, fnShopJewel);
                    break;                 
                case 14:
                    ShowPage(talker, fnShopConsumables);
                    break;
                case 3:
                    ShowPage(talker, fnBuffs);
                    break;    
            }
        }
    }    
}

 

npc data:

npc_begin	citizen	37017	[server_manager]	category={}	level=80	exp=4200000000	ex_crt_effect=1	unique=0	s_npc_prop_hp_rate=1	race=construct	sex=female	skill_list={@s_npc_prop_race_construct;@s_npc_prop_hp_lv_p0;@s_npc_prop_mp_lv_p0;@s_npc_prop_pa_lv_p0;@s_npc_prop_ma_lv_p0;@s_npc_prop_pd_lv_p0;@s_npc_prop_md_lv_p0;@s_npc_prop_armor_type_n;@s_npc_prop_weapon_type_sword;@s_npc_abnormal_immunity;@s_full_magic_defence}	slot_chest=[]	slot_rhand=[]	slot_lhand=[]	collision_radius={25;25}	collision_height={47.5;47.5}	hit_time_factor=0.6	hit_time_factor_skill=-1	ground_high={1;0;0}	ground_low={1;0;0}	str=40	int=21	dex=30	wit=20	con=43	men=20	org_hp=3290.11306877694	org_hp_regen=8.5	org_mp=1674.8	org_mp_regen=3	base_attack_type=sword	base_attack_range=40	base_damage_range={0;0;80;120}	base_rand_dam=30	base_physical_attack=970.537548504614	base_critical=4	physical_hit_modify=5	base_attack_speed=253	base_reuse_delay=0	base_magic_attack=662.751329129412	base_defend=341.375	base_magic_defend=249.80341	base_attribute_attack={none;0}	base_attribute_defend={20;20;20;20;20;20;0}	physical_avoid_modify=0	shield_defense_rate=0	shield_defense=0	safe_height=100	soulshot_count=0	spiritshot_count=0	clan={}	ignore_clan_list={}	clan_help_range=0	undying=1	can_be_attacked=0	corpse_time=7	no_sleep_mode=0	agro_range=0	passable_door=0	can_move=0	flying=0	has_summoner=0	targetable=1	show_name_tag=1	npc_ai={[server_manager]};{[fnHi]=[server_manager.htm]};	unsowing=1	acquire_exp_rate=0	acquire_sp=0	acquire_rp=0	corpse_make_list={}	additional_make_list={}	additional_make_multi_list={}	ex_item_drop_list={}	npc_end

 

npc pos:

territory_begin	[npc_buffer_kamael_village_01]	{{-117369;46603;360;660};{-116969;46603;360;660};{-116969;47003;360;660};{-117369;47003;360;660}}	territory_end
npcmaker_begin	[npc_buffer_kamael_village_01]	initial_spawn=all	maximum_npc=1
npc_begin	[server_manager]	pos={-117169;46803;360;49420}	total=1	respawn=1min	npc_end
npcmaker_end

 

fnHi htm:

<html>
<head>
<title>Server Manager</title>
<body>
<button value="Shop" align="CENTER" action="bypass -h menu_select?ask=-601&reply=1" width=100 height=30 back="L2UI_CT1.Button_DF_Down" fore="L2UI_CT1.Button_DF"><br>
</body>
</html>

 

its not finished yet but shop and b grade armor multisell must be there...

Edited by girogius
Link to comment
Share on other sites

  • 0
5 minutes ago, girogius said:

 

fck i will share every part of this nc code from ai to html everything looks correct

 

compiled ai:


class 0 server_manager : default_npc
parameter_define_begin
	string fnHi "server_manager.htm"
	string fnShop "server_manager_shop.htm"
	string fnShopArmor "server_manager_shop_armor.htm"
	string fnShopWeapon "server_manager_shop_weapon.htm"
	string fnShopJewel "server_manager_shop_jewel.htm"
	string fnShopConsumables "server_manager_shop_consumables.htm"
	string fnProfession "server_manager_class.htm"
	string fnBuffs "server_manager_buffs.htm"
	string fnYouAreChaotic "server_manager_chaotic.htm"
	int firstClassPrice 500000
	int secondClassPrice 3000000
	int thirdClassPrice 30000000
	int buffPrice 1000
parameter_define_end
handler 3 38	//  TALKED
	variable_begin
		"talker"
		"myself"
		"_choiceN"
		"_code"
		"_from_choice"
	variable_end

	push_event	//  talker
	push_const 40			//talker
	add
	fetch_i			//karma
	push_const 528			//karma
	add
	fetch_i4
	push_const 0			//unary->INTEGER_CONST
	greater
	branch_false L1
L0
	push_event	//  myself
	push_const 784			//ShowPage
	add
	fetch_i			//ShowPage
	push_event	//  talker
	push_const 40			//talker
	add
	fetch_i
	push_parameter fnYouAreChaotic
	func_call 235012165	//  func[ShowPage]
	shift_sp -2
	shift_sp -1
	jump L2
L1
	push_event	//  myself
	push_const 784			//ShowPage
	add
	fetch_i			//ShowPage
	push_event	//  talker
	push_const 40			//talker
	add
	fetch_i
	push_parameter fnHi
	func_call 235012165	//  func[ShowPage]
	shift_sp -2
	shift_sp -1
L2
handler_end

handler 31 185	//  MENU_SELECTED
	variable_begin
		"talker"
		"ask"
		"reply"
		"fhtml0"
		"myself"
		"_choiceN"
		"_code"
		"_from_choice"
	variable_end

	push_event	//  ask
	push_const 160			//ask
	add
	fetch_i4
	push_const 601			//unary->INTEGER_CONST
	negate
	equal
	branch_false L4
L3
	push_event	//  reply
	push_const 272			//reply
	add
	fetch_i
	push_reg_sp
	fetch_i			//select_case compare
	push_const 1			//select_case
	equal
	branch_false L7
L6
	push_event	//  myself
	push_const 784			//ShowPage
	add
	fetch_i			//ShowPage
	push_event	//  talker
	push_const 40			//talker
	add
	fetch_i
	push_parameter fnShop
	func_call 235012165	//  func[ShowPage]
	shift_sp -2
	shift_sp -1
	jump L5
	jump L8
L7
	push_reg_sp
	fetch_i			//select_case compare
	push_const 2			//select_case
	equal
	branch_false L9
L8
	push_event	//  myself
	push_const 784			//ShowPage
	add
	fetch_i			//ShowPage
	push_event	//  talker
	push_const 40			//talker
	add
	fetch_i
	push_parameter fnProfession
	func_call 235012165	//  func[ShowPage]
	shift_sp -2
	shift_sp -1
	jump L5
	jump L10
L9
	push_reg_sp
	fetch_i			//select_case compare
	push_const 11			//select_case
	equal
	branch_false L11
L10
	push_event	//  myself
	push_const 784			//ShowPage
	add
	fetch_i			//ShowPage
	push_event	//  talker
	push_const 40			//talker
	add
	fetch_i
	push_parameter fnShopArmor
	func_call 235012165	//  func[ShowPage]
	shift_sp -2
	shift_sp -1
	jump L5
	jump L12
L11
	push_reg_sp
	fetch_i			//select_case compare
	push_const 12			//select_case
	equal
	branch_false L13
L12
	push_event	//  myself
	push_const 784			//ShowPage
	add
	fetch_i			//ShowPage
	push_event	//  talker
	push_const 40			//talker
	add
	fetch_i
	push_parameter fnShopWeapon
	func_call 235012165	//  func[ShowPage]
	shift_sp -2
	shift_sp -1
	jump L5
	jump L14
L13
	push_reg_sp
	fetch_i			//select_case compare
	push_const 123			//select_case
	equal
	branch_false L15
L14
	push_event	//  myself
	push_const 784			//ShowMultisell
	add
	fetch_i			//ShowMultisell
	push_const 803			//unary->INTEGER_CONST
	push_event	//  talker
	push_const 40			//talker
	add
	fetch_i
	func_call 235012182	//  func[ShowMultisell]
	shift_sp -2
	shift_sp -1
	jump L5
	jump L16
L15
	push_reg_sp
	fetch_i			//select_case compare
	push_const 13			//select_case
	equal
	branch_false L17
L16
	push_event	//  myself
	push_const 784			//ShowPage
	add
	fetch_i			//ShowPage
	push_event	//  talker
	push_const 40			//talker
	add
	fetch_i
	push_parameter fnShopJewel
	func_call 235012165	//  func[ShowPage]
	shift_sp -2
	shift_sp -1
	jump L5
	jump L18
L17
	push_reg_sp
	fetch_i			//select_case compare
	push_const 14			//select_case
	equal
	branch_false L19
L18
	push_event	//  myself
	push_const 784			//ShowPage
	add
	fetch_i			//ShowPage
	push_event	//  talker
	push_const 40			//talker
	add
	fetch_i
	push_parameter fnShopConsumables
	func_call 235012165	//  func[ShowPage]
	shift_sp -2
	shift_sp -1
	jump L5
	jump L20
L19
	push_reg_sp
	fetch_i			//select_case compare
	push_const 3			//select_case
	equal
	branch_false L21
L20
	push_event	//  myself
	push_const 784			//ShowPage
	add
	fetch_i			//ShowPage
	push_event	//  talker
	push_const 40			//talker
	add
	fetch_i
	push_parameter fnBuffs
	func_call 235012165	//  func[ShowPage]
	shift_sp -2
	shift_sp -1
	jump L5
	jump L22
L21
L22
L5
	shift_sp -1
L4
handler_end

class_end

 

decompiled ai:


set_compiler_opt base_event_type(@NTYPE_NPC_EVENT)

class server_manager : default_npc {
parameter:
    string fnHi = "server_manager.htm";
    string fnShop = "server_manager_shop.htm";
    string fnShopArmor = "server_manager_shop_armor.htm";
    string fnShopWeapon = "server_manager_shop_weapon.htm";
    string fnShopJewel = "server_manager_shop_jewel.htm";
    string fnShopConsumables = "server_manager_shop_consumables.htm";
    string fnProfession = "server_manager_class.htm";
    string fnBuffs = "server_manager_buffs.htm";
    string fnYouAreChaotic = "server_manager_chaotic.htm";
    int firstClassPrice = 500000;
    int secondClassPrice = 3000000;
    int thirdClassPrice = 30000000;
    int buffPrice = 1000;

handler:
    EventHandler TALKED(talker) {

        if(talker.karma > 0){
            ShowPage(talker, fnYouAreChaotic);
        }
        else{
            ShowPage(talker, fnHi);
        }
        
    }    
	
    EventHandler MENU_SELECTED(talker, ask, reply, fhtml0) {
        if (ask == -601) {
            select (reply) {
                case 1:
                    ShowPage(talker, fnShop);
                    break;
                case 2:
                    ShowPage(talker, fnProfession);
                    break;  
                case 11:
                    ShowPage(talker, fnShopArmor);
                    break;       
                case 12:
                    ShowPage(talker, fnShopWeapon);
                    break;
                case 123:
                    ShowMultisell(803, talker);
                    break;                 
                case 13:
                    ShowPage(talker, fnShopJewel);
                    break;                 
                case 14:
                    ShowPage(talker, fnShopConsumables);
                    break;
                case 3:
                    ShowPage(talker, fnBuffs);
                    break;    
            }
        }
    }    
}

 

npc data:


npc_begin	citizen	37017	[server_manager]	category={}	level=80	exp=4200000000	ex_crt_effect=1	unique=0	s_npc_prop_hp_rate=1	race=construct	sex=female	skill_list={@s_npc_prop_race_construct;@s_npc_prop_hp_lv_p0;@s_npc_prop_mp_lv_p0;@s_npc_prop_pa_lv_p0;@s_npc_prop_ma_lv_p0;@s_npc_prop_pd_lv_p0;@s_npc_prop_md_lv_p0;@s_npc_prop_armor_type_n;@s_npc_prop_weapon_type_sword;@s_npc_abnormal_immunity;@s_full_magic_defence}	slot_chest=[]	slot_rhand=[]	slot_lhand=[]	collision_radius={25;25}	collision_height={47.5;47.5}	hit_time_factor=0.6	hit_time_factor_skill=-1	ground_high={1;0;0}	ground_low={1;0;0}	str=40	int=21	dex=30	wit=20	con=43	men=20	org_hp=3290.11306877694	org_hp_regen=8.5	org_mp=1674.8	org_mp_regen=3	base_attack_type=sword	base_attack_range=40	base_damage_range={0;0;80;120}	base_rand_dam=30	base_physical_attack=970.537548504614	base_critical=4	physical_hit_modify=5	base_attack_speed=253	base_reuse_delay=0	base_magic_attack=662.751329129412	base_defend=341.375	base_magic_defend=249.80341	base_attribute_attack={none;0}	base_attribute_defend={20;20;20;20;20;20;0}	physical_avoid_modify=0	shield_defense_rate=0	shield_defense=0	safe_height=100	soulshot_count=0	spiritshot_count=0	clan={}	ignore_clan_list={}	clan_help_range=0	undying=1	can_be_attacked=0	corpse_time=7	no_sleep_mode=0	agro_range=0	passable_door=0	can_move=0	flying=0	has_summoner=0	targetable=1	show_name_tag=1	npc_ai={[server_manager]};{[fnHi]=[server_manager.htm]};	unsowing=1	acquire_exp_rate=0	acquire_sp=0	acquire_rp=0	corpse_make_list={}	additional_make_list={}	additional_make_multi_list={}	ex_item_drop_list={}	npc_end

 

npc pos:


territory_begin	[npc_buffer_kamael_village_01]	{{-117369;46603;360;660};{-116969;46603;360;660};{-116969;47003;360;660};{-117369;47003;360;660}}	territory_end
npcmaker_begin	[npc_buffer_kamael_village_01]	initial_spawn=all	maximum_npc=1
npc_begin	[server_manager]	pos={-117169;46803;360;49420}	total=1	respawn=1min	npc_end
npcmaker_end

 

fnHi htm:


<html>
<head>
<title>Server Manager</title>
<body>
<button value="Shop" align="CENTER" action="bypass -h menu_select?ask=-601&reply=1" width=100 height=30 back="L2UI_CT1.Button_DF_Down" fore="L2UI_CT1.Button_DF"><br>
</body>
</html>

 

Now it s ok just put on npcdata fnHi Server_Mager and no pos too

And let me now xD

Link to comment
Share on other sites

  • 0
6 minutes ago, slavergigi said:

Now it s ok just put on npcdata fnHi Server_Mager and no pos too

And let me now xD

 

there is fnHi before unsowing=1 in npcdata like this:

npc_ai={[server_manager]};{[fnHi]=[server_manager.htm]};

 

what do you mean no pos?

Link to comment
Share on other sites

  • 0

if you htm name is server_manager.htm is ok

7 minutes ago, girogius said:

 

there is fnHi before unsowing=1 in npcdata like this:


npc_ai={[server_manager]};{[fnHi]=[server_manager.htm]};

 

what do you mean no pos?

*on pos too

Link to comment
Share on other sites

  • 0
37 minutes ago, slavergigi said:

if you htm name is server_manager.htm is ok

*on pos too

 

bro there is problem in my htm s i just changed fnHi to zerstorer_morsell_q0281_08.htm (random htm that i found in html folder) and its workig.... which editor are you using what encoding and how do you save files? 

Edited by girogius
Link to comment
Share on other sites

  • 0
1 minute ago, girogius said:

 

Untitled.jpg

 

 

🥳🥳🥳🥳🥳

 

I guess you only editing existing htm files, i find out that when you creating new htm files   must be encoded as UCS-2 LE BOM, I was using UTF-8 

 

that was the problem. The End. 😄 😄 

 

Thank you for your help i appreciate it ❤️

 

 

 

yep i just copy another htm files, i think all do thats xD

Link to comment
Share on other sites

Guest
This topic is now closed to further replies.



  • Posts

    • the links are offiline, could you reupload them please, if you have other versions of h5 or c6 could you share them too, thanks!
    • Good afternoon everyone, we’ll get a couple of strong players in the CP, more details can be found here https://mw2.community/topic/211276-awr-team/  
    • so i bought this crap of the server few years back and i just found it laying around on my pc and i thought i should share it, if i remember correctly this crap has a lot of bugs that people abuse 🙂   https://drive.google.com/file/d/13QWg8pi4BPbGbTmlygZ078LjL6Fb0J2a/view?usp=sharing source   https://drive.google.com/file/d/13QWg8pi4BPbGbTmlygZ078LjL6Fb0J2a/view?usp=sharing system    
    • Error: Unable to access jarfile libs\Geodata_Converter_v01.jar
    • Since last massive leak as explained as 07/09 (notably all development branches), I don't accept anymore financial newcomers that easily. People will have to contribute 100 cookies worth of contributions (bug reports/fixes) as a first step to be accepted as Donator. Free user can join after sharing over 200 cookies out of contributions, compared to 100 cookies before. You can say thanks to RusAcis, and notably his worthless leader, UnleashedForce. The size of users will continue to shrink if more leaks occur, until true helpers only will be left. New prices are as following : Joining price: 200€ + 100 cookies, or 200 cookies This fee has to be paid if you are joining aCis project. Next month, and all other months, you will have to donate only basic monthly donation. Monthly price: 10€ / 10 cookies This fee has to be paid every month. I won't accept any new join fee before the 100 cookies contribution. Your money will be instantly sent back. Also, in the same shape of idea, actual supporters/donators have to be active to stay in sources. It doesn't have to be a particular amount, you just have to share from time to time *anything*. I don't accept anymore silent ppl. Only useful people will be kept.
  • Topics

×
×
  • Create New...