On Sun, 7 Apr 1996, Han A-Rum wrote: > Hi > > I want to know if it is possible to > limit pk(player kill) according to a > player's level. This is relatively easy to do, but can be pretty time consuming. Most of your work will be done in fight.c and magic.c. You just put checks in fight.c just before the hit is called like this: if (!IS_NPC(vict)) { if (GET_LEVEL(ch) >= 30 && GET_LEVEL(vict) >= 30) } Or however you want to do it. Our mud uses an OUTLAW flag which allows you to optionally be a player killer. We just check for that flag instead of checking for levels like you want to do. One thing to remember though. You have to put the check into EVERY offensive spell that you want not used on players. And if you have an arena area, you may want to make a check to see if the player is in the arena. One of the reasons this is so time-consuming is because you keep finding things you missed. If you forget to limit spells, then all your spell casters will be killing players while their victims can't hit back. Also remember to limit offensive skills like "kick" and "bash". Have fun, this one is cool, but can get frustrating :-) -Brian
This archive was generated by hypermail 2b30 : 12/18/00 PST