Jump to content
MakeWebGames

[mccode v2] Fight the good Fight


Uridium

Recommended Posts

Couldnt think of anything else to call this mod

But basically it stops the user from leaving a fight even when the page has been refreshed or when a new link is entered into the URL. They will be back at the attack screen until the fight is over.

Open up header.php

Find and remove this....

 

You're unable to view this code.

Viewing code within this forum requires registration, you can register here for free.

 

and replace with

 

You're unable to view this code.

Viewing code within this forum requires registration, you can register here for free.

 

Members can no longer evade a fighting..

Link to comment
Share on other sites

Re: [MOD] V2 Fight the good Fight

Good, but my idea would be just to add something where if the user tries to exit or closes the browser then next time they get the choice to continue battling or be a coward and run away, this would be a simple to make and it would be convenient as if the users browser crashes then they don't loose all their exp. Sorry for hi-jacking your post but it is relevant in it's own respect.

Link to comment
Share on other sites

Re: [MOD] V2 Fight the good Fight

 

Good, but my idea would be just to add something where if the user tries to exit or closes the browser then next time they get the choice to continue battling or be a coward and run away, this would be a simple to make and it would be convenient as if the users browser crashes then they don't loose all their exp. Sorry for hi-jacking your post but it is relevant in it's own respect.

stock attck is done in sessions......that would (Unless im mistaken) be impossible, without rewriting it withough using sessions

Link to comment
Share on other sites

Re: [MOD] V2 Fight the good Fight

 

Good, but my idea would be just to add something where if the user tries to exit or closes the browser then next time they get the choice to continue battling or be a coward and run away, this would be a simple to make and it would be convenient as if the users browser crashes then they don't loose all their exp. Sorry for hi-jacking your post but it is relevant in it's own respect.

Because we are removing this part from the header.php and replacing it with the other script your users wont lose EXP as its this that was causing it.

 

You're unable to view this code.

Viewing code within this forum requires registration, you can register here for free.

 

$db->query("UPDATE users SET exp=0,attacking=0 WHERE userid=$userid");

Link to comment
Share on other sites

Re: [mccode v2] Fight the good Fight

Good one mate. I have something similar, but I have also included another little sniplet there to avoid people from using 2 screens for example.

Some people are loading 2 browsers. 1 to attack and 1 to use their health packs to continue on healing themselves.

 

under illussions code add

You're unable to view this code.

Viewing code within this forum requires registration, you can register here for free.

 

+1 for you though. I am a great fan of your mods!

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...