Hi elitepvp
i wanna code to make no use pots on map i want ..
i using source 5165..
what it should be ?
i wanna code to make no use pots on map i want ..
i using source 5165..
what it should be ?
Quote:
We're not here to program for you. It's a simple if else statement. Come on.
If you're really that useless, you probably shouldn't be running a server.
Quote:
newestco
public void UseItem(Item I)
{
try
{
if (I.ID >= 1000000 && I.ID <= 1002050) // mp and hp pots
{
if (!(DateTime.Now > UnableToUseDrugs.AddSeconds(UnableToUseDrugsFor)))
{
MyClient.LocalMessage(2005, "You've been poisoned. You cannot use drugs for a while.");
return;
}
else if (Loc.Map == 1002) // tc map
{
MyClient.LocalMessage(2005, "You cannot use drugs on this map !");
return;
}
}
Quote:
Code:public void UseItem(Item I) { try { if (I.ID >= 1000000 && I.ID <= 1002050) // mp and hp pots { if (!(DateTime.Now > UnableToUseDrugs.AddSeconds(UnableToUseDrugsFor))) { MyClient.LocalMessage(2005, "You've been poisoned. You cannot use drugs for a while."); return; } else if (Loc.Map == 1002) // tc map { MyClient.LocalMessage(2005, "You cannot use drugs on this map !"); return; } }