AlabamaHit Posted February 3, 2008 Share Posted February 3, 2008 Im aware of a attack bug in V2 i was just wondering if someone might have a fix for it i avhe tried everthing i know what ot do.. can cant figure it out. Of course im not going to say the bug exactly but what i will say is its a bug where they can attack someoen no matter if they are in the same location or gang....For the people that know about this one will know what i mean any help would be greatly appreciated. Quote Link to comment Share on other sites More sharing options...
Klikoka Posted February 4, 2008 Share Posted February 4, 2008 Re: Attack Bug First Find : else if ($odata['hp'] < 5) { print "You can only attack those who have health"; $h->endpage(); exit; } Then Underneath Add : else if ($ir['gang'] == $odata['gang'] && $ir['gang'] > 0) { print "You are in the same gang as {$odata['username']}! What are you smoking today dude!"; $h->endpage(); exit; } Then Find : else if ($youdata['energy'] < $youdata['maxenergy']/2) { print "You can only attack someone when you have 50% energy"; $h->endpage(); exit; } Add Underneath : else if ($youdata['location'] != $odata['location']) { print "You can only attack someone in the same location!"; $h->endpage(); exit; } I Think Thats It Quote Link to comment Share on other sites More sharing options...
AlabamaHit Posted February 5, 2008 Author Share Posted February 5, 2008 Re: Attack Bug that is already in there.... Quote Link to comment Share on other sites More sharing options...
Klikoka Posted February 5, 2008 Share Posted February 5, 2008 Re: Attack Bug then i dont know sorry Quote Link to comment Share on other sites More sharing options...
QBD Posted February 6, 2008 Share Posted February 6, 2008 Re: Attack Bug I know of one attack bug that is found in V2 but i don't know if this is what you are looking for but it may help you and others.. Find in attacklost.php: <?php $atkpage=1; include "globals.php"; if ($ir['hospital'] > 0 || $ir['jail'] > 0) { die("You cannot access this page while you are in the hospital or in jail."); } $_GET['ID']==abs((int) $_GET['ID']); $_SESSION['attacking']=0; $_SESSION['attacklost']=0; Add this under the previous code as mentioned above: if($ir['attacking']==0) { print "WTF are you trying to do?"; $h->endpage(); $_SESSION['attacking']=0; $ir['attacking']=0; $db->query("UPDATE users SET attacking=0 WHERE userid=$userid"); exit; } Quote Link to comment Share on other sites More sharing options...
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.