Jump to content
MakeWebGames

Recommended Posts

Posted

Not sure if it's out there or if there is an easier way but this will update the hospital count on the mainmenu instantly.

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

 

Last bit now:

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.

 

Just annoyed me that it never updated instantly so i made this quickly.

Posted

You're unable to view this code.

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

OR

You're unable to view this code.

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

Note not tested.

Then theres noting needed to be changed!

Posted

something like that i wouldn't format because i mean even with 2k members on your not getting a k members in hosital or jail and if you do it's probably better not to have the comma IMO

Hospital (1009)

Hospital (1,009)

  • 1 month later...
Posted

You're unable to view this code.

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

man in this code the the player who's busted get this code in mainmenu

Jail (Resource id #21)

Hospital (Resource id #20)

but the other players who is not in jail get this

 

 

You're unable to view this code.

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

who's in jail get this

Jail (1)

Hospital (1)

and other players who is not in jail get this

 

and BTW there is no one in hospital

so any idea ?

 

Posted

You're unable to view this code.

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

There are a lot of parameters to put in the where statement to put in the WHERE clause to make your game realistic, but then again, you could have a global count of the game, which wouldn't make it so realistic, but give the users more detail, it depends how you run your game, personally, i try and make my games as realistic as possible, but other people don't as it gives users a "time to get away".

Anyway, you can use whatever, some have already been posted in this topic, or you could use the below function.

You're unable to view this code.

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

 

There is a lot of ways you can do this, you could even use AJAX,JQUERY (or whatever, im not familiar with those languages) to fetch the result without refreshing the page.

-sniko

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