Game Elites is offering you all kind of Hacks, Bots, Tips and Tools.
 
HomeCalendarFAQSearchMemberlistUsergroupsRegisterLog in

Share | 
 

 [Release] Automatic Message Sender

View previous topic View next topic Go down 
AuthorMessage
LeGend
NOOB!
NOOB!
avatar

Posts : 18
Join date : 2009-05-09
Age : 24
Location : California

PostSubject: [Release] Automatic Message Sender   Sat May 09, 2009 5:45 pm

Is there really any name for this? Anyways, this is a simple release of how to send messages to the server. The timer is set to 4 minutes, and yeah I think it SHOULD work, if not post whats wrong and ill fix it, havent tested it.

For you who want to learn:
I set the timer at 4 minutes, 240000 milliseconds. Therefore, I start the timer and it all begins! When 4 minutes have gone, it will look up the void "MsgTimer_Elapsed". Once it find it, it will check if MsgCount is either 1,2,3 or 4. If its 4, it will put the MsgCount to 0. But now you are thinking, there isnt a msgcount check for the number zero, minimum is one?! Yeah, you're right, but if you look at the World.SendMsgToAll, under that it pluses the MsgCount, so it will automatically be 1 once its 0.







In General.cs:
Search for:
public static System.Timers.Timer Thetimer;
Under, add:

Code:
public static System.Timers.Timer MsgTimer;
public static int MsgCount = 1;

Search for:
Thetimer.Start();
Under, add:

Code:
MsgTimer = new System.Timers.Timer();
MsgTimer.Interval = 240000;
MsgTimer.Elapsed += new ElapsedEventHandler(MsgTimer_Elapsed);
MsgTimer.Start();

Now search for :
public static void DoStuff()

Above it, add:

Code:
public static void MsgTimer_Elapsed(object sender, ElapsedEventArgs e)
        {
            string text = "";
            if (MsgCount == 1)
                text = "Example 1";
            else if (MsgCount == 2)
                text = "Example 2";
            else if (MsgCount == 3)
                text = "Example 3";
            else if (MsgCount == 4)
            {
                MsgCount = 0;
                text = "Example 4";
        }
            World.SendMsgToAll(text, "[GM]", 2011);
            MsgCount++;
           
        }

Just edit the "Example" text to whatever you want server to say.

Enjoy
Back to top Go down
View user profile
 
[Release] Automatic Message Sender
View previous topic View next topic Back to top 
Page 1 of 1
 Similar topics
-
» How to capture the alert message in Selenium IDE
» Can't get the message from popup
» Can I check the error message displayed or not in Selenium?
» Slow release pain medication not interfering with triptans...
» Watermelon Studios Aims For A January 2nd Release of Pier Solar: HD For The Wii U eshop!

Permissions in this forum:You cannot reply to topics in this forum
Game-Elites :: Conquer Online 2 :: CO2 Programming-
Jump to: