can u make the script more orderly and nice?so its easy for me to edot that skrip..plz khan...tq
Adventure Game
Version: 1.0.0
Category: Other useful scripts
Description:
lavalair game script xhtml ver
[Only registered and activated users can see links. Click Here To Register...]
/tease.gif" style="vertical-align:middle" emoid="" border="0" alt="tease.gif" />t;line-height:100%">Submitted by khan1, on Apr 18 2008, 02:11 AM
can u make the script more orderly and nice?so its easy for me to edot that skrip..plz khan...tq
here 1 for lavalair ..
Code:<?php header("Content-type: text/vnd.wap.wml"); header("Cache-Control: no-store, no-cache, must-revalidate"); echo "<?xml version=\"1.0\"?>"; echo "<!DOCTYPE wml PUBLIC \"-//WAPFORUM//DTD WML 1.1//EN\"". " \"http://www.wapforum.org/DTD/wml_1.1.xml\">"; ?> <wml> <?php include("config.php"); include("core.php"); connectdb(); $action = $_GET["action"]; $sid = $_GET["sid"]; $page = $_GET["page"]; $who = $_GET["who"]; $sitename = mysql_fetch_array(mysql_query("SELECT value FROM ibwf_settings WHERE name='sitename'")); $sitename = $sitename[0]; $lastloc=$_GET["lstloc"]; if($lastloc=="cht"){ $rid= $_GET["rid"]; $rooms = mysql_fetch_array(mysql_query("SELECT id, name FROM ibwf_rooms WHERE id='".$rid."'")); $rname = $rooms[1]; } if(islogged($sid)==false) { echo "<card id=\"main\" title=\"$sitename\">"; echo "<p align=\"center\">"; echo "You are not logged in "; echo "Or Your session has been expired "; echo "<a href=\"index.php\">Login</a>"; echo "</p>"; echo "</card>"; echo "</wml>"; exit(); } $uid = getuid_sid($sid); if(isbanned($uid)) { echo "<card id=\"main\" title=\"$sitename\">"; echo "<p align=\"center\">"; echo "<img src=\"../images/notok.gif\" alt=\"x\"/> "; echo "You are Banned "; $banto = mysql_fetch_array(mysql_query("SELECT timeto, pnreas, exid FROM ibwf_penalties WHERE uid='".$uid."' AND penalty='1' OR uid='".$uid."' AND penalty='2'")); $banres = mysql_fetch_array(mysql_query("SELECT lastpnreas FROM ibwf_users WHERE id='".$uid."'")); $remain = $banto[0]- time(); $rmsg = gettimemsg($remain); echo "Time Left: $rmsg "; $nick = getnick_uid($banto[2]); echo "By: $nick "; echo "Reason: $banto[1]"; //echo "<a href=\"index.php\">Login</a>"; echo "</p>"; echo "</card>"; echo "</wml>"; exit(); } if($action=="main") { addonline(getuid_sid($sid),"Play Kingdom WAR","kingdom.php?action=main"); echo "<card id=\"main\" title=\"Kingdom WAR\">"; echo "<p align=\"center\">"; echo "Kingdom WAR"; echo " "; echo "Now lets see your power to get the power of the WAR !"; echo "</p>"; echo "<p align=\"left\">"; echo "Choose your dungeon:"; echo " "; echo "<a href=\"kingdom.php?action=a&sid=$sid\">Kirupa Island</a>"; echo " "; echo "<a href=\"kingdom.php?action=b&sid=$sid\">Kiran Island</a>"; echo " "; echo "<a href=\"kingdom.php?action=c&sid=$sid\">Fire Dungeon</a>"; echo " "; echo "</p>"; echo "<p align=\"center\">"; echo "<a href=\"fun.php?action=main&sid=$sid\">Fun Menu</a>"; echo " "; echo "<a href=\"index.php?action=main&sid=$sid\"><img src=\"../images/home.gif\" alt=\"\"/>Home</a>"; echo "</p>"; echo "</card>"; } else if($action=="a") { addonline(getuid_sid($sid),"Play Kingdom WAR","kingdom.php?action=main"); echo "<card id=\"main\" title=\"Kingdom WAR\">"; echo "<p align=\"center\">"; echo "Kingdom WAR"; echo " "; echo "Now your character have a armored and magical tactics. Try kill your enemy and earn the plusess"; echo "</p>"; echo "<p align=\"left\">"; echo ""; $num1 = rand(1, 5); $uid = mysql_fetch_array(mysql_query("SELECT uid FROM ibwf_ses WHERE id='".$sid."'")); $uid = $uid[0]; $usrid = $uid; $time = time(); echo "<a href=\"kingdom.php?action=$action&sid=$sid&time=$time\">Axe</a> , <a href=\"kingdom.php?action=$action&sid=$sid&time=$time\">Bash</a> , <a href=\"kingdom.php?action=$action&sid=$sid&time=$time\">Thunder Bolt</a>"; echo " "; $ugpl = mysql_fetch_array(mysql_query("SELECT plusses FROM ibwf_users WHERE id='".$uid."'")); $ugpl = $ugpl[0]; echo "Golden Plusses: $ugpl "; $power = rand(50,100); echo "Power: $power "; echo " "; $damage = rand(0,50); $evil = Kirupa; $gold = rand(30,50); if ($num1 == 1) { $num = rand(1, 3); echo "You hit $evil with damage $damage. You've Won $gold Gold!"; $ugpl = mysql_fetch_array(mysql_query("SELECT plusses FROM ibwf_users WHERE id='".$uid."'")); $ugpl = $ugpl[0]; $ugpl2 = $ugpl + "$gold"; mysql_query("UPDATE ibwf_users SET plusses='".$ugpl2."' WHERE id='".$uid."'"); echo " "; } if ($num1 == 2) { $num = rand(1, 3); echo "You hit $evil with damage $damage,but he return 2 kick for you with damage $gold. You've been attacked and Lost $gold gold!"; $ugpl = mysql_fetch_array(mysql_query("SELECT plusses FROM ibwf_users WHERE id='".$uid."'")); $ugpl = $ugpl[0]; $ugpl2 = $ugpl - "$gold"; mysql_query("UPDATE ibwf_users SET plusses='".$ugpl2."' WHERE id='".$uid."'"); echo " "; } if ($num1 == 3) { $num = rand(1, 3); echo "You hit $evil damaging him $damage %. Then $evil return magic attack to you, damaging you $damage %. You draw! Minus 10 plusses for that attack"; $ugpl = mysql_fetch_array(mysql_query("SELECT plusses FROM ibwf_users WHERE id='".$uid."'")); $ugpl = $ugpl[0]; $ugpl2 = $ugpl - "10"; mysql_query("UPDATE ibwf_users SET plusses='".$ugpl2."' WHERE id='".$uid."'"); echo " "; } if ($num1 == 4) { $num = rand(1, 3); echo "You hit $evil with a damage of $damage %. Then $evil return a scratch attack to you $gold %. You draw! Minus $gold plusses for that attack"; $ugpl = mysql_fetch_array(mysql_query("SELECT plusses FROM ibwf_users WHERE id='".$uid."'")); $ugpl = $ugpl[0]; $ugpl2 = $ugpl - "$gold"; mysql_query("UPDATE ibwf_users SET plusses='".$ugpl2."' WHERE id='".$uid."'"); echo " "; } if ($num1 == 5) { $num = rand(1, 3); echo "You hit $evil damaging him 0%. Miss... Miss! Miss! Minus 10 plusses for that attack"; $ugpl = mysql_fetch_array(mysql_query("SELECT plusses FROM ibwf_users WHERE id='".$uid."'")); $ugpl = $ugpl[0]; $ugpl2 = $ugpl - "10"; mysql_query("UPDATE ibwf_users SET plusses='".$ugpl2."' WHERE id='".$uid."'"); echo " "; } echo ""; echo "</p>"; echo "<p align=\"center\">"; echo "<a href=\"kingdom.php?action=main&sid=$sid\">Kingdom WAR</a>"; echo " "; echo "<a href=\"fun.php?action=main&sid=$sid\">Fun Menu</a>"; echo " "; echo "<a href=\"index.php?action=main&sid=$sid\"><img src=\"../images/home.gif\" alt=\"\"/>Home</a>"; echo "</p>"; echo "</card>"; } else if($action=="b") { addonline(getuid_sid($sid),"Play Kingdom WAR","kingdom.php?action=main"); echo "<card id=\"main\" title=\"Kingdom WAR\">"; echo "<p align=\"center\">"; echo "Kingdom WAR"; echo " "; echo "Now your character have a armored and magical tactics. Try kill your enemy and earn the plusess"; echo "</p>"; echo "<p align=\"left\">"; echo ""; $num2 = rand(1, 9); $uid = mysql_fetch_array(mysql_query("SELECT uid FROM ibwf_ses WHERE id='".$sid."'")); $uid = $uid[0]; $usrid = $uid; $time = time(); echo "<a href=\"kingdom.php?action=$action&sid=$sid&time=$time\">Bow</a> , <a href=\"kingdom.php?action=$action&sid=$sid&time=$time\">Deviling</a> , <a href=\"kingdom.php?action=$action&sid=$sid&time=$time\">Fire Storm</a>"; echo " "; $ugpl = mysql_fetch_array(mysql_query("SELECT plusses FROM ibwf_users WHERE id='".$uid."'")); $ugpl = $ugpl[0]; echo "Golden Plusses: $ugpl "; $power = rand(50,100); echo "Power: $power "; echo " "; $damage = rand(0,100); $evil2 = Darklord; $gold = rand(30,100); $magic = rand(60,93); $level = 2; $level2 = 3; $low = 1; if ($num2 == 1) { $num = rand(1, 3); echo "You hit $evil2 with damage $damage. You've Won $gold Gold!"; $ugpl = mysql_fetch_array(mysql_query("SELECT plusses FROM ibwf_users WHERE id='".$uid."'")); $ugpl = $ugpl[0]; $ugpl2 = $ugpl + "$gold"; mysql_query("UPDATE ibwf_users SET plusses='".$ugpl2."' WHERE id='".$uid."'"); echo " "; } if ($num2 == 2) { $num = rand(1, 3); echo "You hit $evil2 with damage $damage,but he return 2 body and $low high kick for you with damage $gold. You've been attacked and Lost $gold gold!"; $ugpl = mysql_fetch_array(mysql_query("SELECT plusses FROM ibwf_users WHERE id='".$uid."'")); $ugpl = $ugpl[0]; $ugpl2 = $ugpl - "$gold"; mysql_query("UPDATE ibwf_users SET plusses='".$ugpl2."' WHERE id='".$uid."'"); echo " "; } if ($num2 == 3) { $num = rand(1, 3); echo "You cast magic $magic % with a hit to $evil2 damaging him $damage %. Then $evil2 return magic attack to you, damaging you $damage %. You draw! Minus 10 plusses for that attack"; $ugpl = mysql_fetch_array(mysql_query("SELECT plusses FROM ibwf_users WHERE id='".$uid."'")); $ugpl = $ugpl[0]; $ugpl2 = $ugpl - "10"; mysql_query("UPDATE ibwf_users SET plusses='".$ugpl2."' WHERE id='".$uid."'"); echo " "; } if ($num2 == 4) { $num = rand(1, 3); echo "You hit $evil2 with a damage of $damage %. Then $evil2 return dark spell attack to you $gold %. You draw! Minus $gold plusses for that attack"; $ugpl = mysql_fetch_array(mysql_query("SELECT plusses FROM ibwf_users WHERE id='".$uid."'")); $ugpl = $ugpl[0]; $ugpl2 = $ugpl - "$gold"; mysql_query("UPDATE ibwf_users SET plusses='".$ugpl2."' WHERE id='".$uid."'"); echo " "; } if ($num2 == 5) { $num = rand(1, 3); echo "You hit $evil2 damaging him 0%. Miss... Miss! Miss! Minus 10 plusses for that attack"; $ugpl = mysql_fetch_array(mysql_query("SELECT plusses FROM ibwf_users WHERE id='".$uid."'")); $ugpl = $ugpl[0]; $ugpl2 = $ugpl - "10"; mysql_query("UPDATE ibwf_users SET plusses='".$ugpl2."' WHERE id='".$uid."'"); echo " "; } if ($num2 == 6) { $num = rand(1, 3); echo "You hit $evil2 damaging him 100%. level up $level2. You are a GODLIKE! Plus 90 plusses for that attack"; $ugpl = mysql_fetch_array(mysql_query("SELECT plusses FROM ibwf_users WHERE id='".$uid."'")); $ugpl = $ugpl[0]; $ugpl2 = $ugpl + "90"; mysql_query("UPDATE ibwf_users SET plusses='".$ugpl2."' WHERE id='".$uid."'"); echo " "; } if ($num2 == 7) { $num = rand(1, 3); echo "You hit $evil2 damaging him 40%. Level up to $level You win 50 plusses for that attack"; $ugpl = mysql_fetch_array(mysql_query("SELECT plusses FROM ibwf_users WHERE id='".$uid."'")); $ugpl = $ugpl[0]; $ugpl2 = $ugpl + "50"; mysql_query("UPDATE ibwf_users SET plusses='".$ugpl2."' WHERE id='".$uid."'"); echo " "; } if ($num2 == 8) { $num = rand(1, 3); echo "You did not hit $evil2 . He jump faster than your attack! Miss... Miss! Miss! Minus 10 plusses for that attack"; $ugpl = mysql_fetch_array(mysql_query("SELECT plusses FROM ibwf_users WHERE id='".$uid."'")); $ugpl = $ugpl[0]; $ugpl2 = $ugpl - "10"; mysql_query("UPDATE ibwf_users SET plusses='".$ugpl2."' WHERE id='".$uid."'"); echo " "; } if ($num2 == 9) { $num = rand(1, 3); echo "You hit $evil2 $damage % damage, but he hit you 99 % damage. Minus 99 plusses for that attack"; $ugpl = mysql_fetch_array(mysql_query("SELECT plusses FROM ibwf_users WHERE id='".$uid."'")); $ugpl = $ugpl[0]; $ugpl2 = $ugpl - "99"; mysql_query("UPDATE ibwf_users SET plusses='".$ugpl2."' WHERE id='".$uid."'"); echo " "; } echo ""; echo "</p>"; echo "<p align=\"center\">"; echo "<a href=\"kingdom.php?action=main&sid=$sid\">Kingdom WAR</a>"; echo " "; echo "<a href=\"fun.php?action=main&sid=$sid\">Fun Menu</a>"; echo " "; echo "<a href=\"index.php?action=main&sid=$sid\"><img src=\"../images/home.gif\" alt=\"\"/>Home</a>"; echo "</p>"; echo "</card>"; } else if($action=="c") { addonline(getuid_sid($sid),"Play Kingdom WAR","kingdom.php?action=main"); echo "<card id=\"main\" title=\"Kingdom WAR\">"; echo "<p align=\"center\">"; echo "Kingdom WAR"; echo " "; echo "Now your character have a armored and magical tactics. Try kill your enemy and earn the plusess"; echo "</p>"; echo "<p align=\"left\">"; echo ""; $num3 = rand(1, 9); $uid = mysql_fetch_array(mysql_query("SELECT uid FROM ibwf_ses WHERE id='".$sid."'")); $uid = $uid[0]; $usrid = $uid; $time = time(); echo "<a href=\"kingdom.php?action=$action&sid=$sid&time=$time\">Golden Sword</a> , <a href=\"kingdom.php?action=$action&sid=$sid&time=$time\">Double Bash</a> , <a href=\"kingdom.php?action=$action&sid=$sid&time=$time\">Meteor</a>"; echo " "; $ugpl = mysql_fetch_array(mysql_query("SELECT plusses FROM ibwf_users WHERE id='".$uid."'")); $ugpl = $ugpl[0]; echo "Golden Plusses: $ugpl "; $power = rand(50,100); echo "Power: $power "; echo " "; $damage = rand(0,100); $evil3 = HeadDragon; $gold = rand(30,100); $magic = rand(60,93); $level = 2; $level2 = 3; $low = 1; if ($num3 == 1) { $num = rand(1, 3); echo "You hit $evil3 with damage $damage. You've Won $gold Gold!"; $ugpl = mysql_fetch_array(mysql_query("SELECT plusses FROM ibwf_users WHERE id='".$uid."'")); $ugpl = $ugpl[0]; $ugpl2 = $ugpl + "$gold"; mysql_query("UPDATE ibwf_users SET plusses='".$ugpl2."' WHERE id='".$uid."'"); echo " "; } if ($num3 == 2) { $num = rand(1, 3); echo "You hit $evil3 with damage $damage,but he return 2 kick for you with damage $magic . You've been attacked and Lost $gold gold!"; $ugpl = mysql_fetch_array(mysql_query("SELECT plusses FROM ibwf_users WHERE id='".$uid."'")); $ugpl = $ugpl[0]; $ugpl2 = $ugpl - "$gold"; mysql_query("UPDATE ibwf_users SET plusses='".$ugpl2."' WHERE id='".$uid."'"); echo " "; } if ($num3 == 3) { $num = rand(1, 3); echo "You cast magic $magic % with a hit to $evil3 damaging him $damage %. Then $evi3 return magic attack to you, damaging you $damage %. You draw! Minus 10 plusses for that attack"; $ugpl = mysql_fetch_array(mysql_query("SELECT plusses FROM ibwf_users WHERE id='".$uid."'")); $ugpl = $ugpl[0]; $ugpl2 = $ugpl - "10"; mysql_query("UPDATE ibwf_users SET plusses='".$ugpl2."' WHERE id='".$uid."'"); echo " "; } if ($num3 == 4) { $num = rand(1, 3); echo "You hit $evil3 with a damage of $damage %. Then $evil2 return hold spell attack to you $gold %. You draw! Minus $gold plusses for that attack"; $ugpl = mysql_fetch_array(mysql_query("SELECT plusses FROM ibwf_users WHERE id='".$uid."'")); $ugpl = $ugpl[0]; $ugpl2 = $ugpl - "$gold"; mysql_query("UPDATE ibwf_users SET plusses='".$ugpl2."' WHERE id='".$uid."'"); echo " "; } if ($num3 == 5) { $num = rand(1, 3); echo "You hit $evil3 damaging him 0%. Miss... Miss! Miss! Minus 10 plusses for that attack"; $ugpl = mysql_fetch_array(mysql_query("SELECT plusses FROM ibwf_users WHERE id='".$uid."'")); $ugpl = $ugpl[0]; $ugpl2 = $ugpl - "10"; mysql_query("UPDATE ibwf_users SET plusses='".$ugpl2."' WHERE id='".$uid."'"); echo " "; } if ($num3 == 6) { $num = rand(1, 3); echo "You hit $evil3 damaging him 100%. You are a GODLIKE! Plus 98 plusses for that attack"; $ugpl = mysql_fetch_array(mysql_query("SELECT plusses FROM ibwf_users WHERE id='".$uid."'")); $ugpl = $ugpl[0]; $ugpl2 = $ugpl + "90"; mysql_query("UPDATE ibwf_users SET plusses='".$ugpl2."' WHERE id='".$uid."'"); echo " "; } if ($num3 == 7) { $num = rand(1, 3); echo "You hit $evil3 damaging him 70%. Level up to $level2 You win 50 plusses for that attack"; $ugpl = mysql_fetch_array(mysql_query("SELECT plusses FROM ibwf_users WHERE id='".$uid."'")); $ugpl = $ugpl[0]; $ugpl2 = $ugpl + "50"; mysql_query("UPDATE ibwf_users SET plusses='".$ugpl2."' WHERE id='".$uid."'"); echo " "; } if ($num3 == 8) { $num = rand(1, 3); echo "You did not hit $evil3 . He ran faster than your attack! Miss... Miss! Miss! Minus 10 plusses for that attack"; $ugpl = mysql_fetch_array(mysql_query("SELECT plusses FROM ibwf_users WHERE id='".$uid."'")); $ugpl = $ugpl[0]; $ugpl2 = $ugpl - "10"; mysql_query("UPDATE ibwf_users SET plusses='".$ugpl2."' WHERE id='".$uid."'"); echo " "; } if ($num3 == 9) { $num = rand(1, 3); echo "You hit $evil3 $damage % damage, but he hit you 100 % damage. Minus 100 plusses for that attack"; $ugpl = mysql_fetch_array(mysql_query("SELECT plusses FROM ibwf_users WHERE id='".$uid."'")); $ugpl = $ugpl[0]; $ugpl2 = $ugpl - "99"; mysql_query("UPDATE ibwf_users SET plusses='".$ugpl2."' WHERE id='".$uid."'"); echo " "; } echo ""; echo "</p>"; echo "<p align=\"center\">"; echo "<a href=\"kingdom.php?action=main&sid=$sid\">Kingdom WAR</a>"; echo " "; echo "<a href=\"fun.php?action=main&sid=$sid\">Fun Menu</a>"; echo " "; echo "<a href=\"index.php?action=main&sid=$sid\"><img src=\"../images/home.gif\" alt=\"\"/>Home</a>"; echo "</p>"; echo "</card>"; } else{ addonline(getuid_sid($sid),"Lost in kingdom",""); echo "<card id=\"main\" title=\"Kingdom WAR Error!\">"; echo "<p align=\"center\">"; echo "I don't know how did you get into here, but there's nothing to show "; echo "<a href=\"index.php?action=main&sid=$sid\">Kingdom WAR</a>"; echo " "; echo "<a href=\"index.php?action=main&sid=$sid\"><img src=\"../images/home.gif\" alt=\"\"/>Home</a>"; echo "</p></card>"; } ?> </wml>
i made something like this a while back :-)
but it will be cool if its multyplayer...i made something like this a while back :-)[/b]
Like a battle ground so members can battle each other?.. and steal plusses etc..but it will be cool if its multyplayer...[/b]
Yes! i want that one...Like a battle ground so members can battle each other?.. and steal plusses etc..[/b]![]()
do you have a game like that?![]()
lol it would b cool if it were more like an actual wap rpg.
players can gain experience and level up. then their level and experience count ill b shown in their profile etc
something like that isnt hard to do, every one they kill they get more points and if the get upto just say 100 points the level up..lol it would b cool if it were more like an actual wap rpg.
players can gain experience and level up. then their level and experience count ill b shown in their profile etc[/b]
it will be very easy for a good coder like you...something like that isnt hard to do, every one they kill they get more points and if the get upto just say 100 points the level up..[/b]![]()
if you have one can you share it? Thanks![]()
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks