PK Arena

  • Nero
  • Nero's Avatar Topic Author
  • Offline
  • Premium Member
  • Premium Member
More
6 months 3 weeks ago #10056 by Nero
PK Arena was created by Nero
Wanting to setup my game to have PK arenas only. Does TBA have any documentation on how to set that up?

Please Log in or Create an account to join the conversation.

More
6 months 3 weeks ago #10057 by thomas
Replied by thomas on topic PK Arena
Well, there is an old contrib-file from the circlemud days about it: drive.google.com/file/d/0B40XbRH2Qbx5clV...nhEy6kK0R7evZ_p33TGw

Summed up, you'll need to tweak the checks for if aggression is allowed based on some kind of flag on the area you wish fighting to be allowed in.

Please Log in or Create an account to join the conversation.

  • Nero
  • Nero's Avatar Topic Author
  • Offline
  • Premium Member
  • Premium Member
More
6 months 3 weeks ago #10059 by Nero
Replied by Nero on topic PK Arena
Yeah this is the one I found and I didn't have much luck from most of these contrib files. I will try again and see if I can figure it out.

Please Log in or Create an account to join the conversation.

More
6 months 2 weeks ago #10062 by mr514
Replied by mr514 on topic PK Arena
There are a couple of examples in the circle mud code snippets archive, think they use a zone. Good luck!

Please Log in or Create an account to join the conversation.

  • Nero
  • Nero's Avatar Topic Author
  • Offline
  • Premium Member
  • Premium Member
More
2 months 1 week ago #10164 by Nero
Replied by Nero on topic PK Arena
So I was able to get the arena working by using some of that code. Instead of creating a zone though I just made a room flag and just enabled pk on the MUD. I then had to go to each skill, assist, etc and enter a flag to prevent the skills and damage spells from hitting a player if they are not in the Arena.

The only issue I am having is with AOE spells not working if two players are in the same room that is NOT arena
Under do_cast I used:
  if (!IS_NPC(victim) && !IS_NPC(ch) && !ROOM_FLAGGED(IN_ROOM(ch), ROOM_ARENA)) {
        /* disabled SCMD_MURDER */
        send_to_char(ch, "Go to an ARENA for that!\r\n");
        return (0);
  }

which seems to crash the game

So I went to magic.c and entered this snipped under int mag_damage (see screenshot)
which seems to work but one issue arises from it, if two players are in the same room that is NOT an Arena flag
The AOE spells are wonky..The issue is that it seems to be the AOE spell targets the last PC or NPC to enter the room,
So if a player walks into the room last and another player tries to cast an aoe spell in that room, an error comes up.
If a mob walks in the room while the victim player is still in the room, it is only going to target that first mob and no other mobs
Hopefully that makes sense see the screenshots.
 
Attachments:

Please Log in or Create an account to join the conversation.

More
2 months 1 week ago #10168 by thomas
Replied by thomas on topic PK Arena
How's the spell defined? This seems like it's not actually using the mag_areas code...

Please Log in or Create an account to join the conversation.

  • Nero
  • Nero's Avatar Topic Author
  • Offline
  • Premium Member
  • Premium Member
More
2 months 1 week ago - 2 months 1 week ago #10171 by Nero
Replied by Nero on topic PK Arena
I was able to roughly get this fixed. You are correct that was the wrong screenshot
Here is what I updated it to in the mag_areas:

    if (!IS_NPC(tch) && !IS_NPC(ch) && !ROOM_FLAGGED(IN_ROOM(ch), ROOM_ARENA)) {
        /* disabled SCMD_MURDER */
       // send_to_char(ch, "Go to an ARENA for that!\r\n");
        continue;
  }


This seems to be working sort of. I need to clean it up a bit still a few bugs.
Also trying to figure out how to fix issues where charmies can still attack players or other players charmies when they are NOT in the Arena rooms.
 
Last edit: 2 months 1 week ago by Nero.

Please Log in or Create an account to join the conversation.

Time to create page: 0.178 seconds