[Release] Congratulate code

05/20/2009 23:41 Vortex.#1
Yeah whatever.. Just incase you wanted it.. I take no credit other than posting it..

Code:
if (Splitter[0] == "/congratulate")
           {
               World.SendMsgToAll("Congratulations to"+ Splitter[1]+" for winning the event" , "[SYSTEM]", 2011);
           }
Or if you want a foreach statment

Code:
if (Splitter[0] == "/congratulate")
                                        {
                                            foreach (DictionaryEntry DE in World.AllChars)
                                            {
                                                Character Char = (Character)DE.Value;
                                                if (Splitter[1] == Char.Name)
                                                {
                                                    World.SendMsg("Congratulations to "+ Splitter[1]+" for winning the event" , "[SYSTEM]", 2011);
                                                }
                                            }
                                        }
So when you type /congradulate Randomperson

[Only registered and activated users can see links. Click Here To Register...]

Then you get this

[Only registered and activated users can see links. Click Here To Register...]

This code was used by me as an event code..

Have fun

60% Of the credits go to BasicCoder
40% Go to me cause I posted half the code, then he edited it :D
05/20/2009 23:44 mohamedxxx#2
Nice Work Vortex
05/21/2009 00:00 BasicCoder#3
It would be nice if you would give credits.
05/21/2009 01:03 PeTe Ninja#4
good release i guess...

question though...wouldn't you want this after your event to the player who won and make it say automatically?
05/21/2009 01:08 Vortex.#5
@ PeTe Depend on the way your event is coded

@BasicCoder I forgot your name thats why
05/21/2009 01:12 PeTe Ninja#6
Quote:
Originally Posted by Vortex. View Post
@ PeTe Depend on the way your event is coded
well im pretty sure if you had a steady event then it is but if its like pk tourny on your own time then i see where you are going
05/21/2009 01:16 Vortex.#7
Yes.. I don't trust events which are not spectated by Admins
05/21/2009 01:49 reborn666#8
Vortex you sucks -.-
05/21/2009 02:35 Vortex.#9
lol? That was random
05/21/2009 03:04 PeTe Ninja#10
Quote:
Originally Posted by Vortex. View Post
Yes.. I don't trust events which are not spectated by Admins
i see you made a control pnael for your server , you need some help adding anything?
05/21/2009 03:14 Vortex.#11
Yeah.. I actually took it out.. But I could learn.. add me @ [Only registered and activated users can see links. Click Here To Register...]
05/21/2009 06:28 AndreaCo#12
why did you make it so long with the foreach loop??

you could have dont it

if (Splitter[1] == "/congradulate")
{
World.SendMsgToAll("Congradultions to " + Splitter[1] + " for winning the event", "SYSTEM", 2011);
}
# edit nevermind i didint see the first part... sorry i am really tired atm XD
05/21/2009 13:56 Vortex.#13
LOL, you are sexy!
05/26/2009 21:22 Vortex.#14
Oops