
another thing, but it`s not related to this video, why did u made the creatures disappear from the database if u kill them?
 the creatures should be infinite.
 the creatures should be infinite.
 the creatures should be infinite.
 the creatures should be infinite.thanksSakar wrote:Because in his game (and in future videos) he spawns creatures by using crons.

Code: Select all
        if ($playerinfo3['level'] > $creatureinfo3['level'])
        {
         $firstmod = $playerinfo3['level'] - $creatureinfo3['level'];
         $secondmod = $firstmod * 10 ;
         if ($secondmod > 90)($secondmod = 90);
         $thirdmod = ($secondmod / 100) * $creatureinfo3['exper'];
         $totalexper =$creatureinfo3['exper'] - $thirdmod;
        }
        else
        {
         $firstmod = $creatureinfo3['level'] - $playerinfo3['level'];
         $secondmod = $firstmod * 10 ;
         if ($secondmod > 90)($secondmod = 90);
         $thirdmod = ($secondmod / 100) * $creatureinfo3['exper'];
         $totalexper =$creatureinfo3['exper'] + $thirdmod;
        }
          $totalexper = (int)$totalexper
           echo "<br><big><b>You gain " . $totalexper . " experience.</b></big><br>";
          $updateplayer = "update players set exper = exper + '$totalexper' where name = '$player'";
         mysql_query ($updateplayer) or die ("Could not update player");Code: Select all
$totalexper = (int)$totalexper