For what is this function ? - Printable Version
+- SA-MP Forums Archive (
https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (
https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (
https://sampforum.blast.hk/forumdisplay.php?fid=12)
+---- Forum: Help Archive (
https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: For what is this function ? (
/showthread.php?tid=175473)
For what is this function ? -
zalecs - 10.09.2010
In GameModeInit
pawn Код:
call_by_gametype("init_classes");
call_by_gametype("init_vehicles");
call_by_gametype("init_objects");
In OnPlayerCommandText
pawn Код:
call_by_gametype(const function_prefix[])
{
new buff[255];
format(buff, sizeof(buff), "%s_%s", function_prefix, get_server_name(server_type));
CallLocalFunction(buff, "");
}
call_by_gametype_i(const function_prefix[], i1)
{
new buff[255];
format(buff, sizeof(buff), "%s_%s", function_prefix, get_server_name(server_type));
CallLocalFunction(buff, "i", i1);
}
If i want to add a new command (for example /kill) i get some errors from this functions.
Here is the errors :
Код:
C:\Users\Administrator\My Documents\Downloads\Compressed\srv-u1-mp-a-r8-win\gamemodes\simple.pwn(168) : error 017: undefined symbol "call_by_gametype"
C:\Users\Administrator\My Documents\Downloads\Compressed\srv-u1-mp-a-r8-win\gamemodes\simple.pwn(169) : error 017: undefined symbol "call_by_gametype"
C:\Users\Administrator\My Documents\Downloads\Compressed\srv-u1-mp-a-r8-win\gamemodes\simple.pwn(170) : error 017: undefined symbol "call_by_gametype"
C:\Users\Administrator\My Documents\Downloads\Compressed\srv-u1-mp-a-r8-win\gamemodes\simple.pwn(247) : warning 225: unreachable code
C:\Users\Administrator\My Documents\Downloads\Compressed\srv-u1-mp-a-r8-win\gamemodes\simple.pwn(319) : error 017: undefined symbol "call_by_gametype"
C:\Users\Administrator\My Documents\Downloads\Compressed\srv-u1-mp-a-r8-win\gamemodes\simple.pwn(319) : error 029: invalid expression, assumed zero
C:\Users\Administrator\My Documents\Downloads\Compressed\srv-u1-mp-a-r8-win\gamemodes\simple.pwn(319) : error 017: undefined symbol "function_prefix"
C:\Users\Administrator\My Documents\Downloads\Compressed\srv-u1-mp-a-r8-win\gamemodes\simple.pwn(319) : fatal error 107: too many error messages on one line
Compilation aborted.Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase
7 Errors.
Re: For what is this function ? -
Ne0 - 10.09.2010
this fuctions is for bugged your gamemode ...
so delete him!
Re: For what is this function ? -
Ne0 - 11.09.2010
hei guys please answer at zalecs question please i need your's help
thx guys
sorry for my bad english!
Re: For what is this function ? -
Voldemort - 11.09.2010
Its looks like zalecs, have a downloaded GM, where is missing some include, or if is copied, than its not cpied correct
Re: For what is this function ? -
Ne0 - 11.09.2010
I don't understand ....
I'm from romania!