Mark deprecated natives with #pragma deprecated - 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)
+--- Thread: Mark deprecated natives with #pragma deprecated (
/showthread.php?tid=328921)
Mark deprecated natives with #pragma deprecated - Zeex_ - 26.03.2012
This way people will be warned about deprecated natives at compile time rather than run time:
Код:
warning 234: function is deprecated (symbol "AllowAdminTeleport")
To mark native as deprecated you need to put #pragma deprecated before native declaration:
pawn Код:
#pragma deprecated
native AllowAdminTeleport(allow);
Re: Mark deprecated natives with #pragma deprecated - T0pAz - 26.03.2012
Just mentioned on
this tutorial.
Re: Mark deprecated natives with #pragma deprecated -
playbox12 - 26.03.2012
Quote:
Originally Posted by T0pAz
Just mentioned on this tutorial.
|
Your point?
Re: Mark deprecated natives with #pragma deprecated -
MP2 - 26.03.2012
He means Kalcor should do this with AllowAdminTeleport and AllowPlayerTeleport, and I agree.
Re: Mark deprecated natives with #pragma deprecated -
IstuntmanI - 27.03.2012
Good idea, AttachPlayerObjectToPlayer also, and other removed old functions.
AW: Mark deprecated natives with #pragma deprecated -
Meta - 27.03.2012
But why the heck do you use them then?
Not used -> No error message