Jump to content
MakeWebGames

galdikas

Members
  • Posts

    139
  • Joined

  • Last visited

Everything posted by galdikas

  1. extract($row) doesn't cause problems... it's this bit: $get_name=mysql_query("SELECT userid,username FROM users WHERE userid='$to_id'"); $get_name=mysql_fetch_assoc($get_name); extract($get_name); Without this code.. outbox doesnt display the name of the person to whom the mail was sent/
  2. for some reason all indentation in the text got lost... Is that because I just copy/paste from my editor? By the way.. it works fine.. it produces the list of sent messages and everything.. its just that it produces that damn warning
  3. Hello everyone.. SO I ran into some trouble with outbox...   elseif($_GET['outbox']) { $sent=mysql_query("SELECT * FROM mail WHERE from_id='$userid' ORDER BY datetime DESC"); $i=1; echo "<table style='width:760px'>"; echo"<tr><th>To:</th><th class='subj'>Subject:</th><th>Date:</th></th><th>Time:</th>"; while($row=mysql_fetch_assoc($sent)) { extract($row); $get_name=mysql_query("SELECT userid,username FROM users WHERE userid='$to_id'"); $get_name=mysql_fetch_assoc($get_name); extract($get_name); if($i%2==0){ echo "<tr class='alt'>"; echo"<td style='width:100px'>[url='profile.php?ID=$userid']$username[/url]</td><td>[url='mail.php?action=read&ID=$id']$prefix $subject $sufix[/url]</td><td style='width:100px'>$date</td><td style='width:100px'>$time</td>"; echo "</tr>"; unset($userid); } else { echo "<tr class='alt2'>"; echo"<td style='width:100px'>[url='profile.php?ID=$userid']$username[/url]</td><td>[url='mail.php?action=read&ID=$id']$prefix $subject $sufix[/url]</td><td style='width:100px'>$date</td><td style='width:100px'>$time</td>"; echo "</tr>"; unset($userid); } }   So where i extract the $get_name.. I get a warning: Warning: extract() [function.extract]: First argument should be an array in /home/galdika1/public_html/mail.php on line 157 The exact same logic works perfect in Inbox.. Here the only different thing is the mysql query selects to_id instead of from id... Any ideas anyone?To:Subject:Date:Time:$username$prefix $subject $sufix$date$time$username$prefix $subject $sufix$date$time
  4. So I have started developing a game, I have it hosted on shared hosting now. Well since there is hardly anything there yet, of course it works fast and and everything. What I want to find out is - How long is shared hosting enough? Or even is shared hosting enough at all? Just for the sake of comparison lets say standard MCcodes packet... If I was to install it on some standard shared hosting.. How many active users will I be able to sustain on your average shared hosting? After shared hosting no longer enough.. what's next? VPS package? Dedicated servers? Buying your own servers and hiring systen admin(I personally dont know much about hardware/*nix systems, and if possible would like to be able to get away without having to learn all that stuflf?) As well maybe yous could describe some of the hosts you use/ have used? Here's mine: http://www.justhost.com Well so far so good. Paid around €60 for a year of hosting. Got free domain with it. I have unlimited bandwidth/disk space (yeah I know that hosts that promise that should be avoided, but just needed something cheap for development, and so I could share with people what I done so far, so fair enough.) They're servers are based in Chicago US, I am in Ireland, but never noticed slow load times or anything. Support is always available through 24/7 live chat. And for more serious issues you will have to submit a ticket, which gets replied in timely manner. One bad thing: Crons can only be run at minimum intervals of 15min... So no 5 min crons, which are frequently used in online games. I solved that issue by running crons from different host (I have it for other purpose), so basically if you want to run crons at smaller then 15minute intervals, you wont be able to :)
  5. Time traveler or not... But that tutorial really will come in handy :P Thanks ;)   Tidied up some 'behind the scenes stuff' that nobody will even notice lol Aswell some cosmetic changes that people will notice.. Did not add anything new yet, cause as i said i will work for couple days on tidying up everything I coded so far lol Ok.. Im now off to my real job lol :D Will keep yous updates! :)
  6. Yeah thats much better than PHP manual.. cause actually talks about timestamps in the context that i need! :) Thanks a lot again!!!
  7. I hate php manual... I know that it should be like my bible as starter php dev... But its just so hard for me to understand lol well i try reading it lol Thanks for that!
  8. Thanks :) Well talking about help.. Could you point me to a good tutorial about useing timestamps??? Cause I want to change the city visitors table.. Because at the moment there is just a cron deleting it every 15minutes lol I would like to have something a bit more dynamic.. But still can really use the bloody timestamps lol
  9. Added pickpocketing... You may now pickpocket users that have visited city :P It is not complete yet... You dont receive any events and stuff... But if you got City-->Users in the city, you will see a list of visitors, and you can have a go at pickpocketing them.   So will stop adding new features now, and instead will work on perfecting what I have coded so far.. Because its pretty chaotic lol :D
  10. Oh crap.. I think know the problem :) I must have used the same name name twice for a variable... It happened to me before when I would to mailbox, it would show me the userpane of the last person that sent me mail lol Thank you guys so much for good feedback! Really motivates me! By the way you can use this thread to suggest ideas if you want to! Best time to suggest something when game is in development start stages, cause later something might simply be impossibe to do due things like DB structure etc.. lol
  11. Well here is my story: When i decided to learn web design... I started at w3 schools, reading up on HTML and CSS, once go grips with that (which was fairly easy lol) Decided to move on to PHP... So I literally swallowed all info about it on W3 schools, and did not get a break through... So bought a PHP and MySQL for Dummies, swallowed that as well in 1 or 2 days, still couldnt do anything lol Then watched a few videos on youtube, then when first signs of me understanding the concept behind PHP and coding in general started to come. I recommen searchin for "phpacademy" on youtube, really best PHp videos there is on the web lol But the real breakthroukh came, when I actualy tryed to start coding... I am not really that good yet, but created a PM system, gym system, slots game, register and login system. So the bottom line is.. Look at it as to learning a language. You can read all you want about it, but you will not know it well till you start speaking in it. Same with PHP, just you have to start coding, something simple for starters.. and before you know it you will be on your way ;)
  12. Nope I do not use MC codes... Well I used the in a way, I have downloaded the free lite package, and examined it, just to see what kind of logic is behind the code. But all the code for what I've done so far is written by me from scratch :) No offence to MC codes, but I think if you want to either learn PHP or code a good game, 'from scratch' is the way to go.. Because if you design yourself everything from scratch, you know very well what does what, and in later stages it will be a lot easier to update/modify your game. Meanwhile if using system written by someone else, if you modify it you might not be aware of all the things that modification affects, and so get unexpected results. Well I at the moment have few problems that I have ran into, but will try and solve the myself.. If i get really stuck ill post here :) And you misunderstood the concept of city visitors. There is going to be just one city (well maybe travel destination later on). But the point is, that every time player goes to city, he will be deemed as he is in the city (as opposed to being home) for a certain amount of time. And during that time people will be able to perform various actions on him, lets say pick pocket him. You will only be able to pickopet someone while he is in the city. As well there could be cron running every so minutes to perform various action on people currently in city (item finds, money finds.. well unlimited really. Well i hope you get my drift.
  13. Oh thanks.. :) Was expecting to get flamed lol So am i allowed to update this thread with any new stuff that I add so people can try it/give me feedback? :)
  14. Hello everyone, Just started coding my own text based game. Have few unique (i think unique) concepts. So will try to implement them. I am new to PHP, this is basically the first thing i am trying to put together since my first "Hello world" application lol. You can see it at www.galdikasproject.com (haven't even came up with the name yet lol). There isnt much that I have created yet (slots game, mail system, gym system, some user stats, mail system, almost complete city visitors system (that is one of my unique concepts, i will not elaborate any more on this at the moment , but you will probably know what I mean when you see what ive done so far.) To be honest, my main aim isnt even to create a game, but to learn PHP, and if I create a good game.. well I suppose could be a good bonus. I know all the interface/graphics is basic. But that is what I am aiming for.. A clean tidy environment, that doesn't cause your eyes go red lol. Well anyway... I know it is an early stage yet, but if anyone would like to register and give any feedback would appreciate a lot! If you don't want to register you can use test account username:Test password:test. Basically feel free to do abuse/exploit it in anyway you like lol My ingame id is 1, so we can have a chat there, or leave any comments in this forum. Thanks in advance! galdikas
×
×
  • Create New...