base.pwn question...
#1

ok in the base.pwn file that comes with the server there is a /pm ID (text) command. but if i add it into my gamemode i get 2 errors. any help
Reply
#2

give the exact error
Reply
#3

What are the errors?
Reply
#4

C:\Users\TJ's Server\Desktop\Server SA-MP\gamemodes\WEWFGRP.pwn(2901) : error 017: undefined symbol "strrest"
C:\Users\TJ's Server\Desktop\Server SA-MP\gamemodes\WEWFGRP.pwn(2901) : error 033: array must be indexed (variable "gMessage")
C:\Users\TJ's Server\Desktop\Server SA-MP\gamemodes\WEWFGRP.pwn(2930) : warning 209: function "OnPlayerCommandText" should return a value
Reply
#5

Add:
pawn Код:
new gMessage[256];
and:
pawn Код:
stock strrest(const string[], &index)
{
    new length = strlen(string);
    while ((index < length) && (string[index] <= ' '))
    {
        index++;
    }
    new offset = index;
    new result[128];
    while ((index < length) && ((index - offset) < (sizeof(result) - 1)))
    {
        result[index - offset] = string[index];
        index++;
    }
    result[index - offset] = EOS;
    return result;
}
For end, add "return 0;" in end of your "OnPlayerCommandText"!
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)