Modern-Empires Posted September 28, 2008 Posted September 28, 2008 This mod i made from scratch, i will tell you how many poeple are onlineon the main menu. Open Main Menu Find the line: $mc=$ir['new_mail']; add under: $var2['num_users_on'] = mysql_query("SELECT userid FROM users WHERE laston >= UNIX_TIMESTAMP()-900", $c); $var['num_users_on'] = mysql_num_rows($var2['num_users_on']); and put this anywhere on the links in main menu: Users Online ({$var['num_users_on']}) This mod was made by me Peter Greenacre First Placed on modern-empires http://www.modern-empires.site40.net Quote
Zero-Affect Posted September 28, 2008 Posted September 28, 2008 Re: main menu users online count This mod i made from scratch, i will tell you how many poeple are onlineon the main menu. Open Main Menu Find the line: You're unable to view this code. Viewing code within this forum requires registration, you can register here for free. add under: You're unable to view this code. Viewing code within this forum requires registration, you can register here for free. and put this anywhere on the links in main menu: You're unable to view this code. Viewing code within this forum requires registration, you can register here for free. This mod was made by me Peter Greenacre First Placed on modern-empires http://www.modern-empires.site40.net Much better Quote
Karlos Posted September 28, 2008 Posted September 28, 2008 Re: main menu users online count Thanks :-) I Was Looking For This :-D Quote
Joel Posted September 28, 2008 Posted September 28, 2008 Re: main menu users online count Nice :-) Quote
Zero-Affect Posted September 28, 2008 Posted September 28, 2008 Re: main menu users online count Thanks :-) I Was Looking For This :-D you mean you couldn't do that? Quote
Modern-Empires Posted September 28, 2008 Author Posted September 28, 2008 Re: main menu users online count i'm glad you likew the mod, it toke me 10 minutes cos the first time i did it i forgot the main line but over all it was done in 15 minutes Quote
Karlos Posted September 28, 2008 Posted September 28, 2008 Re: main menu users online count Thanks :-) I Was Looking For This :-D you mean you couldn't do that? i guess u havent heard of laziness or being tired Quote
Guest Sniko` Posted September 28, 2008 Posted September 28, 2008 Re: main menu users online count lOl ImMorTaL X Excuses Quote
Modern-Empires Posted September 28, 2008 Author Posted September 28, 2008 Re: main menu users online count i hope that you guys like the mod, there's only one way to check out if it works and that by joining my game and have a look, you locate the working mod at the bottem of the main menu, thanks Quote
Guest Sniko` Posted September 28, 2008 Posted September 28, 2008 Re: main menu users online count there's only one way to check out if it works and that by joining my game and have a look, you locate the working mod at the bottem of the main menu, thanks LoL not only one wy you could install it into your own game, lOl by joining my game and have a look LoL, cheap wahy of getting people to join NICE ONE! Anyway thanks for this MOD Quote
Modern-Empires Posted September 28, 2008 Author Posted September 28, 2008 Re: main menu users online count there's only one way to check out if it works and that by joining my game and have a look, you locate the working mod at the bottem of the main menu, thanks LoL not only one wy you could install it into your own game, lOl by joining my game and have a look LoL, cheap wahy of getting people to join NICE ONE! Anyway thanks for this MOD well it helps me get members lol, but it is there to show you the mod i made in working prgress Quote
simplypanda Posted September 29, 2008 Posted September 29, 2008 Re: main menu users online count I just added this to my game You're unable to view this code. Viewing code within this forum requires registration, you can register here for free. Quote
Haunted Dawg Posted September 29, 2008 Posted September 29, 2008 Re: main menu users online count @ simplepanda, i would like to see your game running fast and efficient with that script plus 900 people online with in 15 minute's. You're unable to view this code. Viewing code within this forum requires registration, you can register here for free. To display: You're unable to view this code. Viewing code within this forum requires registration, you can register here for free. That's what i use. Quote
simplypanda Posted September 29, 2008 Posted September 29, 2008 Re: main menu users online count Ok thx for the advice. Quote
www.mygunwars.com Posted September 30, 2008 Posted September 30, 2008 Re: main menu users online count Nice I have been trying to find out how to add that one thanks man :-D Quote
Zero-Affect Posted September 30, 2008 Posted September 30, 2008 [mccode] Re: main menu users online count This mod i made from scratch, i will tell you how many poeple are onlineon the main menu. Open Main Menu Find the line: $mc=$ir['new_mail']; add under: $var2['num_users_on'] = mysql_query("SELECT userid FROM users WHERE laston >= UNIX_TIMESTAMP()-900", $c); $var['num_users_on'] = mysql_num_rows($var2['num_users_on']); and put this anywhere on the links in main menu: Users Online ({$var['num_users_on']}) This mod was made by me Peter Greenacre First Placed on modern-empires http://www.modern-empires.site40.net let me do a little edit for ya Open Main Menu Find the line: You're unable to view this code. Viewing code within this forum requires registration, you can register here for free. add under: You're unable to view this code. Viewing code within this forum requires registration, you can register here for free. and put this anywhere on the links in main menu: You're unable to view this code. Viewing code within this forum requires registration, you can register here for free. that should work... Quote
Decepti0n Posted September 30, 2008 Posted September 30, 2008 Re: main menu users online count It'll almost work Change $var = mysql_num_rows($sql); to $var = mysql_fetch_assoc($sql); And it will. Also there's no need to use sprintf on that, since you're putting the 900 in directly Quote
Zero-Affect Posted September 30, 2008 Posted September 30, 2008 Re: main menu users online count EDITED thanks i forgot it was fetch not num lol Quote
Modern-Empires Posted October 2, 2008 Author Posted October 2, 2008 Re: main menu users online count well guys thanks for changeing my mod a little makes it easier to add in thanks Quote
Zero-Affect Posted October 2, 2008 Posted October 2, 2008 Re: main menu users online count Your Welcome Quote
Modern-Empires Posted October 2, 2008 Author Posted October 2, 2008 Re: main menu users online count thanks at least some appreciate some of my mccodes mods Quote
Ishraq Posted October 10, 2008 Posted October 10, 2008 Re: [mccode] Main menu users online count aint there a code that shows atleast 10 people who are online and under neath them will be a link to usersonline page in the mainmenu. if you can make it please post them Quote
Modern-Empires Posted October 22, 2008 Author Posted October 22, 2008 Re: [mccode] Main menu users online count so who has put this mod i made in there game Quote
Zero-Affect Posted October 23, 2008 Posted October 23, 2008 Re: [mccode] Main menu users online count aint there a code that shows atleast 10 people who are online and under neath them will be a link to usersonline page in the mainmenu. if you can make it please post them and you say your a coder... limit 10 god thats basic i taught myself simple sql queries on my first day... Quote
Modern-Empires Posted November 29, 2008 Author Posted November 29, 2008 Re: [mccode] Main menu users online count i just want to say thanks to all the people who have added my mod to their game, i've seen a few people use it now so i would just like to say thanks for using my mod Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.