-
Posts
579 -
Joined
-
Last visited
-
Days Won
5
Content Type
Profiles
Forums
Events
Everything posted by Seker
-
I don't understand the requesting, anyway. Why not just link our PayPals? Why don't we have the ability to use our dev funds to purchase other mods? Hell, I've been waiting two days now to get my payout. And, I had another sale today, so I'll have to wait again.
-
Try changing this: if ($ir['hsteps'] > 0) To this: if ($ir['hsteps'] >= 1) Don't know why I did that backwards.
-
Buying the license from someone else doesn't mean it's illegal.
-
Ease of Use (Installation and Management) - 8 Secure (Does the script have a lot of vulnerabilities) - 2 Efficient (How efficient is the script when it comes to using server resources) - 2 Customization (Is the script easy to customize - for example adding new features to the game) - 8 Support ( If any problems are found with the script how good is the vendor support) - 3 Updates (Is the script regularly updated) - 1 (What's the time on these? Like two years?) Honestly, I like it, but... There are better choices out there.
-
Okay, I think I'm going to redo this. I typed this up in about ten-fifteen minutes in Notepad++. Looked okay and I assumed it would work when it didn't throw any errors on the test server. My apologies, guys. I'll get it all fixed.
-
http://php.net/manual/en/security.database.sql-injection.php Read up on injections. Basically, it means some asshole player alters the MYSQL query and changes something in your game. Could be anything from giving out millions of crystals to changing themselves to admins. Pretty much one of the biggest problems for all text-based games.
-
Take a look at the staffnotes on the viewuser page and tweak it to your needs. Though, as a general rule, notepads are advised against unless you know some security. They're a big danger for SQL injections.
-
Strange? Please elaborate. I always want to improve what I'm doing, so if there's something unnecessary, or just flat out wrong, I'd love to know about it. :)
-
Hmm. Wonder how Zynga will feel about those images.
-
I just realized I mis-typed, anyway. Should be: $db->query("UPDATE users SET hsteps=50"); The stat-base idea is interesting. Perhaps a formula similar to the way the crime success rate is calculated. I'll have to look into that.
-
And, for those who will ask, here's V2: <?php /****************************************/ /************ Created By Seker *************/ /********** Bugs Fixed By mixmaster *********/ /****************************************/ require_once('globals.php'); $hsteps = $ir['hsteps']; $maxenergy = $ir['maxenergy']; if (!$ir['hospital']) { echo " You are not in the hospital! <a href='index.php'>[Home]</a>"; exit($h->endpage()); } if ($ir['jail']) { echo " You cannot be here while in jail! <a href='index.php'>[Home]</a>"; exit($h->endpage()); } if ($ir['energy'] < 5) { echo " You do not have enough energy to explore the hospital! <a href='crystaltemple.php'>[Refill Energy]</a>"; exit($h->endpage()); } echo " <table width='70%' border='1'> <tr> <td align='center'> <b><u>Explore The Hospital</u></b> </td> </tr> <tr> <td align='center'> Explore the hospital! You never know what you'll find! </td> </tr> <tr> <td align='center'> It will cost you 5 energy, and you get 50 chances to explore each day! </td> </tr> <tr> <td align='center'> You can earn your release, or you can end up spending even longer in the hospital, so be careful! </td> </tr> </table> <table width='70%' border='1'> <tr> <td align='center'> You currently have {$hsteps} more chances to explore! Don't waste them! </td> </tr> <tr> <td align='center'>"; if ($ir['hsteps'] > 0) { echo " <a href='hospexplore.php?action=explore'>[Explore]</a> </td> </tr> </table>"; } else { echo " You have explored enough! Try again tomorrow! <a href='hospital.php'>[back]</a> </td> </tr> </table>"; } $_GET['action'] = $db->escape( htmlentities(stripslashes($_GET['action']), ENT_QUOTES, 'ISO-8859-1')); switch ($_GET['action']) { case 'explore': do_explore(); break; } function do_explore() { global $ir, $h, $c, $userid, $db; if (!$ir['hospital']) { echo " You are not in the hospital! <a href='index.php'>[Home]</a>"; exit($h->endpage()); } if ($ir['jail']) { echo " You cannot be here while in jail! <a href='index.php'>[Home]</a>"; exit($h->endpage()); } if ($ir['energy'] < 5) { echo " You do not have enough energy to explore the hospital! <a href='crystaltemple.php'>[Refill Energy]</a>"; exit($h->endpage()); } if($ir['hsteps'] < 1) { echo" you have no steps left": exit($H->endpage()): } $result = rand(1,3); $db->query("UPDATE users SET energy=energy-5,hsteps=hsteps-1 WHERE steps > 0 && userid=$userid"); if ($result == 1) { $db->query("UPDATE users SET hospital=hospital+5 WHERE userid=$userid"); echo " The doctor ordered bedrest! Your hospital time has increased! <a href='hospexplore.php?action=explore'>[Continue Exploring]</a> <a href='hospital.php'>[back]</a>"; exit($h->endpage()); } else if ($result == 2) { $db->query("UPDATE users SET energy=$maxenergy WHERE userid=$userid"); echo " You stopped at the vending machine and got a coffee. You feel re-energized! <a href='hospexplore.php?action=explore'>[Continue Exploring]</a> <a href='hospital.php'>[back]</a>"; exit($h->endpage()); } else if ($result == 3) { $db->query("UPDATE users SET hospital=0 WHERE userid=$userid"); echo " You stumbled across the back exit! Time to get out of here! <a href='index.php'>[Home]</a>"; exit($h->endpage()); } } $h->endpage(); Add to cron_day: $db->query("UPDATE users SET hsteps=50"); SQL is the same.
-
Haven't seen many new free mods around, lately, so I thought I would share this with everyone. It's a little twist on Streets to keep your players active while sitting in the hospital. Players get 50 steps per day, only to be used while in the hospital. While exploring the halls, they have a chance at refilling their energy, getting out of the hospital, nothing happening at all, or even increasing their hospital time. Just figured this is one more little feature to keep players busy. Hope you can find some use for it. SQL: ALTER TABLE `users` ADD `hsteps` INT( 11 ) NOT NULL DEFAULT 50; hospexplore.php: <?php /****************************************/ /*********** Created By Seker ***********/ /****************************************/ session_start(); require "global_func.php"; if ($_SESSION['loggedin'] == 0) { header("Location: login.php"); exit; } $userid = $_SESSION['userid']; require "header.php"; $h = new headers; $h->startheaders(); include "mysql.php"; global $c; $is = mysql_query( "SELECT u.*,us.* FROM users u LEFT JOIN userstats us ON u.userid=us.userid WHERE u.userid=$userid", $c) or die(mysql_error()); $ir = mysql_fetch_array($is); check_level(); $fm = money_formatter($ir['money']); $cm = money_formatter($ir['crystals'], ''); $lv = date('F j, Y, g:i a', $ir['laston']); $h->userdata($ir, $lv, $fm, $cm); $h->menuarea(); $hsteps = $ir['hsteps']; if (!$ir['hospital']) { echo " You are not in the hospital!<br /> <a href='index.php'>[Home]</a>"; exit($h->endpage()); } if ($ir['jail']) { echo " You cannot be here while in jail!<br /> <a href='index.php'>[Home]</a>"; exit($h->endpage()); } if ($ir['energy'] < 5) { echo " You do not have enough energy to explore the hospital!<br /> <a href='crystaltemple.php'>[Refill Energy]</a>"; exit($h->endpage()); } echo " <table width='70%' border='1'> <tr> <td align='center'> <b><u>Explore The Hospital</u></b> </td> </tr> <tr> <td align='center'> Explore the hospital! You never know what you'll find! </td> </tr> <tr> <td align='center'> It will cost you 5 energy, and you get 50 chances to explore each day! </td> </tr> <tr> <td align='center'> You can earn your release, or you can end up spending even longer in the hospital, so be careful! </td> </tr> </table> <table width='70%' border='1'> <tr> <td align='center'> You currently have {$hsteps} more chances to explore! Don't waste them! </td> </tr> <tr> <td align='center'>"; if ($ir['hsteps'] > 0) { echo " <a href='hospexplore.php?action=explore'>[Explore]</a> </td> </tr> </table>"; } else { echo " You have explored enough! Try again tomorrow!<br /> <a href='hospital.php'>[back]</a> </td> </tr> </table>"; } $_GET['action'] = mysql_real_escape_string( htmlentities(stripslashes($_GET['action']), ENT_QUOTES, 'ISO-8859-1')); switch ($_GET['action']) { case 'explore': do_explore(); break; } function do_explore() { global $ir, $h, $c, $userid; if (!$ir['hospital']) { echo " You are not in the hospital!<br /> <a href='index.php'>[Home]</a>"; exit($h->endpage()); } if ($ir['jail']) { echo " You cannot be here while in jail!<br /> <a href='index.php'>[Home]</a>"; exit($h->endpage()); } if ($ir['energy'] < 5) { echo " You do not have enough energy to explore the hospital!<br /> <a href='crystaltemple.php'>[Refill Energy]</a>"; exit($h->endpage()); } $result = rand(1,5); mysql_query("UPDATE users SET energy=energy-5,hsteps=hsteps-1 WHERE userid=$userid"); if ($result = 1) { mysql_query("UPDATE users SET hospital=hospital+5 WHERE userid=$userid"); echo " The doctor ordered bedrest! Your hospital time has increased!<br /> <a href='hospexplore.php?action=explore'>[Continue Exploring]</a><br /> <a href='hospital.php'>[back]</a>"; exit($h->endpage()); } else if ($result = 3) { mysql_query("UPDATE users SET energy=maxenergy WHERE userid=$userid"); echo " You stopped at the vending machine and got a coffee. You feel re-energized!<br /> <a href='hospexplore.php?action=explore'>[Continue Exploring]</a><br /> <a href='hospital.php'>[back]</a>"; exit($h->endpage()); } else if ($result = 5) { mysql_query("UPDATE users SET hospital=0 WHERE userid=$userid"); echo " You stumbled across the back exit! Time to get out of here!<br /> <a href='index.php'>[Home]</a>"; exit($h->endpage()); } else { echo " This hospital is huge! You haven't found anything, yet!<br /> <a href='hospexplore.php?action=explore'>[Continue Exploring]</a><br /> <a href='hospital.php'>[back]</a>"; exit($h->endpage()); } } $h->endpage(); Add to cron_day: mysql_query("UPDATE users SET hsteps=50"); Add somewhere in your hospital or wherever you want it: <a href='hospexplore.php'>Explore The Halls</a> Screenshot: [ATTACH=CONFIG]499[/ATTACH]
-
You have to encase the image in a print or echo statement. Change: <img src='logo.jpg' title='logo' alt='registernow.png' /> To: echo "<img src='logo.jpg' title='logo' alt='registernow.png' />";
-
The alt tag specifies an alternate text to display in the case the image can't load.
-
Where it says "Bleh" is what you would want the link to say. For example - <a href='http://www.google.com'>Google</a> would look like this - Google
-
Images - <img src='blah.jpg' title='blah' alt='blah' /> Hyperlink = echo "<a href='http://www.blah.com'>Bleh</a>";
-
Don't see why it wouldn't. Pop it into an iframe and place where you want it. Not the most efficient way, but it should work.
-
There are some okay shoutbox mods floating around. Or you could just include an outside chat in an iframe. Then, it's just css positioning to get it where you want.
-
You don't do the typing, do you?
-
I think you just need to change the values, not remove it completely.
-
Won't that just put it in the center of the page?
-
V2 is finally ready and available for purchase HERE!
-
I can get into MCCodes just fine, but I have a similar issue when trying to log in to any forums. I use Chrome, and the only way I can fix it is to disable page caching. "Smart browsing" is absolutely idiotic.
-
I've updated the original post with screenshots. For those waiting for V2, I apologize. It seems the Hall Of Fame doesn't work quite the same way, so I'm working on converting off the V2 Hall Of Fame. It should be ready very soon.
-
Version 1 of this mod is now available in the marketplace HERE Version 2 should be available very soon.