Where ?
#1

pawn Код:
new AutoMessages[][] = {
Where should i put in the script a "new" state like this ?and should i make a stock or anything for it ?!
Reply
#2

I now get these errors:
pawn Код:
C:\Users\Mody\Desktop\Yea.pwn(13) : error 017: undefined symbol "AutoMessages"
C:\Users\Mody\Desktop\Yea.pwn(13) : error 017: undefined symbol "AutoMessages"
C:\Users\Mody\Desktop\Yea.pwn(13) : error 029: invalid expression, assumed zero
C:\Users\Mody\Desktop\Yea.pwn(13) : fatal error 107: too many error messages on one line

Compilation aborted.Pawn compiler 3.2.3664          Copyright (c) 1997-2006, ITB CompuPhase


4 Errors.
from line 10 to line 16:
pawn Код:
forward AutoMessage();
public AutoMessage() {
    new string[128];
    format(string, sizeof(string), "%s", AutoMessages[random(sizeof(AutoMessages))]);
    SendClientMessageToAll(COLOR_YELLOW2, string);
    return 1;
}
Reply
#3

PHP код:
new AutoMessages[][] = {
    
"Message",
    
"Message",
    
"Message",
    
"Message"
};
public 
OnFilterScriptInit()
{
    
SetTimer("SendAutoMessage",60000,1);
    return 
1;
}
forward public SendAutoMessage();
public 
SendAutoMessage() {
    new 
string[128];
    
format(string,sizeof(string),"%s",AutoMessages[random(sizeof(AutoMessages))]);
    
SendClientMessageToAll(-1,string);
    return 
1;

Reply
#4

Still get these errors:
pawn Код:
C:\Users\Mody\Desktop\Yea.pwn(13) : error 017: undefined symbol "AutoMessages"
C:\Users\Mody\Desktop\Yea.pwn(13) : error 017: undefined symbol "AutoMessages"
C:\Users\Mody\Desktop\Yea.pwn(13) : error 029: invalid expression, assumed zero
C:\Users\Mody\Desktop\Yea.pwn(13) : fatal error 107: too many error messages on one line

Compilation aborted.Pawn compiler 3.2.3664          Copyright (c) 1997-2006, ITB CompuPhase


4 Errors.
Reply
#5

try this, it is what i use to use.

Код:
new BugMessage;
forward Bug();
public Bug()
{
	if(!BugMessage)
	{
		SendClientMessageToAll(COLOR_LIME, "Found a bug? Report it using /reportbug and scripters will check it once possible.");
		BugMessage = 1;
	}
	else if(BugMessage == 1)
	{
		SendClientMessageToAll(COLOR_ORANGE, "Can't find the place you're looking for? /search has some useful locations.");
        BugMessage = 2;
	}
	else if(BugMessage == 2)
	{
		SendClientMessageToAll(COLOR_YELLOW, "You can request help from our community helpers using /helpme.");
		BugMessage = 3;
	}
	else if(BugMessage == 3)
	{
		SendClientMessageToAll(COLOR_RED, "Want to get free VIP packages? /refhelp.");
		BugMessage = 4;
	}
	else if(BugMessage == 4)
	{
		SendClientMessageToAll(COLOR_RED, "If you wish to have a stats refund, please visit www.zGaming.org and fill your request there.");
		BugMessage = 0;
	}
	return 1;
}
it says the bug stuff but it really is not.
Reply
#6

Please specify. What do you mean by OnPlayerConnect ? put what under it ?

EDIT: Trying it
Reply
#7

Quote:
Originally Posted by Red_Dragon.
Посмотреть сообщение
Please specify. What do you mean by OnPlayerConnect ? put what under it ?

EDIT: Trying it
I was wrong, Look at the change i did.
Reply
#8

Where did you place the code? The code is all seperate, not under any callbacks.
Reply
#9

It depends on how your script is setup.
Reply
#10

Michael, the one you gave me works, thanks but i need mine
Reply


Forum Jump:


Users browsing this thread: 2 Guest(s)