Welcome to the Builder Academy

Question PK Arena

More
14 May 2022 08:12 #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
14 May 2022 12:48 #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.

More
14 May 2022 22:35 #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
18 May 2022 17:40 #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.

More
25 Sep 2022 03:37 #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:
Code:
  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
26 Sep 2022 21:51 #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.

Time to create page: 0.201 seconds