Jump to content
MakeWebGames

[V2] Attacking Turns Shop


Recommended Posts

Guest Sniko`
Posted

My first ever modification on this forum was ammo, i decided to update for a game i am coding for.

This is a shop where you buy turns to attack

turns_shop.php

You're unable to view this code.

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

 

Add the link in explore

You're unable to view this code.

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

 

Add in header

You're unable to view this code.

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

 

Now in attack.php find

You're unable to view this code.

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

 

Replace with

You're unable to view this code.

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

 

Now in attackwon.php find

You're unable to view this code.

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

 

Replace with

You're unable to view this code.

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

 

SQL

You're unable to view this code.

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

change 30 to any number you want them to start off with

Thanks

Sniko

Posted

Re: [V2] Attacking Turns Shop

There is a problem with this:

When the members start of with some atk turns and they try and attack it say's they have none???

 

Same still when they buy the turns.

Posted

Re: [V2] Attacking Turns Shop

try this...

 

You're unable to view this code.

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

 

$r['attak_turns'] <= 1 is checking the turns of the member who is being attacked not the one attacking... should be $ir['attak_turns'] <= 1

Posted

Re: [V2] Attacking Turns Shop

Correction it shouldn't be ($ir['attk_turns'] <=1

Check the sql you need to put in it say's attk_turns

Here is the code for anyone who wants it:

You're unable to view this code.

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

Posted

Re: [V2] Attacking Turns Shop

i've not installed this so only helping by looking at the coding...

and you answered your own problem here...

 

You're unable to view this code.

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

 

don't you think

You're unable to view this code.

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

should match one another ?

Posted

Re: [V2] Attacking Turns Shop

 

don't you think

You're unable to view this code.

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

should match one another ?

The problem is people don't spend time looking at the code. copy/paste and its all done! then complain it doesn't work :)

Guest Sniko`
Posted

Re: [V2] Attacking Turns Shop

Sorry for the typo's with the attk_turns = attak_turns-1 i apologize

Posted

Re: [V2] Attacking Turns Shop

Don't apologise you've been good enough to share an idea and modification, personally i read the code through on any mod prior to installing it and any mods i have installed i've quite often re-modded them to fit my game...

At the end of the day you posted it for free, the bugs were spelling errors and pretty simple to spot...

  • 1 month later...

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...