Page 2 of 2

Re: Video #19

Posted: Mon Mar 01, 2010 10:17 pm
by zolacat999
Just watched this video, great nice to make some more progress and i think i understood most of it :D not got time to watch video 20 now will probably watch that tomorrow

Re: Video #19

Posted: Tue Mar 02, 2010 4:27 am
by Jackolantern
It is probably best to let video 19 soak in anyway. It is best for most people to only watch one or two a day at the most, and then sleep on it since that is supposedly when your brain organizes all of the data it absorbed for the day.

Re: Video #19

Posted: Tue Mar 02, 2010 5:23 am
by kevino58
when i go into the arena the battle.php doesnt pull a creature from the database

Re: Video #19

Posted: Tue Mar 02, 2010 2:51 pm
by hallsofvallhalla
i am looking at this issue today. Will have a "fix" up and some new videos.

Re: Video #19

Posted: Wed Mar 03, 2010 3:17 am
by kevino58
Why can't i add any weapons to the stores. And i am getting a error on my equipped .php it says unidentified index Local on line 27

Code: Select all

<?php
include_once 'connect.php';
 session_start();
   include_once 'logo.php';
   ?>
     <link href="style.css" rel="stylesheet" type="text/css" />
<?php
if (isset($_SESSION['player']))
{
  $player=$_SESSION['player'];
}
else
{
  echo "Not Logged in <br><br> <A href='login.php'>Login</a>";
  exit;
}
$playerinfo="SELECT * from players where name='$player'";
$playerinfo2=mysql_query($playerinfo) or die("could not get player stats!");
$playerinfo3=mysql_fetch_array($playerinfo2);
include_once 'statpanel.php';
$id=$playerinfo3['id'];
?>
</div>
<div id="table">
 <?php
	    $type=$_GET['type'];
		$local=$_GET['local'];
	   $randid=$_GET['randid'];

	   if ($type=="w")
	   {
	 $updateequip="Update playerweapons SET equip=0 WHERE pid='$id' AND equip=1";
	    mysql_query($updateequip) or die("Could not update equipment");	
		 $reequip="Update playerweapons set equip=1 where pid='$id' AND randid='$randid'";
	    mysql_query($reequip) or die("Could not update equipment2");	
		
		echo "<center><big><big>Weapon Equipped<br></big></big>";
		echo "<br><A href='index.php'>Go back</a>";
		}
		
		if ($type=="a")
	  {
	   	 $updateequip="Update playerarmor SET equip=0 WHERE pid='$id' AND equip=1 AND location='$local'";
	    mysql_query($updateequip) or die("Could not update armor");	
		
		 
		 $reequip="Update playerarmor set equip=1 where pid='$id' AND randid='$randid' AND location='$local'";
	    mysql_query($reequip) or die("Could not update armor2");	
		
		echo "<center><big><big>Armor Equipped<br></big></big>";
		echo "<br><A href='index.php'>Go back</a>";
		}
  
  ?>

</div>

 

Re: Video #19

Posted: Thu Jan 06, 2011 7:45 pm
by Shihonoryu
im getting:
Undefined variable: bypass in C:\wamp\www\Tutorial\index.php on line 60

Code: Select all

if($bypass != 1)
{
echo "<b><big><u>" . $playerinfo3['location'] . "</u></big></b><br>";
echo "<a href='store.php'>Visit Store</a><br>";
echo "<a href='weaponshop.php'>Visit Weapon Shop</a><br>";
echo "<a href='armorshop.php'>Visit Armor Shop</a><br>";
echo "<a href='inn.php'>Visit Inn</a><br>";
echo "<a href='spelltrainer.php'>Visit Spell Trainer</a><br>";
echo "<a href='battle.php'>Battle in Arena</a><br>";
echo "<a href='index.php?map=1'>Go to Map</a><br>";
}
Also getting these on armor shop and weapon shop

Re: Video #19

Posted: Thu Jan 06, 2011 10:19 pm
by hallsofvallhalla
somewhere at top of page, maybe after player query add

Code: Select all

$bypass = 0;