An4rchy Posted April 26, 2012 Posted April 26, 2012 There are mistakes :D The prepare() method should be called before the waitSecs(45) method(in handle() method). In register(L2PcInstance p) method, this line MUST be removed: state = State.REGISTERING; The inLHE boolean in L2PcInstance isn't needed, since there are not checks in L2PcInstance, but in my opinion there should have been some. There should have been checks in Logout and RequestRestart packets. This: + if (!(state == State.INACTIVE)) + { + { + while (state == State.REWARDING) + { + endAndReward(); + teleport(true); + } + } should have been coded in another way. First of all, in while loop there should have been a waitSecs(x)(where x put between 5-15), to avoid possible lags because of multiple checks. In endAndReward() method there should have been a check if both players are killed and if both are disconnected or 1 of them, to immediately stop the game. In clear() method, before you set player1 and player2 objects to null, you should set to false the inLHE boolean, since it exists. Also winner and loser objects are not needed. Quote
Fiou Posted April 26, 2012 Posted April 26, 2012 There are mistakes :D The prepare() method should be called before the waitSecs(45) method(in handle() method). In register(L2PcInstance p) method, this line MUST be removed: state = State.REGISTERING; The inLHE boolean in L2PcInstance isn't needed, since there are not checks in L2PcInstance, but in my opinion there should have been some. There should have been checks in Logout and RequestRestart packets. This: + if (!(state == State.INACTIVE)) + { + { + while (state == State.REWARDING) + { + endAndReward(); + teleport(true); + } + } should have been coded in another way. First of all, in while loop there should have been a waitSecs(x)(where x put between 5-15), to avoid possible lags because of multiple checks. In endAndReward() method there should have been a check if both players are killed and if both are disconnected or 1 of them, to immediately stop the game. In clear() method, before you set player1 and player2 objects to null, you should set to false the inLHE boolean, since it exists. Also winner and loser object are not needed. thx my friend ;) Quote
An4rchy Posted April 26, 2012 Posted April 26, 2012 thx my friend ;) No problem :). But this was for Ventic too.... Quote
disorder25 Posted April 27, 2012 Posted April 27, 2012 Anarchy can you post a patch with your corrections? Quote
An4rchy Posted April 27, 2012 Posted April 27, 2012 Anarchy can you post a patch with your corrections? Sorry, can't do it since there is no time. But it's easy since i fully explain where are the problems. Quote
DiNamO Posted June 10, 2012 Posted June 10, 2012 Thanks for keeping fixes up. Going to use it :) Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.