hello,
i tried nasc but it is not very clear for me for the moment then i tried to do something with the old way:
Code:
push_event // i0
push_const 192
add
push_reg_sp
fetch_i
shift_sp 1
push_const 3 // [0-2]
func_call 55 // Rand
shift_sp -1
assign
shift_sp -1
L0
push_event
push_const 192
add
fetch_i
push_const 0 // if rand <= 0
less_equal
branch_false L1
shift_sp 1
(DO ACTION 0 IF rand <= 0)
shift_sp -1
jump L9 // goto end
L1
push_event
push_const 192
add
fetch_i
push_const 0 // if rand = 1
equal
branch_false L2
shift_sp 1
(DO ACTION 1 IF rand = 1)
shift_sp -1
jump L9 // goto end
L2
push_event
push_const 192
add
fetch_i
push_const 2 // if rand >= 2
greater_equal
branch_false L3
shift_sp 1
(DO ACTION 2 IF rand >= 2)
shift_sp -1
jump L9 // goto end
L3
L9 // end
i cant be sure it is correct because this AI display a PUSH CONST error about data TYPE. If you can just take a look at this part and tell me what you think it could help me maybe.
btw do you know, if it is possible, to do something like:
Code:
class my_class : my_parent_class
parameter_define_begin
int MyVar 0
parameter_define_end
handler X
push_parameter MyVar // 0
MyVar = Rand[0-9]
push_parameter MyVar // Rand[0-9] result
handler_end
class_end
Regards