OK, look, my custodiam AI, the part related to that... replace "..." with the original code...
You can set in params if ON or OFF, you can choose range to buff... etc, if you have the pet summoned... buffer will target your pet, if you want to buff yourself, send far the summon or dont have it summoned...is easy.
Code:
class 1 custodian : citizen
parameter_define_begin
...
...
...
int BuffSummon 1
int SummonRange 350
parameter_define_end
handler 32 6316 // MENU_SELECTED
variable_begin
...
...
...
"c0"
"c1"
variable_end
...
...
...
L6349
push_event // c0
push_const 344
add
push_reg_sp
fetch_i
push_event // talker
push_const 40
add
fetch_i
assign
shift_sp -1
push_event // c1
push_const 352
add
push_reg_sp
fetch_i
push_event // myself
push_const 704
add
fetch_i
push_event // talker
push_const 40
add
fetch_i
func_call 184614963 // func[GetSummon]
shift_sp -1
assign
shift_sp -1
push_event // c1
push_const 352
add
fetch_i
push_reg_sp
fetch_i
branch_false L9999917
push_parameter BuffSummon
and
L9999917
branch_false L9999916
L9999915
push_event // myself
push_const 704
add
fetch_i
push_event // c1
push_const 352
add
fetch_i
func_call 184614996 // func[DistFromMe]
shift_sp -1
push_parameter SummonRange
less
push_reg_sp
fetch_i
branch_false L9999919
L9999918
push_event // c0
push_const 344
add
push_reg_sp
fetch_i
push_event // myself
push_const 704
add
fetch_i
push_event // talker
push_const 40
add
fetch_i
func_call 184614963 // func[GetSummon]
shift_sp -1
assign
shift_sp -1
L9999919
L9999916
push_event // myself
push_const 704
add
fetch_i
push_event // c0
push_const 344
add
fetch_i
push_event // reply
push_const 164
add
fetch_i4
push_const 1
push_const 0
push_const 1000000
func_call 184877074 // func[AddUseSkillDesire]
shift_sp -5
shift_sp -1
...
...
...
handler_end
Quote:
Originally Posted by Kation
Is chamberlain a buffer? (i can see nothing to change in his ai - or if i forgot tell me what pls)
|
I just correct my post... i say chamberlain because is the name of the NPC, i was talking about steward class... class in charge of Clan Halls like Bandits
Anyway, your method is good too, a new option in the list... but im thinking what happen with your code if you try to buff a summon far away... or if it doesnt exist...