u are checking if the time is exactly 12:00 with 0 seconds or 24:00 with 0 seconds, u got it? when u use the npc, and voted succesfully u save the DateTime in your database, so when u talk to the npc, the check must be
Code:
if(client.Entity.LastVote.AddHours(12) <= DateTime.Now)
{
client.Send(new Conquer_Online_Server.Network.GamePackets.Message("http://www.xtremetop100.com/in.php?site=1132310025", System.Drawing.Color.Yellow, 2105));
client.Entity.LastVote = DateTime.Now;
}
being LastVote a DateTime with the set and get properties
Code:
DateTime _LastVote
public DateTime LastVote
{
get{return _LastVote;}
set{Database.SaveVote(this);}
}
SaveVote voids to update the MySql database with "Entity" as param, and ofc reading the lastvote when loading the entity
that is the way i would do it at least