#1

What's the difference between this:
PHP Code:
stock strlower(string[])
{
    for(new 
i=0string[i] != EOSi++)
        
string[i] = tolower(string[i]);
    return 
string;

and this:
PHP Code:
strlower(string[])
{
    for(new 
i=0string[i] != EOSi++)
        
string[i] = tolower(string[i]);
    return 
string;

What does the stock do?

Also, should I use stock?
Reply
#2

Youґre asking for a stock you dont know what itґs about and if you should use it? фФ
Reply
#3

if you have defined with stock & you are not using that function in script. compiler will not return any warning/error.
pawn Code:
stock strlower(string[])
{

    for(new i=0; string[i] != EOS; i++)
        string[i] = tolower(string[i]);
    return string;
}
if you are not using stock & you are not using that function in script. compiler will return warning/error.
pawn Code:
strlower(string[])
{

    for(new i=0; string[i] != EOS; i++)
        string[i] = tolower(string[i]);
    return string;
}
that is difference.
Reply
#4

https://sampwiki.blast.hk/wiki/Stocks
Reply
#5

Thanks guys
Reply
#6

That really is a terrible article. It's written as if the word "stock" and the word "function" can be used interchangeably. They can't.

There is ZERO need to use stock in a gamemode.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)