RunUO Community

This is a sample guest message. Register a free account today to become a member! Once signed in, you'll be able to participate on this site by adding your own topics and posts, as well as connect with other members through your own private inbox!

Timer stop()

shade555

Wanderer
Timer stop()

Sorry guys a little question to you

When I do t.Stop(); ( where t is a timer, no matter what kind of timer)

My timer t is destroyed or it simply stop and continue to exist?
'cause I'm doing timers with this function, but I don't know if server could start lagging due to lots of timers stopped but not destroyed
 

Murzin

Knight
what happens is that the "timer" gets stopped.

the variable is not cleared.

the C# garbage system then flags it as eligible for deleting

when the garbage system deems system resources to be enough, it goes through its list of things to be deleted and actually deletes it making the variable null.

it still exists inside the C# internal heap, but is marked for deletion when the garbage cleanup cycle happens.

make sense?
 

Pure Insanity

Sorceror
C# is based a lot around java, that would be why. Microsoft started working on C# when Java decided to not allow Microsoft to not allow them to change what they wanted in Java. So Microsoft started their own language.

So if you can program in Java, then C# is very easy to pick up and learn.
 
Top