Jump to content
MakeWebGames

Zan

Members
  • Posts

    124
  • Joined

  • Last visited

Everything posted by Zan

  1. hmmm we can add something like this [mysql]ALTER TABLE `forum_topics` ADD `liker` INT (11) DEFAULT 0; ALTER TABLE `forum_topics` ADD `disliker` INT (11) DEFAULT 0; ALTER TABLE `forum_topics` ADD `liked` INT (11) DEFAULT 0; ALTER TABLE `forum_topics` ADD `disliked` INT (11) DEFAULT 0;[/mysql] then $like=$db->query("SELECT * FROM `forum_topics` WHERE `liker`=$forumid AND `liked`={$_GET['ID']}"); $dislike=$db->query("SELECT * FROM `forum_topics` WHERE `disliker`=$forumid AND `disliked`={$_GET['ID']}"); if (mysql_num_rows($like)==1) { echo "<h2><center>You have already Liked this thread!</h2></center>"; $h->endpage(); exit(); } if (mysql_num_rows($dislike)==1) { echo "<h2><center>You have already Disliked this thread!</h2></center>"; $h->endpage(); exit(); } Not 100% sure it will work..just my thinking..maybe someone can improve this codes ????
  2. hi Now this is wat i call a mod...Good Work DJK
  3. hy Well coded sniko,i like it but i dont think theres a buy link :\
  4. Chicka is this wat u r talking abt?   <?php include(DIRNAME(__FILE__).'/globals.php'); if(isset($_GET['ID']) && ctype_digit($_GET['ID'])) { if($_GET['ID'] == $userid) { echo 'You cannot slap yourself'; exit($h->endpage()); } $p = $db->query("SELECT userid, username FROM users WHERE userid = ".$_GET['ID']); if(!$db->num_rows($p)) { echo 'This user does not exist'; exit($h->endpage()); } $r = $db->fetch_row($p); echo 'You have slapped '.$r['username']; event_add($r['userid'],'you have been slapped by [url="viewuser.php?u='.$userid.'"]'.$ir['username'].'[/url]. Click [url="pslap.php?ID='.$userid.'"]Here[/url] to slap him back',$c); $db->query("UPDATE users SET punches=slaps+1 WHERE userid = ".$_SESSION['userid']); } else { echo 'Please specify a user'; } ?>
  5. TIve seen one same like this before   ha! now i remember ...NUDGE USER BY JOEL
  6. Nice work pal...;)
  7. Can u post the cde here or make a new download link? this one aint working..Looking nice in the images tho
  8. Peter hahha...When ever any of my friends or any of the people tells about making a game or website...FIRST TELL PETERS NAME FOR THE GRAPHICS OF THE SITE ;)
  9. Good templat e..made by peter :P i like it bertnad told ryt..NO STORY ,maybe u should have a final check for the bugs :\
  10. Hmmm good work... u can add some moons(satelites) instead of man made stelites :P
  11. hmm U can add meteriods and some rock particles in the atmospere? :thumbsup:
  12. Ehm ...EHm...I m working on this mod this mod i tried adding the insert into inventory like how it is in itemmarket still aint working
  13. I installed a gang armoury everything works fine but from armoury when i try giving an item to a user...the user gets the event aand also the item gets removed from the armoury...but the item is not reaching the user to whom i sent   THIS IS MY GANGGIVE.PHP Removed
  14. Wooh..This is a good mod...maybe we can add alot of features to it and make it good
  15. There is a free one like this ,But ull have to edit it in a way like torns..i can help u in that but wats in it 4 me?
  16. Fixed..Thanks to lucky3809
  17. Zan

    A good Host

    Can someone tell me a good host which have no server down shits and all i bought byethost   now 2 days it have been server down... Please mail me some nice hosts or reply here
  18. :) i added u plz accept me
  19. i added u in my msn accept plz
  20. Curt also...No one releases the game as soon as they buy the domain or as soon as they get the bought template or any shit..they check if any bugs are there..also some ppl make thier own mods and test it..so they might need energy and all..so THIS MOD CN BE USED BEFORE THE GAME IS RELEASED :)
  21. <?php $atkpage=1; include 'globals.php'; $_GET['ID'] = (isset($_GET['ID']) && ($_GET['ID'])) ? intval($_GET['ID']) : false; $_GET['wepid'] = (isset($_GET['wepid']) && ($_GET['wepid'])) ? intval($_GET['wepid']) : false; $_GET['nextstep'] = (isset($_GET['nextstep']) && ($_GET['nextstep'])) ? intval($_GET['nextstep']) : false; $_GET['hp'] = (isset($_GET['hp']) && ($_GET['hp'])) ? intval($_GET['hp']) : false; $_GET['attacklost'] = (isset($_GET['attacklost']) && ($_GET['attacklost'])) ? intval($_GET['attacklost']) : false; $_GET['attacking'] = (isset($_GET['attacking']) && ($_GET['attacking'])) ? intval($_GET['attacking']) : false; $_GET['maxhp'] = (isset($_GET['maxhp']) && ($_GET['maxhp'])) ? intval($_GET['maxhp']) : false; if(!$_GET['ID']) { echo'No ID selected.'; exit($h->endpage()); } if(!$_GET['ID']) { echo 'WTF you doing, bro?'; exit($h->endpage()); } else if($_GET['ID'] == $userid) { echo 'Only the crazy attack themselves.'; exit($h->endpage()); } else if ($ir['hp'] <= 1) { echo 'Only the crazy attack when their unconscious. [url="index.php"]Back[/url]'; exit($h->endpage()); } else if ($_SESSION['attacklost'] == 1) { echo "Only the losers of all their EXP attack when they've already lost. [url='index.php']Back[/url]"; $_SESSION['attacklost']=0; exit($h->endpage()); } //get player data $youdata=$ir; $q=$db->query("SELECT u.*,us.* FROM users u LEFT JOIN userstats us ON u.userid=us.userid WHERE u.userid={$_GET['ID']}"); $odata=$db->fetch_row($q); $myabbr=($ir['gender']=="Male") ? "his" : "her"; $oabbr=($ir['gender']=="Male") ? "his" : "her"; if($ir['attacking'] && $ir['attacking'] != $_GET['ID']) { echo 'Bad, bad, bad girl. [url="index.php"]Back[/url]'; $_SESSION['attacklost']=0; exit($h->endpage()); } if($odata['hp'] == 1) { echo 'This player is unconscious. [url="index.php"]> Back[/url]'; exit($h->endpage()); $_SESSION['attacking']=0; $ir['attacking']=0; $db->query("UPDATE users SET attacking=0 WHERE userid=$userid"); exit; } else if($odata['hospital']) { echo 'This player is in hospital. [url="index.php"]> Back[/url]'; exit($h->endpage()); $_SESSION['attacking']=0; $ir['attacking']=0; $db->query("UPDATE users SET attacking=0 WHERE userid=$userid"); exit; } else if($ir['hospital']) { echo 'While in hospital you can\'t attack. [url="hospital.php"]> Back[/url]'; exit($h->endpage()); $_SESSION['attacking']=0; $ir['attacking']=0; $db->query("UPDATE users SET attacking=0 WHERE userid=$userid"); exit; } else if($odata['jail']) { echo 'This player is in jail. [url="index.php"]> Back[/url]'; exit($h->endpage()); $_SESSION['attacking']=0; $ir['attacking']=0; $db->query("UPDATE users SET attacking=0 WHERE userid=$userid"); exit; } else if($ir['jail']) { echo 'While in jail you can\'t attack. [url="jail.php"]> Back[/url]'; exit($h->endpage()); $_SESSION['attacking']=0; $ir['attacking']=0; $db->query("UPDATE users SET attacking=0 WHERE userid=$userid"); exit; } else if($odata['travelling']) { echo 'That player is travelling. [url="index.php"]> Back[/url]'; exit($h->endpage()); $_SESSION['attacking']=0; $ir['attacking']=0; $db->query("UPDATE users SET attacking=0 WHERE userid=$userid"); exit; } echo '<table width=100%><tr><td colspan=2 align=center>'; if($_GET['wepid']) { if($_SESSION['attacking']==0 && $ir['attacking'] == 0) { if ($youdata['energy'] >= $youdata['maxenergy']/2) { $youdata['energy']-= floor($youdata['maxenergy']/2); $me=floor($youdata['maxenergy']/2); $db->query("UPDATE users SET energy=energy- {$me} WHERE userid=$userid"); $_SESSION['attacklog']=""; $_SESSION['attackdmg']=0; } else { echo 'You can only attack someone when you have 50% energy'; exit($h->endpage()); } } $_SESSION['attacking']=1; $ir['attacking']=$odata['userid']; $db->query("UPDATE users SET attacking={$ir['attacking']} WHERE userid=$userid"); $_GET['wepid'] = (int) $_GET['wepid']; $_GET['nextstep'] = (int) $_GET['nextstep']; if($_GET['nextstep'] > 25) { print "<center>This fight is going knowhere you may as well go home! [url='index.php'] Back[/url]</center>"; exit($h->endpage()); event_add($odata['userid'],"[url='viewuser.php?u=$userid']{$youdata['username']}[/url] Tried to beat you but stalemated.",$c); exit; } if($_GET['wepid'] != $ir['equip_primary'] && $_GET['wepid'] != $ir['equip_secondary']) { echo 'Stop trying to abuse a game bug. You can lose all your EXP for that. [url="index.php"]> Home[/url]'; $db->query("UPDATE users SET exp=0 where userid=$userid",$c); die(""); } $qo=$db->query("SELECT i.* FROM items i WHERE i.itmid={$_GET['wepid']}"); $r1=$db->fetch_row($qo); $mydamage=(int) (($r1['weapon']*$youdata['strength']/($odata['guard']/1.5))*(rand(8000,12000)/10000)); $hitratio=max(10,min(60*$ir['agility']/$odata['agility'],95)); if(rand(1,100) <= $hitratio ) { $q3=$db->query("SELECT i.armor FROM items i WHERE itmid={$odata['equip_armor']} ORDER BY rand()"); if($db->num_rows($q3)) { $mydamage-=$db->fetch_single($q3); } if($mydamage < -100000) { $mydamage=abs($mydamage); } else if($mydamage < 1) { $mydamage=1; } $crit=rand(1,40); if($crit==17) { $mydamage*=rand(20,40)/10; } else if($crit==25 or $crit == 8) { $mydamage/=(rand(20,40)/10); } $mydamage=round($mydamage); $odata['hp']-=$mydamage; if($odata['hp']==1) { $odata['hp']=0;$mydamage+=1; } $db->query("UPDATE users SET hp=hp-$mydamage WHERE userid={$_GET['ID']}"); echo '<span style="color: red;">'. number_format($_GET['nextstep']) .'. Using your '. $r1['itmname'] .' you hit '.$odata['username'].' doing '.$mydamage.' damage ('. number_format($odata['hp']) .')</span> '; $_SESSION['attackdmg']+=$mydamage; $_SESSION['attacklog'] .= '<span style="color: red;">'. number_format($_GET['nextstep']) .'. Using your '. $r1['itmname'] .' you hit '. $odata['username'] .' doing '. $mydamage .' damage '. number_format($odata['hp']) .'</span> '; } else { echo '<span style="color: red;">'. number_format($_GET['nextstep']) .'. You tried to hit '. $odata['username'] .' but missed ('. number_format($them['hp']) .')</span> '; $_SESSION['attacklog'] .= '<span style="color: red;">'. number_format($_GET['nextstep']) .'. You tried to hit '. $odata['username'] .' but missed ('. number_format($odata['hp']) .')</span> '; } if($odata['hp'] <= 0) { $odata['hp']=0; $_SESSION['attackwon']=$_GET['ID']; $db->query("UPDATE users SET hp=0 WHERE userid={$_GET['ID']}"); echo ' [b]What do you want to do with '.$odata['username'].' now?[/b] <form action="attackwon.php?ID='.$_GET['ID'].'" method="post"><input type="submit" value="Mug Them" /></form> <form action="attackbeat.php?ID='.$_GET['ID'].'" method="post"><input type="submit" value="Hospitalize Them" /></form> <form action="attacktake.php?ID='.$_GET['ID'].'" method="post"><input type="submit" value="Leave Them" /></form>'; } else { //choose opp gun $eq=$db->query("SELECT i.* FROM items i WHERE i.itmid IN({$odata['equip_primary']}, {$odata['equip_secondary']})"); if(mysql_num_rows($eq) == 0) { $wep="Fists"; $dam=(int)((((int) ($odata['strength']/$ir['guard']/100)) +1)*(rand(8000,12000)/10000)); } else { $cnt=0; while($r=$db->fetch_row($eq)) { $enweps[]=$r; $cnt++; } $weptouse=rand(0,$cnt-1); $wep=$enweps[$weptouse]['itmname']; $dam=(int) (($enweps[$weptouse]['weapon']*$odata['strength']/($youdata['guard']/1.5))*(rand(8000,12000)/10000)); } $hitratio=max(10,min(60*$odata['agility']/$ir['agility'],95)); if(rand(1,100) <= $hitratio) { $q3=$db->query("SELECT i.armor FROM items i WHERE itmid={$ir['equip_armor']} ORDER BY rand()"); if($db->num_rows($q3)) { $dam-=$db->fetch_single($q3); } if($dam < -100000) { $dam=abs($dam); } else if($dam < 1) { $dam=1; } $crit=rand(1,40); if($crit==17) { $dam*=rand(20,40)/10; } else if($crit==25 or $crit == 8) { $dam/=(rand(20,40)/10); } $dam=round($dam); $youdata['hp']-=$dam; if ($youdata['hp']==1) { $dam+=1; $youdata['hp']=0; } $db->query("UPDATE users SET hp=hp-$dam WHERE userid=$userid"); $ns=$_GET['nextstep']+1; echo '<span style="color: red;">'.$ns.'. Using '.$oabbr.' '.$wep.' '.$odata['username'].' hit you doing '.$dam.' damage '.($youdata['hp']).'</span> '; $_SESSION['attacklog'].='<span style="color: blue;">'.$ns.'. Using '.$oabbr.' '.$wep.' '.$odata['username'].' hit '.$ir['username'].' doing '.$dam.' damage '.($youdata['hp']).'</span> '; } else { $ns=$_GET['nextstep']+1; echo '<span style="color: red;">'.$ns.'. '.$odata['username'].' tried to hit you but missed '.($youdata['hp']).'</font> '; $_SESSION['attacklog'].='<span style="color: blue;">'.$ns.'. '.$odata['username'].' tried to hit '.$ir['username'].' but missed '.($youdata['hp']).'</span> '; } if($youdata['hp'] <= 0) { $youdata['hp']=0; $_SESSION['attacklost']=1; $db->query("UPDATE users SET hp=0 WHERE userid=$userid"); echo '<form action="attacklost.php?ID='.$_GET['ID'].'"method="post"><input type="submit" value="Continue" />'; } } } else if ($odata['hp'] < 5) { echo 'You can only attack those who have health'; exit($h->endpage()); } else if ($ir['gang'] == $odata['gang'] && $ir['gang'] > 0) { echo 'You are in the same gang as '.$odata['username'].'! What are you smoking today dude!'; exit($h->endpage()); } else if ($youdata['energy'] < $youdata['maxenergy']/2) { echo 'You can only attack someone when you have 50% energy'; exit($h->endpage()); } else if ($youdata['location'] != $odata['location']) { echo 'You can only attack someone in the same location!'; exit($h->endpage()); } else { } echo '</td></tr>'; if($youdata['hp'] <= 0 || $odata['hp'] <= 0) { echo '</table>'; } else { $vars['hpperc']=round($youdata['hp']/$youdata['maxhp']*100); $vars['hpopp']=100-$vars['hpperc']; $vars2['hpperc']=round($odata['hp']/$odata['maxhp']*100); $vars2['hpopp']=100-$vars2['hpperc']; $mw=$db->query("SELECT i.* FROM items i WHERE i.itmid IN({$ir['equip_primary']}, {$ir['equip_secondary']})"); echo '<tr><td colspan=2 align="center">Attack with: '; if($db->num_rows($mw) > 0) { while($r=$db->fetch_row($mw)) { if(!$_GET['nextstep']) { $ns=1; } else { $ns=$_GET['nextstep']+2; } if($r['itmid']==$ir['equip_primary']) { echo '[b]Primary Weapon:[/b] '; } if($r['itmid']==$ir['equip_secondary']) { echo '[b]Secondary Weapon:[/b] '; } echo "[url='attack.php?nextstep=$ns&ID={$_GET[']{$r['itmname']}[/url] "; } } else { echo 'You have nothing to fight with.'; } echo '</table>'; echo "<table width='50%' align='center'><tr><td align=right>Your Health: </td><td><img src=greenbar.png width={$vars['hpperc']} height=10><img src=redbar.png width={$vars['hpopp']} height=10></td><tr><td align=right>Opponents Health: </td><td><img src=greenbar.png width={$vars2['hpperc']} height=10><img src=redbar.png width={$vars2['hpopp']} height=10></td></tr></table>"; } exit($h->endpage()); ?>   THIS WORKS
  22. if($_GET['nextstep'] > 10) { echo'<center><span style="color: red;">STALEMATE!</span> This fight is going knowhere you may as well go home! > Back</center>'; $h->endpage(); event_add($odata['userid'],"{$youdata['username']} Tried to beat you but stalemated.",$c); event_add($youdata['userid']," You Tried to beat {$odata['username']} but stalemated.",$c); exit; }   NOT WORKING
  23. Yeah..because..i added this to my test game...and i had same weapon adn same batle stats as the opponent then we both fought till 1000 still no winner..... 109. You tried to hit Assassin Creed but missed (0) 110. Using his Fists Assassin Creed hit you doing 0 damage 134 when it reaches 100 stop the fight ? with a message?
  24. 109. You tried to hit Assassin Creed but missed (0) 110. Using his Fists Assassin Creed hit you doing 0 damage 134 can u make it like..if we reach 100 it says" looks like you both knocked out each other " or something like that? the fight never stops until someone wins.thats boring kinda ;)
  25. Nice one Blade.its like old one but still i like it because/./..now damges made are normal...in the mccodes 2 attack...its 1000000000damage your damage is blanced lol and nice color ;)
×
×
  • Create New...