Jump to content

Ads

Members
  • Posts

    162
  • Joined

  • Last visited

    Never

Everything posted by Ads

  1. Why Not Just put the include in the parent frame?
  2. Is it a Frame set, or an Iframe?
  3. Close. OP: set this in the head of your document: <style type="text/css"> table { border-collapse: collapse: } </style> xD I had the right idea
  4. How Much Per Month, Would you expect to pay for a server? If you get a company to do it all for you?
  5. What is better, using a proper hosting site, or Your own?
  6. Lol i did, it made no Sense, >.> I am looking into Hosting a website, But i heard You can do Just as well off of a Personal Computer, Now i was interested by this, because this could save me a lot of Monthly fees, and hassle with a web hosting company. but i have no idea how to do something like this, So i was wondering if someone could give me some info on doing something like this. Maybe some things that i need to know and Just helpful hints .
  7. If they are better than Buying it form someone, how to do it is a big one lol Any Info you can provide me with.
  8. I was wondering if anyone could give me any details about these. Any Web sites on them or anything really.
  9. I think he wants it to onEnterKey To submit the Form instead on Going to the next text area.
  10. I would say it is Searching through The Form for the Whole string of Ichars. I am not that great With Java script So i don;t know for sure, but try Separating each Special Character with a Delimiter
  11. I think it is css, something like Border:collapse
  12. $id = $_GET['id']; Try that instead of $_POST['id]
  13. In my experience there is no difference between the two. I would guess that if you got down to specifics fetching by array *might* be a bit faster, but I think it would be so small it wouldn't affect your script at all. The difference is after you run your query with either: $row = mysql_fetch_object($result) or $row = mysql_fetch_array($result) you would reference your fields by $row->field or $row[index] I prefer using an Array. But that is Just me
  14. http://au2.php.net/mysql_fetch_assoc http://au2.php.net/mysql_fetch_object
  15. try taking out the Quotes around the to. $result = mysql_query("SELECT * FROM email WHERE to='$name'") or die(mysql_error()); Also test to see if the $result is working. if($result) { echo " Yay It works"; } else { echo "Sad, it doesn't work "; }
  16. to increase the font size of everything. body { font-size:13px } Change the 13 accordingly.
  17. Yeah that is kinda mean...look Ads ...I cant help you right now...I'm currently at work killing time in the forums...technically I can but no...not right now lol thats alright.
  18. Oh thats Mean, I made it thank You ^^
  19. <?php include "include/db.php"; $ID=$_GET['ID']; $oppstats3=mysql_fetch_array($oppplayerstats=mysql_query("SELECT * FROM players WHERE id='$ID'")); $oppstats1=mysql_query("SELECT * from mechs where playersid='$ID'"); $oppstats=mysql_fetch_array($oppstats1); //Oppenetns mech Stats $oppmechname=$oppstats['mechname']; $oppcharge=$oppstats['charge']; $oppdex=$oppstats['dexterity']; $opppow=$oppstats['power']; $oppdef=$oppstats['defence']; $oppweaponpow=$oppstats['weaponpower']; //Oppenets Player stats $oppref=$oppstats3['reflex']; $opptac=$oppstats3['tactics']; $oppluck=$oppstats3['luck']; //Your mech stats $mechname=$MECH['mechname']; $charge=$MECH['charge']; $dex=$MECH['dexterity']; $pow=$MECH['power']; $def=$MECH['defence']; $weaponpow=$MECH['weaponpower']; //Your Player stats $ref=$row['reflex']; $tac=$row['tactics']; $luck=$row['luck']; //******************************BATTLE CODE ****************************** while($oppcharge>0 && $charge>0){ //while Mechs are still alive if($oppdex>=$dex) //Openets Speed is Greater than or Equal to Your speed { if($oppcharge>0) { $randmultiplier = rand(0,10); $attackturns = 1000; while($attackturns>=10) { $oppdodge = ($oppref*rand(1,5))-$dex; $dodge = ($ref*rand(1,5))-$oppdex; $attackturns = $attackturns -$oppdex-$dex; if($dodge>$oppdodge) //Dodgeing { echo "<font color='blue'>".$mechname. " dodged " .$oppmechname. "</font><br>"; } else { // Amount of Damage $attackdamage = round((($oppweaponpow + $opppower)*($opptac/2))-$def*$randmultiplier); $criticaldamage = 0; $criticalchance = (($oppluck*6)/10); $criticalnumerator = rand(0,40); if($criticalnumerator<$criticalchance) // Critcal { echo "<font color='yellow'><b> ".$oppmechname. " hit " .$mechname. " for Critical Damage "; $criticaldamage = ($luck*$attackdamage)*30 ; $charge=$charge-$attackdamage-$criticaldamage; echo $criticaldamage. " - ".$charge." Health left <br></font></b>"; } else // Normal Damage { $oppcharge=$oppcharge-$attackdamage; echo"<font color='purple'>". $oppmechname . " hit " . $mechname . " for " . $attackdamage ."-".$oppcharge." Health left</font> <br>"; } if($oppcharge<=0) { $oppcharege==0; echo $oppmechname." wins<br>"; exit(); } } } } } else { if($charge>0) { echo $mechname. " retaliated <br>"; $oppdodge = (($oppref*rand(0,5))-$dex); $dodge = (($ref*rand(0,5))-$oppdex); if($dodge>$oppdodge) { echo $mechname ." dodged " .$oppmechname."<br>"; } else { $attackdamage = round((($weaponpow . $pow) * ($tac/2))-($oppdef*$randmultiplier)); echo $mechname." retaliated for ".$attackdamage." - ".$charge." Health left <br>"; if($charge<=0) { $charege==0; echo $mechname." wins<br>"; exit(); } } } } if($oppdex>=$dex) { if($charge>0) { $randmultiplier = rand(0,2); $attackturns = 1000; while($attackturns>=10) { $oppdodge = (($oppref*rand(0,5))-$dex); $dodge = (($ref*rand(0,5))-$oppdex); $attackturns = $attackturns-($dex-$oppdex); if($dodge>$oppdodge) { echo $oppmechname." dodged ".$mechname."<br>"; } else { $attackdamage = round((($weaponpow + $opppow)* ($tac/2))-($oppdef*$randmultiplier)); $criticaldamage = 0; $criticalchance = (($luck*6)/10); $criticalnumerator = rand(0,10); if($criticalnumerator<$criticalchance) { echo "<font color='green'><b> ".$mechname. " hit " .$oppmechname. " for Critical Damage "; $criticaldamage = ($luck*$attackdamage)/2; $charge=$charge-$attackdamage-$criticaldamage; echo $criticaldamage. " ".$charge." Health left <br></font></b>"; } else { $charge=$charge-$attackdamage-$criticaldamage; echo $mechname." hit ".$oppmechname." for" . $attackdamage . " - ".$charge." Health left <br>"; } if($charge<=0) { $charege==0; echo $mechname." wins<br>"; exit(); } } } } } else { if($oppcharge>0) { echo $oppmechname ." retaliated<br>"; $oppdodge = (($oppref*rand(0,5))-$dex); $dodge = (($ref*rand(0,5))-$oppdex); if($oppdodge<$dodge) { echo $oppmechname ." dodged " .$mechname."<br>"; } else { $attackdamage = round((($oppweaponpow + $opppow)*($opptec/2))-$def*$randmultiplier); echo $oppmechname. " retaliated for ".$attackdamage."-".$oppcharge." Health left <br>"; } if($oppcharge<=0) { $oppcharege==0; echo $oppmechname." wins<br>"; exit(); } } } } ?> <html> <head> <link href=style.css rel='stylesheet' type='css/text'> THere ya go
  20. What I tried to get to do is. Player 1 Clicks on a Link which Enter a Simple Text based Arena with player 2. And then it call all there stats(Health, Str,spd,agl,acc)[just Examples] and Passes them through some Algorithms To bring out a Result. Critcal and Counter inculded.
  21. My Code is a few Hundreds Lines Long, thats why i didn't Put it in the opening post. Is there any Base line I can follow, like the basics of writing on of these things
  22. Sorry xD I am making a PVP battle Arena, And I have already made my own But it Sucks bad, I have googled it a bit and come up with nothing of Much Help. So i was wondering if anyone where had any advice for when(if) i build another one. Or if there are any Good Tutorials out there.
  23. Now I have googled this, and alos made my own, and both came up Pretty Dodgy. So i was wondering if anyone can give me any Tips and Hints for when i make a new one, or any good Examples or Tuts that i can run by. Cheers, Ads
  24. I Use Javascript print "<script>"; print " self.location='main.php';"; // Comment this line if you don't want to redirect print "</script>";
  25. I am Confused as well >.>
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.