Jump to content
MakeWebGames

Recommended Posts

Posted

Re: BANK cap V2

off the top of my head...

change

$_POST['deposit']=abs((int) $_POST['deposit']);

to

$_POST['deposit']=abs($_POST['deposit']);

and

$_POST['withdraw']=abs((int) $_POST['withdraw']);

to

$_POST['withdraw']=abs($_POST['withdraw']);

  • 1 month later...
Posted

Re: BANK cap V2

I have a problem :( I followed what seany said, but it says you have (a higher amount than cap) in your bank. When i click city bank it says withdraw 2147483647, which is the cap. Please help me.

Posted

Re: BANK cap V2

* younggold abngs his hea don the table countless times....

what is it with noobs who come here expecting everything to be done for them...................

LEARN how to code or take your game down cause it will be pointless.

  • 4 weeks later...
Posted

Re: BANK cap V2

There are Two reasons for the 2.1B issue. What Seany said and what I said. If you still have the problem, then you are doing something wrong. My original response was in response to gurpreet.

If you are going negative, then you are withdrawing more money than you have and/or you have also not addressed the Int issues above.

  • 2 months later...
Posted

Re: BANK cap V2

You can leave (int) in the coding if you change the database table from int to bigint 25 or higher. This will allow php coding to max game money at 9.2 Quintillion. If you want it higher than that there is also more that can be done as well.

  • 3 weeks later...
Posted

Re: BANK cap V2

 

You can leave (int) in the coding if you change the database table from int to bigint 25 or higher.

Just doing for example

ALTER TABLE `crystalmarket`

CHANGE `cmPRICE` `cmPRICE` BIGINT( 25 ) DEFAULT '0' NOT NULL

doesn't cut it. It still lists them at 2147...unless in the script you do a few small changes, changing int to float...

$each= (float) $r['cmPRICE'] / $r['cmQTY'];

$_POST['amnt'] = abs((float) $_POST['amnt']);

$_POST['price'] = abs((float) $_POST['price']);

Then it's pro massive inflation!

  • 1 year later...
Posted

Re: BANK cap V2

for future references you can do it this way

change

$_POST['deposit']=abs((int) $_POST['deposit']);

to

$_POST['deposit']=abs((BIGINT) $_POST['deposit']);

and

$_POST['withdraw']=abs((BIGINT) $_POST['withdraw']);

to

$_POST['withdraw']=abs((BIGINT) $_POST['withdraw']);

or you can use

$_POST['deposit']=abs((int) $_POST['deposit']);

to

$_POST['deposit']=abs((float) $_POST['deposit']);

and

$_POST['withdraw']=abs((BIGINT) $_POST['withdraw']);

to

$_POST['withdraw']=abs((float) $_POST['withdraw']);

keep in mind your still going to need to adjust it in your phpmyadmin

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