Blockland Forums > Modification Help

how to display variables?

Pages: << < (4/5) > >>

deathrider:

in game i can do /announce then a message but the problem is it only does one word. How can i make it do more than one word the code is the same above. Also how can i get a message displayed for the client all i can find is bottomprintall();. Last thing before i go to work, How can i enter color codes and font like <color:ffffff> like that for messages.

Honorable:

I made this a long time ago, I was going to make it into this huge fancy script. But I brushed it under the mat as soon as I got bored.


--- Code: ---//Made by Honor BLID_5235

function servercmdannounce(%client,%player,%message,%message2,%message3,%message4,%message5,%message6,%message7,%message8,%message10,%message11,%message12,%message13,%message14,%message15,%message16,%message17,%message18,%message19,%message20,%message21,%message22,%message23,%message24,%message25)
{
if(!%client.isAdmin)
{
messageclient(%client,'',"This command can only be used by Admins!");
return;
}

if(%player $= "all")
{
messageall('', "<bitmap:base/client/ui/ci/star> \c6<color:008000>" @ %client.getPlayerName() @ "\c3 <bitmap:base/client/ui/ci/star> \c6<color:FFDF00>" @ %message @ "\c6 \c3" @ %message2 @ "\c6 \c3" @ %message3 @ "\c6 \c3" @ %message4 @ "\c6 \c3" @ %message5 @ "\c6 \c3" @ %message6 @ "\c6 \c3" @ %message7 @ "\c6 \c3" @ %message8 @ "\c6 \c3" @ %message9 @ "\c6 \c3" @ %message10 @ "\c6 \c3" @ %message11 @ "\c6 \c3" @ %message12 @ "\c6 \c3" @ %message13 @ "\c6 \c3" @ %message14 @ "\c6 \c3" @ %message15 @ "\c6 \c3" @ %message16 @ "\c6 \c3" @ %message17 @ "\c6 \c3" @ %message18 @ "\c6 \c3" @ %message19 @ "\c6 \c3" @ %message20 @ "\c6 \c3" @ %message21 @ "\c6 \c3" @ %message22 @ "\c6 \c3" @ %message23 @ "\c6 \c3" @ %message24 @ "\c6 \c3" @ %message25);
serverplay3d(rewardSound,%client.player.getTransform());
}
}
--- End code ---

I must also mention, this may not be the best way to use messages. I made this like 1-2 years ago, I haven't touched it since. The script was originally going to be so you could write a few names in, and it would only broadcast to those people. I never finished it, and I worked on some other scripts.

I may also wanna mention, the sound system doesn't work. I am fully aware, and I do know how to fix it. (As I said, am just to bored. >.<)

deathrider:


--- Quote from: Honorable on April 07, 2012, 03:52:01 AM ---I made this a long time ago, I was going to make it into this huge fancy script. But I brushed it under the mat as soon as I got bored.


--- Code: ---//Made by Honor BLID_5235

function servercmdannounce(%client,%player,%message,%message2,%message3,%message4,%message5,%message6,%message7,%message8,%message10,%message11,%message12,%message13,%message14,%message15,%message16,%message17,%message18,%message19,%message20,%message21,%message22,%message23,%message24,%message25)
{
if(!%client.isAdmin)
{
messageclient(%client,'',"This command can only be used by Admins!");
return;
}

if(%player $= "all")
{
messageall('', "<bitmap:base/client/ui/ci/star> \c6<color:008000>" @ %client.getPlayerName() @ "\c3 <bitmap:base/client/ui/ci/star> \c6<color:FFDF00>" @ %message @ "\c6 \c3" @ %message2 @ "\c6 \c3" @ %message3 @ "\c6 \c3" @ %message4 @ "\c6 \c3" @ %message5 @ "\c6 \c3" @ %message6 @ "\c6 \c3" @ %message7 @ "\c6 \c3" @ %message8 @ "\c6 \c3" @ %message9 @ "\c6 \c3" @ %message10 @ "\c6 \c3" @ %message11 @ "\c6 \c3" @ %message12 @ "\c6 \c3" @ %message13 @ "\c6 \c3" @ %message14 @ "\c6 \c3" @ %message15 @ "\c6 \c3" @ %message16 @ "\c6 \c3" @ %message17 @ "\c6 \c3" @ %message18 @ "\c6 \c3" @ %message19 @ "\c6 \c3" @ %message20 @ "\c6 \c3" @ %message21 @ "\c6 \c3" @ %message22 @ "\c6 \c3" @ %message23 @ "\c6 \c3" @ %message24 @ "\c6 \c3" @ %message25);
serverplay3d(rewardSound,%client.player.getTransform());
}
}
--- End code ---

I must also mention, this may not be the best way to use messages. I made this like 1-2 years ago, I haven't touched it since. The script was originally going to be so you could write a few names in, and it would only broadcast to those people. I never finished it, and I worked on some other scripts.

I may also wanna mention, the sound system doesn't work. I am fully aware, and I do know how to fix it. (As I said, am just to bored. >.<)

--- End quote ---

so if i want more than one message i need alot of %message... aww but i do see message client witch is what i want but you never finished it as i can see no function to just send a message to that %client... am i right?

deathrider:

is there a fail safe because i cant do MY /commands in other peoples servers? also dont know why this does not work
--- Code: ---messageclient(%user,'',"Message from :" @ %client.name @ ": message: " @ %message);
--- End code ---


Treynolds416:


--- Quote from: deathrider on April 07, 2012, 04:22:34 AM ---is there a fail safe because i cant do MY /commands in other peoples servers? also dont know why this does not work
--- Code: ---messageclient(%user,'',"Message from :" @ %client.name @ ": message: " @ %message);
--- End code ---

--- End quote ---
You cannot do that on other servers because it is a server command and you are only a client on other servers

Pages: << < (4/5) > >>

Go to full version