Posts: 129
Threads: 24
Joined: Dec 2014
Reputation:
0
Alright, that got rid of that issue however when I am getting a weird symbol is never used error stating that "EVENT_PLAYER" isn't used, however it clearly is right there so I am doubting that this method will even properly call the public. And also, what would be the best method of having one define parameter for all possible parameters(ofcourse excluding the function name) which in this case is playerid, vehicleid and ispassenger.
Posts: 141
Threads: 2
Joined: May 2014
Reputation:
0
11.04.2015, 19:38
(
Последний раз редактировалось R0; 11.04.2015 в 20:08.
)
I just checked the code ,remove the quotes from the first parameter,but i got a better idea for detecting events and also printing them,if you want me to post it then reply.
Posts: 129
Threads: 24
Joined: Dec 2014
Reputation:
0
Its not about "detecting events", it's mainly about an organized way of calling them and I already did that however the warning is still persistent. The only thing I don't understand is how "EVENT_PLAYER" can be unused, when it's used clearly - I also am stumped about an efficient use of having one parameter(%number) in the define to represent all the possible parameters, and at the same time call them properly to the public.
The only method of doing this I can imagine would be to call a public, or stock function which would directly call the callback / function based on the parameters given however I don't know how I can get the parameter specifiers for use in CallLocalFunction - and aswell this would probably not be a very efficient method of coding.
Posts: 10,066
Threads: 38
Joined: Sep 2007
Reputation:
0
The warning occurs because the line simply does not match your define pattern (using brackets () instead of braces {}). So you have just created yourself a function called EVENT_PLAYER which is never called and thus, according to the compiler, never used.
That said, I hardly think that this is "more organized". If anything, I think it makes things less organized. Besides, not every callback has 3 parameters so this thing can't be used for something like ExitVehicle.
Posts: 141
Threads: 2
Joined: May 2014
Reputation:
0
Thats why i told you that i got a better way,because your parameters wont match all of the callbacks.