kuplion

[SOLVED] chatCommandsP help.

10 posts in this topic

I'm trying to do multiple ChatP commands with InfiSTAR, but I can't get more than one working.. Where am I going wrong here?

chatCommandsP[] =
{
    {"admin","If an admin is not online, please go to FriendlyPlayerShooting.com and post in the correct forum. We'll get back to you asap!"},
    {"vote","Day/Night vote is disabled on this server. But you can attach chemlights to yourself if you don't have NVG.."}
};

And the error:

9:01:17 "<infiSTAR.de> 0 - compiling AntiHack"
 9:01:17 Error in expression <g.com and post in the correct forum. We'll get back to you asap!"],["vote","Day/>
 9:01:17   Error position: <ll get back to you asap!"],["vote","Day/>
 9:01:17   Error Missing ;
 9:01:17 Error in expression <g.com and post in the correct forum. We'll get back to you asap!"],["vote","Day/>
 9:01:17   Error position: <ll get back to you asap!"],["vote","Day/>
 9:01:17   Error Missing ;
 9:01:17 "<infiSTAR.de> 0 - AntiHack loaded!"

 

Share this post


Link to post
Share on other sites
Advertisement
5 minutes ago, infiSTAR said:

Almost sure it's your single quote '

not tested that

try writing "we will" instead of "we'll"

I tested the single quote ' with just a single entry and it worked ok. I'll remove it completely and try again with two commands.

EDIT: Or could I escape the single quote?

Edited by kuplion

Share this post


Link to post
Share on other sites

I'll test now as well and if the case of ' or " within the text happens I will "backslash" it :D so no more problems with that for future versions

  • Like 1

Share this post


Link to post
Share on other sites
2 minutes ago, infiSTAR said:

I'll test now as well and if the case of ' or " within the text happens I will "backslash" it :D so no more problems with that for future versions

Cheers dude. :)

Share this post


Link to post
Share on other sites

This is working:

chatCommandsP[] =
{
    {"admin","If an admin is not online, please go to FriendlyPlayerShooting.com and post in the correct forum. We will get back to you asap!"},
    {"vote","Day-Night vote is disabled on this server. But you can attach chemlights to yourself if you do not have NVG.."}
};

One more question whilst you're around, where can I change the colour of these messages?

Share this post


Link to post
Share on other sites
Advertisement
Guest
This topic is now closed to further replies.

  • Recently Browsing   0 members

    No registered users viewing this page.