When using system timers for say inside an event that runs once per day, Should you always call Timer.Dispose() for each timer after the event ends and you have stopped the timers?
An event, that runs once a day? I don't think using a Timer for this occasion is very advisable. I don't know which source kids be using these days, but I'm sure it has a thread somewhere that checks events by DateTime stamps whether they should be called or not on each step. Perhaps that is the place, you should implement that daily event.
However, if you must use a Timer, you can call Dispose if you want. It should not matter that much, because the GarbageCollector should automatically dispose of it anyways, once it has lived its use, or am I wrong? (I imagine Timer's finalizer calls Dispose)
Im using Impluses Base 5165 Source, I have been using Timers in daily events and also for certain Player Quests where things are triggered at certain points or have time limits in them, I mainly started using them so everything was kept tidy and all stuff for each individual thing in 1 place for each given event or quest, There is a Thread that keeps check time wise for things like Buffs ect ect. Would there be any advantage to doing away with the timers and moving the timing part into the Thread mentioned above?
And the reason i asked about dispose was just i had someone looking over some code and when they saw Timer.Stop() said you should also use Timer.Dispose() after it, Which i havent been doing so i was just wondering again if that was the correct way to do it or if he was wrong.
Im using Impluses Base 5165 Source, I have been using Timers in daily events and also for certain Player Quests where things are triggered at certain points or have time limits in them, I mainly started using them so everything was kept tidy and all stuff for each individual thing in 1 place for each given event or quest, There is a Thread that keeps check time wise for things like Buffs ect ect. Would there be any advantage to doing away with the timers and moving the timing part into the Thread mentioned above?
And the reason i asked about dispose was just i had someone looking over some code and when they saw Timer.Stop() said you should also use Timer.Dispose() after it, Which i havent been doing so i was just wondering again if that was the correct way to do it or if he was wrong.
Like I said, it couldn't hurt to call Dispose yourself, but you don't have to either, because of GarbageCollector, that .Net has.
You're better off doing it yourself at some points. Not saying it's necessary in this case, but with streams and such it's highly recommended.
Ikr? Well if I am correct Impulse source had a lot of deadlock problems as well.
Deadlocks hardly. Race conditions, not really either. The source I released used one thread per client so they would be fairly rare. Though, a very well known problem would be the collection modified exceptions which is a result of a lack of locks which do exists in most sources.
Timers Question 05/07/2013 - CO2 Private Server - 1 Replies I've been using the following code for specific events to activate things at different times for everyone who is in the event which works fine.
But now im looking at using for something different and im wondering if there is a way to make it so that for every new player that goes through this it starts a new "TimerB" for each individual player rather than just altering it for every player thats gone through it?
public static System.Timers.Timer TimerB;
public static void...
Better way to set Autoinvite timers? 03/09/2013 - CO2 Private Server - 9 Replies Hello, I'm using a 5672 edited trinity base.
There are a lot of auto-invites timers for several events, but it's situated in Threading system, program.cs
this is kinda taking a lot of RAMs (+150mb on 0 players), even with a powerful host, ping is 200-500, it use to be less than 100 on other sources.
Do you suggest a better way to deal with these timers? to be honest, i've no idea what to do
Old Timers 10/03/2012 - Shaiya Private Server - 10 Replies Hey there Epvp been awhile sense i been around just looking around here. To see if i can find any old guildys or players from either Shaiya Evo or Shaiya Abso. My char name i used on those 2 was Syn or other variations of Syn for alt toons. On Evo i was guild leader of Requiem and on Abso i was guild leader of Damnation. So if any of u reconize the name or guilds from those servers hit me up looking to try and connect with some of u guys and gals from the past.
[Question/Request]Halo Timers 01/19/2010 - CO2 Private Server - 5 Replies has anyone made the save halo timer and if so could they be kindly and release it. ty
Mission Timers? 11/10/2008 - Ace Online / AirRivals - 15 Replies Ive seen it said a few times that you can slow down the mission timer for missions such as the Lv.8 Mission, and the ANI Lv.27 Mission.
Others claim such things are impossible :P
What im really looking to know is...
Is it Possible?, and How long can you remain in the mission map?
Im trying to use Cheat Engine 5.3 but i dont really got the hang of it yet.
and a little explination on how this works would be really helpful.
Please, and Thank You? :)