-
Posts
727 -
Joined
-
Last visited
-
Days Won
40
Content Type
Profiles
Forums
Events
Everything posted by peterisgb
-
Don't post much here as i don't get many ideas so i though i would post this here at least.. Enjoy. This code gives you a coloured animation stat bars. create a .css page. .progress-bar { background-color: #1a1a1a; height: 10px; padding: 1px; width: 100px; margin: 0px 0; border-radius: 1px; box-shadow: 0 1px 5px #000 inset, 0 1px 0 #444; } .progress-bar span { display: inline-block; height: 100%; border-radius: 3px; float: left; box-shadow: 0 1px 0 rgba(255, 255, 255, .5) inset; transition: width .4s ease-in-out; } .blue span { background-color: #1fbbdf; } .orange span { background-color: #fecf23; background-image: linear-gradient(top, #fecf23, #fd9215); } .green span { background-color: #a5df41; background-image: linear-gradient(top, #a5df41, #4ca916); } .stripes span { background-size: 30px 30px; background-image: linear-gradient(135deg, rgba(255, 255, 255, .15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, .15) 50%, rgba(255, 255, 255, .15) 75%, transparent 75%, transparent); animation: animate-stripes 3s linear infinite; } @keyframes animate-stripes { 0% {background-position: 0 0;} 100% {background-position: 60px 0;} } .shine span { position: relative; } .shine span::after { content: ''; opacity: 0; position: absolute; top: 0; right: 0; bottom: 0; left: 0; background: #fff; border-radius: 3px; animation: animate-shine 2s ease-out infinite; } @keyframes animate-shine { 0% {opacity: 0; width: 0;} 50% {opacity: .5;} 100% {opacity: 0; width: 95%;} } .glow span { box-shadow: 0 5px 5px rgba(255, 255, 255, .7) inset, 0 -5px 5px rgba(255, 255, 255, .7) inset; animation: animate-glow 1s ease-out infinite; } @keyframes animate-glow { 0% { box-shadow: 0 5px 5px rgba(255, 255, 255, .7) inset, 0 -5px 5px rgba(255, 255, 255, .7) inset;} 50% { box-shadow: 0 5px 5px rgba(255, 255, 255, .3) inset, 0 -5px 5px rgba(255, 255, 255, .3) inset;} 100% { box-shadow: 0 5px 5px rgba(255, 255, 255, .7) inset, 0 -5px 5px rgba(255, 255, 255, .7) inset;} } and then in header add <link rel='stylesheet' type='text/css' href='FILE_NAME.css' /> under title. (change FILE_NAME.css to the .css file you've created.) You can replace the stats bar with the code below, Of course change the names accordingly. <b>Energy:</b> {$ir['energy']}/{$ir['maxenergy']} {$enperc}%<br /> <div class="progress-bar orange stripes"> <span style="width: $enperc%"></span> </div> That shouldn't be to hard i hope. Contact me if you do need help. Tips. You can change the colour of the bars via CSS, orange, green and blue are included and remove the "stripes" to remove the animation. Enjoy
-
MTG rewrote the class for me a while back as it was better than the basic mccodes codes lol.
-
oh right ok, well i cant use that either as it throws up another error to do with the class_db_mysqli.php which MTG wrote. will have get his help there.
-
I keep this this error on loads of pages. Please help and thanks in advance :) Error Code is Fatal error: Call to undefined method database::fetch_array() in /home/electri9/public_html/viewuser.php on line 251 lines 244 - 263 print"<table width=100% cellspacing=1 class='table'><tr style='background:gray'><th colspan=2>Users Comments <A href=comments.php?ID={$r['userid']}>[Add Comment]</a></th>"; if($ir['userid'] == $r['userid'] || $ir['user_level'] > 1) { print"<th width=10%>Delete</th>"; } print"</tr>"; $blah=$db->query("SELECT * FROM comments WHERE cmtTO={$r['userid']} ORDER BY cmtTIME DESC limit 5", $c) or die(mysql_error()); while($cmnt = $db->fetch_array($blah)); { $they=$db->query("SELECT * FROM users WHERE userid={$cmnt['cmtFROM']}",$c); $them=$db->fetch_array($they); $sent=date('F j, Y, g:i:s a',$cmnt['cmtTIME']); print"<td width=25%><b>{$them['username']} [{$them['userid']}]</br></br></b>$sent</td><Td>{$cmnt['cmtTEXT']}</td>"; if($ir['userid'] == $r['userid'] || $ir['user_level'] > 1) { print"<td width=10%><a href=comments.php?action=delete&ID={$cmnt['cmtID']}>Delete</a></td>"; } print"</tr>"; } print"</table>";
-
any chance of a screeny script?
-
Stick up the code.
-
have a go at a map travel system, Info map with cords where you can move around, while moving you could do foresting (streets) and travel to locations replacing the old travel system.
-
Hi its been a while since there has been any new mods, so i was wondering if anyone on here would like to team up with me on a titanpad and see if we can make something new. Mail me on here or e-mail at [email protected]. Thanks
-
Thanks MTG, got it right the second time, thanks... works a charm,
-
anyone? could really use some help. thanks.
-
not quite, this picks a random winner, there is no random winner. not only that, i am looking for a cron file. would someone have a go for me please.
-
I'm trying to make a cron file where the prizes are auto credited and an announcement is made. I've done abit of this so far and all the functions. but its not quite right and i need a little help to finish it of so it will work, This is what i have so far. <?php include "config.php"; global $_CONFIG; define("MONO_ON", 1); require "class/class_db_{$_CONFIG['driver']}.php"; $db=new database; $db->configure($_CONFIG['hostname'], $_CONFIG['username'], $_CONFIG['password'], $_CONFIG['database'], $_CONFIG['persistent']); $db->connect(); $c=$db->connection_id; $userInfo = $db->query('SELECT `userid`, `sides` FROM `users` ORDER BY sides DESC LIMIT 3'); if($db->num_rows($userInfo) > 0) { $ir = $db->fetch_row($userInfo); $AddAnnouce = sprintf("INSERT INTO mod_announcements (`annouce_NAME`, `annouce_TEXT`, `annouce_TIME`, `annouce_URGENCY`, `annouce_TOPIC`, `annouce_POSTED`)VALUES ('Hackers VS Police', 'Hackers Vs Police Event has Finished.<br /> The Winners are:<br /> 1st Place - {username} Winning 10 Magic Boxes<br /> 2nd Place - {username} Winning 5 Magic Boxes<br /> 3rd Place - {username} Winning 1 Magic Boxes<br /> <br />Congrats and well done.<br />', unix_timestamp(), 'No Urgency', 'Fun', 'System Message')"); $db->query($AddAnnouce); $db->query("UPDATE users SET new_announcements=new_announcements+1"); $db->query("INSERT INTO inventory VALUES('',72,{winner},10)", $c); $db->query("INSERT INTO inventory VALUES('',72,{second},5)", $c); $db->query("INSERT INTO inventory VALUES('',72,{third},1)", $c); $db->query("UPDATE users SET sides=0 WHERE sides > 0"); ?> As you can see there are a few bits missing and things are wrong, but i've done what i can to the best of my knowledge. Any help would be great, thanks
-
i also have the facebook connect, however it wont work for what Jimbo has in mind.
-
would this work if i put it in a cron file to run every 15 minutes. i think its coded bad, but this is a weakpoint i'm working on. $q=$db->query("SELECT userid FROM users"); while($r=$db->fetch_row($q)) { $e=$db->query("SELECT * FROM buildings WHERE userid={$r['userid']}"); while($y=$db->fetch_row($e)) { $gain = rand(100, 100) * $y['goldmine'] * $y['goldmineworkers']; $db->query("UPDATE users SET gold=gold+$gain"); } $e=$db->query("SELECT * FROM buildings WHERE userid={$r['userid']}"); while($y=$db->fetch_row($e)) { $gain = rand(100, 100) * $y['farm'] * $y['farmworkers']; $db->query("UPDATE users SET food=food+$gain"); } $e=$db->query("SELECT * FROM buildings WHERE userid={$r['userid']}"); while($y=$db->fetch_row($e)) { $gain = rand(100, 100) * $y['sawmill'] * $y['sawmillworkers']; $db->query("UPDATE users SET wood=wood+$gain"); } }
-
i like this, nice work :)
-
function orgcrime_dropdown($connection,$ddname="orgcrime",$selected=-1) remove the space before the selected
-
nice to see my mod being used and edited to suit there needs,
-
looks nice, look forward to testing this out.
-
$db->query("UPDATE `users` SET `stamina` = `stamina` + ".($n2 * 5)." WHERE `stamina` < `maxstamina`"); $db->query("UPDATE `users` SET `stamina` = `maxstamina` WHERE `stamina` > `maxstamina`"); Yes you do need a cron, insert this into whichever cron you choose and change the rate accordingly.
-
Hi, Number 14 File Manager, the link is broken, anyway, did you ever fix the <+textbox+> error? Thanks
-
i got this working, its pretty good, however there isnt an option to sell the weed once you have grown it.
-
Car images would be a good idea aswell. be really handy.
-
Hello. To all People Intrested in this or wish to have it dayo has released this for free now . http://makewebgames.io/showthread.php/43407-Free-Template here is a link to it.
-
i've asked magictallguy to quick run through the codes and he said all good so i will add it later and give some feedback.
-
not bad mod, i had police vs hacker on my site lol. good mod,