Author Topic: Welcome script  (Read 1362 times)

I'm starting to script and I was wondering if anyone would let me have a welcome script to look at some of the code.
Edit: By welcome script I mean a script that says something like "hi" when someone connects
« Last Edit: November 29, 2010, 05:49:16 PM by swollow »

Well, all you really have to do is download other scripts and study them. Also, I believe this is in the wrong section.

Well, all you really have to do is download other scripts and study them. Also, I believe this is in the wrong section.
I'm Trying to but its not helping I still need a welcome script and I guess this would go under coding help?

I have it, should I email it to you?

I have it, should I email it to you?
Pm please or just quote the script here

I am banned, and you may want the packaging?
Anyways:
Code: [Select]
package niceToGreetYou
{
function newChatHud_addLine(%text)
{
//Called when any line of text is added to the chat box
Parent::newChatHud_addLine(%text);
//This will turn the "Destiny connected." into "Destiny"
%nameToGreet = strReplace(%text," connected.","");
//If the %nameToGreet variable is different to the original line greet them,
//otherwise it's something else
if(%nameToGreet !$= %text)
{
//Send a chat message saying hi to the player who joined (%nameToGreet)
commandtoserver('messagesent',"Hey, " @ %nameToGreet);
}
}
};
activatePackage(niceToGreetYou);

like description txt and execute?
Ill be fine