View Single Post
  #2  
Old 10-17-2008, 02:54 AM
AndMetal
Developer
 
Join Date: Mar 2007
Location: Ohio
Posts: 648
Default

I think this would be the easiest way:
Code:
if($mlevel >= (.34 * $ulevel)) {
	quest::say("Success!");
} else {
	quest::say("Not quite...");
}
However, if you're just trying to make it an even third (33.3%), you could also do it like this:
Code:
if($mlevel >= ($ulevel / 3)) {
	quest::say("Success!");
} else {
	quest::say("Not quite...");
}
Hope this helps.
__________________
GM-Impossible of 'A work in progress'
A non-legit PEQ DB server
How to create your own non-legit server

My Contributions to the Wiki
Reply With Quote