Page 1 of 1

Armors wont degrade?

Posted: Sun Feb 01, 2009 5:09 am
by Breg
Found my degrading code how where would I alter it to degrade abit faster and be it noticeable to players?

Code: Select all

						if (RandomInt (1000) == 1)
							defender_armor.hp := defender_armor.hp - 1;
							if (defender_armor.hp < 1)
								SendSysMessage (defender, "Your " + defender_armor.desc + " breaks!");
								DestroyItem (defender_armor);
							endif

Re: Armors wont degrade?

Posted: Sun Feb 01, 2009 12:56 pm
by Austin
If you want it to wear out in combat then you need to make it wear out in combat.

If you're using a combat hook, you need to do-so there.
If you use the older mainhitscript concept then wear it out there.

Re: Armors wont degrade?

Posted: Sun Feb 01, 2009 1:06 pm
by Breg
Can ya gimme an example of the code if I paste some of the combat hook here?

Re: Armors wont degrade?

Posted: Sun Feb 01, 2009 3:07 pm
by Austin