Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

"You are already in a competition /arena leave" Crashes server! #119

Closed
darrenstraight opened this issue Mar 7, 2013 · 7 comments
Closed

Comments

@darrenstraight
Copy link

Ok been trying to reproduce this, here's what I have so far.

Example 1

Config:

arena:
enabled: true
type: arena
database: arena
rated: false
prefix: "&6[Arena]&e"
nTeams: 2
teamSize: 1-12
matchTime: 300
preReqs:
options: [sameWorld]
onEnter:
options: [storeAll]
onLeave:
options: [restoreAll]
onPrestart:
options: [pvpOff, teleportWaitRoom, woolTeams]
onStart:
options: [teleportIn, blockBreakOff, pvpOn]
onSpawn:
options: [hunger=20, health=20]
onDeath:
options: [clearInventory]
onComplete:
options: [teleportOut, wgClearRegion]
winner:
options: [health=20, hunger=20]

Also set:

secondsTillBegin: 30
secondsTillMatch: 30
matchTime: 120
secondsToLoot: 0
matchUpdateInterval: 10
matchEnableForceStart: true
matchForceStartTime: 30

Log:

19:42:36 [INFO] darrenstraight issued server command: /arena j
19:42:44 [INFO] Infiniminer issued server command: /arena j
19:42:44 [INFO] [Arena] darrenstraight[0] vs Infiniminer[0]!
19:43:00 [INFO] [world] [Member] TheTimeMeddler: The two people above be are in the waiting room. I will try join.
19:42:53 [INFO] TheTimeMeddler issued server command: /arena j
19:43:00 [INFO] [world] [Member] TheTimeMeddler: It says "You have been added to a team"
19:44:10 [INFO] [world] [Member] TheTimeMeddler: Im killing myself
19:44:16 [INFO] [world] [Admin] darrenstraight: Im killing myself
19:44:23 [INFO] darrenstraight drowned
19:44:30 [INFO] TheTimeMeddler drowned
19:44:30 [INFO] [Arena] Infiniminer0 defeated TheTimeMeddler, darrenstra
ight0!
19:44:33 [INFO] [world] [Admin] darrenstraight: I am respawning after dying.
19:44:43 [INFO] [world] [Member] TheTimeMeddler: I am respawning after dying.
19:44:57 [INFO] [world] [Member] Infiniminer: I have been sent out of arena after winning.

We now all try and rejoin

19:45:04 [INFO] darrenstraight issued server command: /arena j
19:45:09 [INFO] Infiniminer issued server command: /arena j
19:45:14 [INFO] TheTimeMeddler issued server command: /arena j
19:45:18 [INFO] [world] [Admin] darrenstraight: I cant join
19:45:39 [INFO] [Arena] Infiniminer[0] vs TheTimeMeddler[0]!
19:45:43 [INFO] [world] [Admin] darrenstraight: Says You are already in a compe
tition /arena leave
19:45:57 [INFO] [world] [Admin] darrenstraight: If I type this server will cras
h
19:46:19 [INFO] darrenstraight issued server command: /arena leave

* SERVER CRASHED NO ERROS*

Example 2

Config (notice waiting room changed to onJoin, this is becuase I use class signs, in the previous example if players join after the matchForceStartTime then they dont get into waiting room before match begins so they cant choose a class, adding it here instead seems to fix problem, ideally would be nice if we could use onEnterQueue and have them sent to waiting room then)

Anyway, config:

arena:
enabled: true
type: arena
database: arena
rated: false
prefix: "&6[Arena]&e"
nTeams: 2
teamSize: 1-12
matchTime: 300
preReqs:
options: [sameWorld]
onEnter:
options: [storeAll]
onLeave:
options: [restoreAll]
onPrestart:
options: [pvpOff]
onJoin:
options: [teleportWaitRoom, woolTeams]
onStart:
options: [teleportIn, blockBreakOff, pvpOn]
onSpawn:
options: [hunger=20, health=20]
onDeath:
options: [clearInventory]
onComplete:
options: [teleportOut, wgClearRegion]
winner:
options: [health=20, hunger=20]

Also set:

secondsTillBegin: 30
secondsTillMatch: 30
matchTime: 120
secondsToLoot: 0
matchUpdateInterval: 10
matchEnableForceStart: true
matchForceStartTime: 30

Log:

20:02:03 [INFO] darrenstraight issued server command: /arena j
20:02:08 [INFO] Infiniminer issued server command: /arena j
20:02:33 [INFO] [Arena] darrenstraight[0] vs Infiniminer[0]!
20:02:41 [INFO] [world] [Member] TheTimeMeddler: The 2 people above me have joined and are in the waiting room. I will type /arena join
20:02:45 [INFO] TheTimeMeddler issued server command: /arena join
20:02:53 [INFO] [world] [Member] TheTimeMeddler: Im also in waiting room now.
20:04:12 [INFO] [world] [Member] TheTimeMeddler: We are all teleported out of waiting room and Im killing myself.
20:04:29 [INFO] [world] [Admin] darrenstraight: I too will kil myself
20:04:44 [INFO] TheTimeMeddler drowned
20:05:01 [INFO] darrenstraight drowned
20:05:01 [INFO] [Arena] Infiniminer0 defeated TheTimeMeddler, darrenstra
ight0!
20:05:05 [INFO] [world] [Member] TheTimeMeddler: I have respawned after dying.
20:05:12 [INFO] [world] [Admin] darrenstraight: I have respawned after dying.
20:05:20 [INFO] [world] [Member] Infiniminer: I have been sent out of arena after winning.

We now all try and rejoin

20:05:27 [INFO] darrenstraight issued server command: /arena join
20:05:33 [INFO] Infiniminer issued server command: /arena join
20:05:37 [INFO] TheTimeMeddler issued server command: /arena join
20:05:44 [INFO] [world] [Admin] darrenstraight: Th two others have joined, I cant it says:
20:06:03 [INFO] [Arena] Infiniminer[0] vs TheTimeMeddler[0]!
20:06:06 [INFO] [world] [Admin] darrenstraight: You are already in the competiom /arena leave
20:06:22 [INFO] [world] [Admin] darrenstraight: If I type /arena leave
20:06:26 [INFO] [world] [Admin] darrenstraight: It will crash server
20:06:29 [INFO] darrenstraight issued server command: /arena leave

* SERVER CRASHED NO ERROS*

Example 3

The way I have done it below works all ok with same config from above, notice we all joined at same time before the force start time ran out.

20:19:39 [INFO] [world] [Admin] darrenstraight: Joining queue
20:19:41 [INFO] darrenstraight issued server command: /arena j
20:19:49 [INFO] [world] [Member] Infiniminer: And me
20:19:53 [INFO] Infiniminer issued server command: /arena j
20:19:59 [INFO] [world] [Member] TheTimeMeddler: and me
20:20:02 [INFO] TheTimeMeddler issued server command: /arena j
20:20:12 [INFO] [Arena] TheTimeMeddler, darrenstraight[0] vs Infiniminer[0]!
20:20:23 [INFO] [world] [Admin] darrenstraight: We are all in waiting room
20:20:30 [INFO] [world] [Admin] darrenstraight: game starts in 30 seconds
20:21:20 [INFO] [world] [Member] TheTimeMeddler: Im killing myself
20:21:35 [INFO] [world] [Admin] darrenstraight: And me
20:21:52 [INFO] TheTimeMeddler drowned
20:22:00 [INFO] [world] [Member] TheTimeMeddler: Respawned
20:22:07 [INFO] darrenstraight drowned
20:22:07 [INFO] [Arena] Infiniminer0 defeated TheTimeMeddler, darrenstra
ight0!
20:22:15 [INFO] [world] [Admin] darrenstraight: Respanwed after dying.
20:22:21 [INFO] [world] [Member] Infiniminer: Respanwed after dying.
20:22:23 [INFO] [world] [Member] Infiniminer: I have been sent out of arena after winning.

Now we will all try rejoining/starting a new game

20:22:26 [INFO] darrenstraight issued server command: /arena j
20:22:29 [INFO] Infiniminer issued server command: /arena j
20:22:33 [INFO] TheTimeMeddler issued server command: /arena j
20:22:41 [INFO] [world] [Member] TheTimeMeddler: All 3 of us have joined fine and were placed in waiting room.
20:22:56 [INFO] [Arena] TheTimeMeddler, darrenstraight[0] vs Infiniminer[0]!

However

20:23:18 [INFO] [world] [Member] TheTimeMeddler: If someone was to join now whi
le we are in waiting room
20:23:18 [INFO] [world] [Member] TheTimeMeddler: they would join us
20:23:29 [INFO] [world] [Member] TheTimeMeddler: But latter would have the same
issue about trying to rejoin a new game and saying they are in it already. and to do /arena leave whch would crash server!

So....

For now only way I could work around it would be too:

  1. Increase force start time so gives everyone a chance to join.
  2. Only give players 10 seconds or so too quickly pick a class.
  3. Hope people dont join while others are in waiting room.

If everyone joins before prestart then theres no issues... but I cant stop someone trying to join after a prestart but before start! :s

Any suggestions?

Any other checks want me to do?

There's also been instances of players /arena leave within the waiting room/arena that cuased it also to bug, I quick fixed that problem by blocking the command /arena leave while they were in a match! :S

@darrenstraight
Copy link
Author

The above was in BattleArena_v3.7.9.9.8. I will try the latest version you have just released and see what happens.

@darrenstraight
Copy link
Author

Nope still crashes the server if they do /arena leave!

I could temp fix it if I could stop people doing /arena leave (if it was a permission or something) for those out of the arena but still saying they are still in it when trying to join.

Of course id have to restart server until they could rejoin BattleArena again, but at least it wouldnt crash server and involve me trying to have force stop/start server to try and get it working then finding out people have lost their inventories and even world changes becuase a chunk save hadent happened.

@darrenstraight
Copy link
Author

Further to my first post, I have tried different combinations above and can confirm:

  1. If everyone joins before the "matchForceStartTime: 30" ends (Queue countdown) then there will be no issues with those players trying to rejoin a new game after that one has ended.
  2. However if player A joins before "matchForceStartTime: 30" ends (Queue countdown) and then player B joins before "matchForceStartTime: 30" ends (Queue countdown). If player C joins after "matchForceStartTime: 30" ends (Queue countdownin), that is everyone is in now in the waiting room (The time between prestart and start) then when the game ends player A (The first person to join) will not be able to rejoin a new game, if he trys /arena leave - server crash.

Will continue to see if I can find a temp fix anyway! :s Wish could stop them typing /arena leave or not have them enter an arena if people are already in the waiting room! Sure that didnt happen before! :s

@alkarinv
Copy link
Owner

Hi Darren.

Sorry it took so long to get back to you.

I've been trying all day to replicate this and can't get it to work... can you hop on teamspeak or skype or somewhere where I can talk to you.

This is by far the best written crash report I've seen... and I want to fix the issue but I still cant recreate it.

@darrenstraight
Copy link
Author

Hi,

No problem, you can add me on skype: darrenstraight

Thank you,
Darren

@darrenstraight
Copy link
Author

Until then, if this helps, here's my config files minus the BattleArena.jar:

https://www.dropbox.com/s/sae40a93qidxdcg/BattleArena.zip

@alkarinv
Copy link
Owner

Hey Darren, So this is now fixed as of BattleArena 3.8+.

Thanks to you I found the issue and was able to get rid of it :)

cheers and thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants