What I want to do is simple, however putting it into practise is not (at least it isn't easy for me (I'm self-taught btw).
I wish to have a method (it's invocation is irrelevant) that will get the id and authid of the calling player, then 1 minute later, pass those 2 pieces of data to another method.
This is my current attempt:
Code:
...
public one ( id ) {
//2-dim array intended to store "id" and "authid" seperately
new var[2][32]
format(var[0], 31, "%d", id)
get_user_authid(id, var[1], 31)
set_task(60.0, "two", _, var, 2)
}
public two ( param[2][32] )
client_print(0, print_chat, "0 = %s, 1 = %s", param[0], param[1])
I keep getting this error:
Welcome to the AMX Mod X 1.70-300 Compiler.
Copyright (c) 1997-2005 ITB CompuPhase, AMX Mod X Team
Error: Array dimensions do not match on line 28
1 Error.
Could not locate output file C:\1.amx (compile failed).
and it points to this line:
Code:
set_task(60.0, "two", _, var, 2)
I realise I could code this by:
1) Storing the id and authid into 2 global variables and have the second method access those global variables 1 minute later.
OR
2) Add the id, a wierd character and the authid to one string so it would appear as:
1*Steam_0:0:999999
and then ofcourse pass it to the second method where the 2 pieces of data would be seperated.
I know what I want can be done, I just want it done the way I am asking about.
Please can anyone help?
Eternal thanks,
Casio.