Asking what is difference between stock and public
#1

Title, says it all.

What is the difference between the stock function ( when you're going to create a custom function yourself... ) and the public function.... I know that public needs to be forwarded like " forward NewFunction(parameter1, parameter2);
etc... but is there something else different?
Reply
#2

Stocks don't get compiled into the .amx unless they are used in code, saving you memory. Publics, on the other hand, are always compiled into the .amx and can be used in timers and in other scripts using CallRemoteFunction. I prefer using no function header.

pawn Код:
func()
{
    doStuff();
}
Reply
#3

Ok, thanks for your reply, it really helped alot.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)