Author Topic: servercmd  (Read 1669 times)

function servercmdnewsmod\c2 (%client){}
{
 \c2function severcmdnewsmod
}

{
$$newsmod::default=0; ("[Your Text Hear]");
$$newsmod::default=0; ("[Your Text Hear]");
};

I used to be able to make a mod like this but i dont remember it was like 5 months ago and
i need some help finishing it so can someone help?


???????????????????????????????????????????????????????????????????????????????????????????????????????????????
Please stop these horrid attempts at doing something and tell us what you want to do

Dude peolpe i just need some help fixing it to make it work

Dude peolpe i just need some help fixing it to make it work
THEN TELL US WHAT IT SHALL DO
goddamnit

read the the script basic helpmod but you say /news and news pops up in the chat

Code: [Select]
$newsline0 = "Really boring news";
$newsline1 = "More boring news";
$newsline2 = "Even more news";
$newsline3 = "Hi noobs";
$newsline4 = "End of news";
$newslinecount = 5;

function servercmdshownews(%client)
{
    messageclient(%client,'',"\c3Current news:");
    for(%i=0;%i<$newslinecount;%i++)
    {
        messageclient(%client,'',"\c3 - \c4" @ $newsline[%i]);
    }
}



should i feel ashamed of myself that i don't know what $(whatever) does

should i feel ashamed of myself that i don't know what $(whatever) does
Its a variable and the part aftert he $ is its name

Its a variable and the part aftert he $ is its name
oh.
so is there a difference between $ and %?
i know i'm not making much sense but im stupid

oh.
so is there a difference between $ and %?
i know i'm not making much sense but im stupid
$ are global variables, once they're defined, they're accessible anywhere.
% are local variables, they're only accessible within the function they're defined in
« Last Edit: September 12, 2012, 12:15:23 PM by Headcrab Zombie »

oh ok
i only kind of understand but still thankyun