castle Posted March 26, 2009 Posted March 26, 2009 I did a search but did not find this: I would like the hospital and jail time to be standard for no matter what the reason. Say like 20 minutes...where do I find this in the code. Is it in the global file (version 2 by the way) Quote
AlabamaHit Posted March 26, 2009 Posted March 26, 2009 Re: Hospital/Jail Time v2 The values for them are in different pages. For jail you can just set it in the staff panel when making the crime. for hospital their are a few pages to edit. attackwon.php, attacklost.php, attackhospital.php files like taht.. Quote
castle Posted March 26, 2009 Author Posted March 26, 2009 Re: Hospital/Jail Time v2 how much time does this mean? $hosptime=rand(20,40)+floor($ir['level']/8); Quote
Carnage Posted March 27, 2009 Posted March 27, 2009 Re: Hospital/Jail Time v2 how much time does this mean? $hosptime=rand(20,40)+floor($ir['level']/8); It is not an exact amount. You can replace this part rand(20,40)+floor($ir['level']/8); with an exact amount if you like. Quote
Lithium Posted March 27, 2009 Posted March 27, 2009 Re: Hospital/Jail Time v2 how much time does this mean? $hosptime=rand(20,40)+floor($ir['level']/8); rand() generates a random value in between the 2 elements so lets say it generates a result of 30 floor() rounds down decimal values now lets say you are level 4 so 4/8 = 0.5 now floor(0.5) will return 0 that is going to produce a final result $hosptime = 30+0 $hosptime = 30 Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.