Welcome Guest ( Log In | Register )

[ Big| Medium| Small] -



Post new topic Reply to topic  [ 3 posts ] 
    levenita
  Wed Nov 13, 2013 11:29 am
Member

I'm wanting to create a game engine from scratch. I've not got much expeirence in any programming language. But at the moment i have started learning java. Can anyone point me in the correct direction? Once my game engine is complete i want to create a game like Grand theft auto Crossed with smackdown vs raw 2010 Serious answers only please.


Top Top
Profile      
 

    Amy
  Thu Nov 21, 2013 12:16 pm
User avatar
Staff

Big Dumb Guy
At Uni we did it from a SAMS book - called something like "how to make a game engine in 24 hours". It was quite useful. What we learned could be applied to any language I guess. There must be tutorials online from googling, I'm not sure.

Basically though the main things you'll want to learn are a graphics library, finite state machines, and basically just how to make a game loop. I'm not sure I'm the one to teach that, there must be better tutorials on that on Google. OpenGL is the graphics library we used and there are many tutorials for it.

But if that's too vague or you need any help don't take ^ for an answer.


Top Top
Profile      
 

    aphadeon
  Sun Nov 24, 2013 1:03 pm
1987-2023
User avatar
Staff

Generic Townsperson
My suggestion:
Start with a simple loop. Something like:

Expand to see the code.


You say from scratch, but I do strongly suggest using libraries. For my C++ projects, I'm using:
Allegro - for all around cross platform help-y stuff (windows, input, basic sound, etc). It has drawing capabilities, but if you want 3d, they suck. learn opengl and roll your own. I suggest learning Allegro5, and using the addon modules for things like Fonts.
Audiere - if you need more advanced sound stuff.
Some kind of database - even if you end up just using your own flatfile format, you'll need a way to load/save/manipulate data. (For a project I'm on at the moment, I'm using SQLite.)


Anyway, once you have your loop and you're all "linked" up, you'll want to get a better workflow in place. The above example might come to resemble something like this:

Expand to see the code.

Once you have that, you'll want to get state management in place. I use a parent class with subclasses, but there are countless ways to implement states. I'll offer one hint: states don't have to be a single variable. Google, and consider, a "state stack", as for some game types that makes certain things significantly easier.

Once you get state management, from there on its all about your engine. Improve or replace those functions, and continue to add and improve and replace and cull the crap until its nice and shiny.
And then, at long, long last, that awaited day, when the actual work can begin.


Edit: the snippets arent real code. hell they aren't even good examples.
but they do summarize the concept I was trying to get across.


Top Top
Profile      
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 3 posts ] 


Who is online

Users browsing this forum: No users and 5 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

We are an independent, not-for-profit game making community.
Homepage
Board Index
About Us
Downloadable Games
Free Browser Games
Games in Development
RPG Maker Support
Game Maker Support
Construct 2 Support
HBGames the eZine
Advanced RPG Maker
Site Announcements
Powered by phpBB © phpBB Group