Jump to content
MakeWebGames

Recommended Posts

Guest Anonymous
Posted

Re: Money,crystals cap

 

ALTER TABLE `users`

CHANGE `money` `money` INT( 12 ) NOT NULL DEFAULT '0',

CHANGE `crystals` `crystals` INT( 12 ) NOT NULL DEFAULT '0',

CHANGE `bankmoney` `crystals` INT( 12 ) NOT NULL DEFAULT '0',

CHANGE `cybermoney` `crystals` INT( 12 ) NOT NULL DEFAULT '0'

ALTER TABLE `userstats`

CHANGE `strength` `strength` INT( 12 )NOT NULL DEFAULT '0',

CHANGE `IQ` `IQ` INT( 12 )NOT NULL DEFAULT '0',

CHANGE `agility` `agility` INT( 12 )NOT NULL DEFAULT '0',

CHANGE `guard` `guard` INT( 12 )NOT NULL DEFAULT '0',

CHANGE `labour` `labour` INT( 12 )NOT NULL DEFAULT '0',

Erm... INT(12) ??

Lets see, a standard 32-bit has range of -2147483648 to 2147483647 therefore INT(10) is actually the correct (and maximum) value here.

You may need to use BIGINT(12) - Although I'd have to look at the SQL docs to confirm this...

In fact, IMSMC, just INT or BIGINT suffice, the number in brackets is just the display size *not* the storage capacity - Again, check the docs, I may well be wrong here

  • Replies 67
  • Created
  • Last Reply

Top Posters In This Topic

Posted

Re: Money,crystals cap

 

`IQ` decimal(92,6) NOT NULL default '0.000000'

It really works i was testing it and my stats went up to:

Stats Info:

Strength: 99,214,223,234,200,011,344,822,808,748,263,406,361,903,104 [Ranked: 1]

LOL THATS A LOT

LOL!! Can (92,4) also be used on money/banks so you can have that much, instead of a 'tiny' cap of 9,223,372,036,854,775,807!! :-D :-D

Posted

Re: Money,crystals cap

 

`IQ` decimal(92,6) NOT NULL default '0.000000'

It really works i was testing it and my stats went up to:

Stats Info:

Strength: 99,214,223,234,200,011,344,822,808,748,263,406,361,903,104 [Ranked: 1]

LOL THATS A LOT

LOL!! Can (92,4) also be used on money/banks so you can have that much, instead of a 'tiny' cap of 9,223,372,036,854,775,807!! :-D :-D

To change how much you can keep in banks you just have to change (int) to (float)

Posted

Re: Money,crystals cap

Error

SQL query:

ALTER TABLE `userstats` CHANGE `strength` `strength` decimal( 50, 4 ) NOT NULL default '0.0000',

CHANGE `agility` `agility` decimal( 50, 4 ) NOT NULL default '0.0000',

CHANGE `guard` `guard` decimal( 50, 4 ) NOT NULL default '0.0000',

CHANGE `labour` `labour` decimal( 50, 4 ) NOT NULL default '0.0000',

CHANGE `IQ` `IQ` decimal( 50, 6 ) NOT NULL default '0.000000',

MySQL said: Documentation

#1064 - You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '' at line 6

  • 4 months later...
Posted

Re: Money,crystals cap

 

i know i sound like a n00b for asking this but where do i change the cap for sending money and bank money so people can send more then 2.1bill at a time

Assuming youve done everything else.

Open sendcash.php and sendbank.php change that part of it and it worked for me.On the sendbank.php it may be in a different spot then for sendcash.php I dont remember off hand, but still thats an idea of what you need to change.

<?php

include "globals.php";

$_GET['ID'] = abs((int) $_GET['ID']);

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

if(!((float)$_GET['ID']))

Posted

Re: Money,crystals cap

i use big int 11 if you get past the max on that then you need to look at the money in your game it should take a lifetime if you can actually code...

maybe people cheat...

but there is another option to change it to 9.3 quintrillion i believe but you'd have to ask Noelle that lol she's the only person i know who has money that high

but she knows what she's doing

Posted

Re: Money,crystals cap

just wondering if there is anyone that knows how to put a cap on the cmarket.php

so they don't put crystals at silly prices

any help would be appreciated

Thanks

  • 4 months later...
Posted

Re: Money,crystals cap

 

:x What did I say about the userstats; it is a DECIMAL!!!! they can be made bigger than an INT by changing the first value. Changing them to anything other than a decimal will mess up the stats.

err sorry dude but u are sadly mistaken as i have changed it from Decimal bigger then INT and oh yer it works fine so maybe ya shud think before you speak

Posted

Re: Money,crystals cap

 

just wondering if there is anyone that knows how to put a cap on the cmarket.php

so they don't put crystals at silly prices

any help would be appreciated

Thanks

cap on everything mate pm me on msn when you get on ill explain if needed.

float is used for decimals example %01.2f

...

Posted

Re: Money,crystals cap

 

:x What did I say about the userstats; it is a DECIMAL!!!! they can be made bigger than an INT by changing the first value. Changing them to anything other than a decimal will mess up the stats.

err sorry dude but u are sadly mistaken as i have changed it from Decimal bigger then INT and oh yer it works fine so maybe ya shud think before you speak

I did think. You clearly didn't as your sentence is incoherent and I can derive no meaning from it. Perhaps you should rephrase it?

  • 4 months later...
Posted

Re: [mccode] Money,crystals cap

Ok, i got the SQL part down

 

You're unable to view this code.

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

 

got some help from Emphesis,

change all the (int) values to (Float)

  • 1 month later...
Posted

Re: [mccode] Money,crystals cap

 

God this is not hard.

Here

 

You're unable to view this code.

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

 

... Stats are a decimal as well.....

Posted

Re: [mccode] Money,crystals cap

 

How do you get rid of the decimal places in userstats? It makes it look ugly!! aka...90210.113222434154.

When you start an account, with the lowest property, unless you change it to have even less will, it gives you 10 stat per train.

Change the db field to the decimal places you want DECIMAL (XX,amount_of_decimal_places)

Posted

Re: [mccode] Money,crystals cap

 

just wondering if there is anyone that knows how to put a cap on the cmarket.php

so they don't put crystals at silly prices

any help would be appreciated

Thanks

on item add file something along these lines

if ($_POST['price'] > max_value_for_item) { echo no pricing over max_value_for_item; exit; }

  • 9 months later...
Posted

Stats,And Level Cap

i had all my stats in the database set for BIGINT 25....and had up to bank cap in each stat....it wouldn't go up any higher....i changed all the int's to floats after changing the bigint's back to int 11,4 for all stats....and now i have a cap of 10mil per stat....so....not sure about anybody else,but i'm thinking the 92....what ever doesn't work.....i tried the 92 thing earlier,and the cap for it said was 65.....so do what ya want,but i'll stick with setting all my stats in the database to BIGINT 25....not sure how long somebody would have to play to even get bank cap in one stat....much less all of them....thanks for reading....RESPECT....Snake

Posted

Stats,And Level Cap

here is my example after i changed my user stats all to BIGINT 25 and the stats numbers 0.0000 changed to just 0

Strength: 10,000,000,000 [Ranked: 1]Agility: 20,000,000,000 [Ranked: 1]

Guard: 10,000,000,000 [Ranked: 1]Labor: 10,000,000,000 [Ranked: 1]

IQ: 10,000,000,000 [Ranked: 1]Total Stats: 60,000,000,000 [Ranked: 1]

....with the database set the way i have it,and all the int's changed to float's in the staff_users.php i get tril's in each stat,and tril's in hand money,and bank money

hope this helps somebody....all you haters can bite me,and not respond to this.....it's for ones who do not know

  • 4 months later...
Posted

This is what my database is like >>>

`userid` int(11) NOT NULL default '0',

`strength` decimal(65,4) NOT NULL default '0.0000',

`agility` decimal(65,4) NOT NULL default '0.0000',

`guard` decimal(65,4) NOT NULL default '0.0000',

`labour` decimal(65,4) NOT NULL default '0.0000',

`IQ` decimal(65,4) NOT NULL default '0.000000'

) ENGINE=MyISAM DEFAULT CHARSET=latin1;

 

`money` `money` int(11) NOT NULL DEFAULT '0',

`crystals` `crystals` int(11) NOT NULL DEFAULT '0',

`bankmoney` `bankmoney` int(11) NOT NULL DEFAULT '0',

 

And everything is maxed out at 2,147,483,647

How can i change this ?

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