hi adding up depending on varables Please help!!!!!!

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
reecec
Forum Contributor
Posts: 218
Joined: Sun Apr 02, 2006 7:12 am

hi adding up depending on varables Please help!!!!!!

Post by reecec »

hi

for my game i am making an organised crime script i am not sure how to determin the amount of money made

i hope you can help

for the OC i want it so that you need 4 people

i person has the car
i person has the gun
i person has the bomb
i person is the leader


i need it depneding on rank and items used to determin how much is recived back

my ranks are numbers 1-19

1 being lowest

all my items have a number 1-10 to show quality 1 beign lowest same as ranks



i would like it so if every thing used and ranks are 1 (so the absolut basic) it would make £500,000


if all best are used (10) you would make £3,000,000

and in between it would jus caluculate this

this probably iisnt even posible

please help i hope im not asking of to much
Last edited by reecec on Wed Jun 14, 2006 1:07 pm, edited 1 time in total.
User avatar
John Cartwright
Site Admin
Posts: 11470
Joined: Tue Dec 23, 2003 2:10 am
Location: Toronto
Contact:

Post by John Cartwright »

you would try

Level 1 - 500,000
...
Level 5 - 1500000
...
Level 10, 2,750,000

Code: Select all

$cash = (($level+1) * 250000);
Your values arn't really linear.. that's the closest I could come up with. Then again.. I stopped taking math in grade 10.
reecec
Forum Contributor
Posts: 218
Joined: Sun Apr 02, 2006 7:12 am

hi thanks

Post by reecec »

thanks for you help


but i will have

4 people so (4 ranks)
4 items (4 items)


so 8 diferent things to depend on the amount


thanks

reece
Post Reply