View Single Post
Old 12.10.2005, 14:04   #11
Sauron
Архивный участник
 
Join Date: Feb 2005
Posts: 357
Default

Quote:
Originally Posted by krapno
tx for your answer but i have all about AI var/functions/handlers, what i need is how and when use them... atm i need to make a sort of:

Code:
if (item 60101 is owned) then
 dont give more
else
 give one item 60101
 take 600 adena
end

[php:1:8dae0dd365] shift_sp 1
push_event // talker
push_const 32
add
fetch_i
push_const 60101
func_call 81 // func[OwnItemCount]
shift_sp -2
push_const 0
equal
push_reg_sp
fetch_i
branch_false L0
shift_sp 1
push_event // talker
push_const 32
add
fetch_i
push_const 57
func_call 81 // func[OwnItemCount]
shift_sp -2
push_const 599
greater
and
L0
branch_false L2
L1
shift_sp 1
push_event // talker
push_const 32
add
fetch_i
push_const 60101
push_const 1
func_call 77 // func[GiveItem1]
shift_sp -3
shift_sp -1
shift_sp 1
push_event // talker
push_const 32
add
fetch_i
push_const 57
push_const 600
func_call 80 // func[DeleteItem1]
shift_sp -3
shift_sp -1
L2
[/php:1:8dae0dd365]
Sauron is offline