Jump to content

  • Log In with Google      Sign In   
  • Create Account


Member Since 02 Jul 2011
Offline Last Active Apr 04 2013 05:52 AM

Topics I've Started

mysql database

26 December 2012 - 07:28 AM

well im working on a browser based game right now and i came to the part when i need to structure what will be my database, shortly after i started thinking about it i realized i dont have enough experience managing databases at all, so i got a couple questions about it, hopefully one of you can help me out here:


so in the game i want each user to be able to unlock certain items, so i need to keep track of that lock/unlock thing for each item, what i dont know, is how that would work in the database, should i have a user database separate from the item database? or should i use 2 tables inside the same database? how would it work? 


actually being more general, how would the whole database work when it comes to users? what they can unlock, their current status, sessions?, everything related to the database is useful for me right now.


also these items im planning to let the players unlock, can be  more than one, so they would have quantity, so how do i connect an item-table to each user?


im not sure im being clear enough, im not even sure i understand what i need to be asking here, what i do know is that im confused and any help might be just what i need to get going.

web browser game development

22 December 2012 - 06:19 AM

so i have the basics of programming and "visual" web development (i mean i can make things look the way i want them).



the reason im posting here is because i want to learn how to make real time browser games, without using flash, i want to use the tools that come with the browser itself like php, javascript, html5 etc... 


i have some general questions and some specific questions, so lets start with the general ones:


general questions:


1- do you know about a good book that will get me on the right track, specially on the networking part.


2- what is a good way that you would recommend to interact with the database in real time, or interact with other players, i can load stuff from databases and write on them, but usually when i use php to manipulate databases, it requires a submit button to send data to the server, so i would like to know if there is a way to do this without leaving the current page, like with javascript but accessing the actual server.


3- even tho i have knowledge of programming, i have pretty much nothing when it comes to networking, how would it work?, (like the log in stuff, to get the user and have him play against or with other users in real time), that part sounds really scary to me, but hopefully its not THAT hard. so yeah, how would it work? 


specific questions:


4- lets say i want to have a battle between 2 users, each one of them will have 3 characters, and each character wil have 3 different spells, is it a good thing to have every available character and every available spell in the database?


5- (only if the anwer of #4 is yes), then alright, each character in the database will have data like hp, mana, items and pretty much numeric stuff, but it will also have 3 spells, those spells would have complex effects that i cant just put in numbers in the database, so how would it work?, lets say one of the spells should hit one of the enemies for 50 hp, and then break that 50hp and give each of the teammates 50% of that as a shield (25 & 25 with 2 teammates), how would i put all that effect in a database? and how would i use it?




well thats pretty much all i need, feel free to answer even if you cant answer all of the questions, also note that the most important of those for me is #3, because i dont have any kind of experience or basics on that field, so any help will be appreciated, thanks a lot.

HTML 5 Canvas game programming

02 November 2012 - 04:04 AM

so i want to start testing the capabilities of the canvas element of html 5, i already got a couple books on the subject, but i like to code my own stuff, i quickly reached a point where i just had to post here asking for help.

so the thing is, im trying to code a game like Arkanoid, as i think its a game that will test the stuff i need tested on canvas.

so im going to assume you are familiar with Arkanoid games, and im going to show you the problem im having:

as you can see in this flash game:
the player bar movement is really sharp, it follows the mouse like immediately, no delay, almost no flickring.

in my attempt on canvas:
it takes a small delay for the bar to reach the mouse position, i have tried a lot of stuff trying to fix the issue, but i just cant figure out the reason.

so any suggestions?

isometric maps question

25 September 2012 - 09:31 PM

well im trying to make an isometric tile based game using mostly javascript, and i got the map painted and a functional array that stores tile positions, but im having trouble capturing mouse events.

so the real problem is, i can't figure out a way to manipulate the x and y coordinates where i click, and turn them into a number that fits any posible map size, for example

i have a map of 'a' rows and 'b' columns, and i get the tiles stored in a 2 dimensional array, so lets say each tile is 64x32 pixels and i got a 10x10 map, which would use 640x320 pixels.

then there is the problem, when i click anywhere on the map, im capturing the xycoordinates and i can't figure out a way to turn those coordinates, into numbers from 0-9 (for this example), to use them to know which tile im click in on.

i have read a lot of guides on the subject, and i haven't been able to find one that actually works, or that i can understand.

also im not planing to have plain maps, they are going to have like levels or floors and some tiles are going to be placed over other tiles, and so on, so if there is anything i should take into consideration when clicking on that kind of map with floors, it would be welcome as well, even tho i can't really advance on it until i get it to click on plain maps.

thank you in advance and i'd like to point out that i've found some guides on the subject, but i find them really hard to understand, so any help would be appreciated.

Game Programming in Java

25 September 2011 - 12:53 AM

Hello, about 6 months ago, I asked here for advices to get started on java game developing, and I was kind of naïve, trying to start with an isometric strategy game, which after reading a few articles on the subject, I realized it was too hard to begin, so I spent some more time reading about other stuff, I wasted a lot of time doing stuff not programming related and now I finally got to start working on it again, I’ve been working on it for a while now, and I started an easier project, where I want to make a supermario-like game, with side scrolling and platforms and enemies and all that, but before I start programming the game, I decided to make random mini tests of the different aspects that a side scrolling game like this would involve, and that got me a few questions.

So enough of my boring story, the reason im here again is to ask a couple questions that I have, you don’t have to answer all of them, just feel free to help a future game programmer start his career J, I know they are a lot of questions but I will put them all here so I don’t make 10 Posts for each one individually.


1- Whats resolution would you recommend for a fullscreen game, I know there are different resolutions like 4:3, 16:9, etc, and I want to know if there is a possibility of that, affecting my game graphics, like stretching the wallpaper or something, do I have to make different versions of the game for each resolution? Is there a universal resolution that works fine for most computers? For example 1024x768 is probably more common than 1600x1200.

2- Is it good to make a method to catch the actual resolution of the screen and use it for the game?, is it even possible?

3- When I started animating objects, I had to try some different methods to get it to work, first I had to use lots of different png files, and make a loop so they would repaint one after another, however, that method felt too troublesome, and it required a lot of files so I tried making a .gif, and it worked but it had the problem that I couldn’t play with the framerate, I could just play the gif as it is and that’s it, so I started researching a little bit, and I found out there are some kind of spritesheets, that put all the different frames of the animation in one single file, so my question is: how does it work?, it seems to be the perfect method because it gets rid of all the extra files, and I can play with frame rate J.

4- Another question, would be a lot like the last one, I found out about tilesets, which would be pretty much like the spritesheets but for tiles for the maps, and I think the previous answer might answer this one as well, but the difference is that probably not all the tiles will have the same size, so how would it work?

5- And talking about maps, I would like to know if any of you have a good example for a map editor, I saw some algorithms where the map editor wrote a .txt file which would contain some arrays and stuff pointing to each tile in each position, so I read the best way to do it is with a map editor so you don’t have to make the .txt from scratch, but instead you have a small program to do it for you. So that’s the question how can I make a map editor? Or is there a good tutorial for it?

6- Im not sure how the copyright works, but is it illegal to use official sprites of an existing game such as metroid, megaman or Mario?, I mean I think it should be fine as long as I don’t make money out of it, but maybe you guys know better about these copyright rules. (in the case that its illegal, is there a good website with an open sprite list database that I could use? I mean I know how to do all that stuff, but I don’t want to waste time on it, I just want to use existing sprites and use them to make a game which wouldn’t be anything more than a test of my skills and practice).

7- Im not sure how .jar files work, but I need to know if they require the user to have the jvm installer on his computer, in that case my guess is that converting to .exe would be better, but I always read that its not advisable to make such conversion, so how exactly does this .jar work?

8- Talking about .jar, is there a way to encrypt the game in a way that its harder to copy and its harder or even impossible to access the original code so people cant see it or modify it? Would it still be a .jar after that?

9- I’ve read some stuff about how the side scrolling would work, but in fact I don’t understand it quite well, I haven’t been able to find a source code that uses side scrolling, so could you please explain how it works, or share a source code that uses it? Thank you J

10- Is there a website where I can post my games and my tests so people can comment and critique them?, or even better, is there a place in this forum to do just that? J

Ok I think that’s enough questions, and I hope that it can get me to complete my very first game on java, thank you for your time.

there is a possibility that im missing questions that will come when i advance in the project, so if you have an advice or something i should keep in mind that im probably not aware of, feel free to add it :), any extra info would be great ;D.