• Create Account

## Modifying an open source game engine for your needs:Where should I start

Old topic!

Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.

32 replies to this topic

### #1/ Nathan2222_old   Members

Posted 26 November 2013 - 05:06 PM

Hi all.

I'm new to the forum so my question.

At first, i wanted to create a gta style game because i loved it so much. Searched the web for information and i gathered as much as i could. Game engines was a real pain because none were meeting my requirements. Unreal, unity, blender game engine, Bethseda, source engine and even cry engine. Cryengine did come really close but it had some problems.

2. the face that i don't get the source code

3. the fact that cryengine 3 is more optimized than 2 thereby not allowing for really big open world games because of floating points accuracy.

SO which engine did i find, the younger not so popular sister of cry engine, TORQUE 3D. It had almost all what i needed without the crazy license and access to the source code. Now, after going on search the net leave for awhile, watch dogs demos came. I'm watching them as I'm writing this. It is supercalifragilistically awesome. My needs increased because watch dogs has so many things i haven't seen torque do so please i would really want to modify this engine to perfection(almost) and use it.

I can't really seem to find c++ tutorials or maybe i haven't searched enough. I want to modify the torque 3d engine to be really good because it has some faults with  the AI, lip synching, the way plants look water physics and physics is really a must for me.

I am not sure where to start but i have this image gotten from the game engine architecture book. Unfortunately i don't and can't afford the book, yet.

Can someone please point me in the right direction.

Thanks.

#### Attached Thumbnails

UNREAL ENGINE 4:
Total LOC: ~3M Lines
Total Languages: ~32

--
GREAT QUOTES:
I can do ALL things through Christ - Jesus Christ
--
Logic will get you from A-Z, imagination gets you everywhere - Albert Einstein
--
The problems of the world cannot be solved by skeptics or cynics whose horizons are limited by the obvious realities. - John F. Kennedy

### #2PeterF  Members

Posted 26 November 2013 - 06:32 PM

POPULAR

I can't really seem to find c++ tutorials or maybe i haven't searched enough

Does this mean you don't know how to program? If so, starting your programming career with modifying the engine to be "really good" is just going to frustrate you.
These engines (including TORQUE 3D) are horribly complex and have taken teams of highly skilled people ages to put together. If you want to make a game using a prebuilt engine, it's probably in your best interest to just use the engine as it is - and even then it's going to take a lot of work.
If you're still looking for C++ tutorials, try www.cplusplus.com. It's not going to tell you how to modify to the source code of any game engines, but if you're just starting out, you're probably months (or more likely years) of full-time study and practice away from understanding enough to make the changes you want.
It's a hard truth, I know, but one you're going to have to live with.

### #33Ddreamer  Members

Posted 26 November 2013 - 07:22 PM

POPULAR

Hi,

I agree with Peter.

Releasing a new version of a game engine takes the development team months or even years.  They have all the original tools, documentation, and experience with the game engine, yet it requires much time and thousands of lines of coding.

I don't mean to hurt your feelings, but have you estimated the amount of coding that you must search in a game engine?  In the range of 100,000s to 1,000,000s of lines of coding must be searched and parsed.

Added to this, there is the issue of the range of coding to be examined, too.  There is low and high level coding, as well as branches.   Truly only an expert in said game engine, working with a team, could hope to complete a new version in less than a couple of years.

Everything that you need with a game engine can be accomplished by simply scripting a game source code of your own. The game engine might allow Python, C#, Lua, Java, C++, or whatever, and most of them are designed for a particular workflow pipeline of software and applications for most efficient development.

Go trekking into the jungle of a game engine alone if you like, but it is best to follow the proven and beaten path made for the beginner.

Edited by 3Ddreamer, 26 November 2013 - 08:03 PM.

Personal life and your private thoughts always effect your career. Research is the intellectual backbone of game development and the first order. Version Control is crucial for full management of applications and software.  The better the workflow pipeline, then the greater the potential output for a quality game.  Completing projects is the last but finest order.

by Clinton, 3Ddreamer

### #4Rld_  Members

Posted 27 November 2013 - 03:15 AM

What PeterF and 3Ddreamer said is very true, so I won't go into more detail than what they already said.

It's kind of hard to judge if you're new to programming or not due to the vagueness of that in your post. I'f you're new to programming, you should really sharpen up that skill first before you want to dive into existing game engines and alter them for all the reasons (and more) already stated.

In my opinion, the best thing you can do, provided you do have a proper programming knowledge is perhaps not to jump in a fully fledged game engine, but take a render engine and extend on that with the things you want/need. This is a pure speculation, but with the time you're going to invest in making a full fledged game better by adding or altering stuff (and very likely break stuff), it's probably worth more your time and effort to freshly build upon said render engine.

Take a look at Ogre3D or Horde3D. They're both opensource and have plenty of resources to get you started. I would personally go that road instead of learning an entire engine and break it down.

Good luck though

### #5dejaime  Members

Posted 27 November 2013 - 06:43 AM

Well,

It looks like you want to modify a C++ engine without prior knowledge of C++.

If that's the case, you'll need to get a grasp on C++ first. This will probably take weeks of really hard work (or months without classes or a good book).

But tutorials won't cut it; you'll need a better resource. Try to search wikibooks for a good C++ programming one.

If you already know C++, great!

1 - The second thing to do is to define what you need that the engine can't do. Write down the names of the features, or descriptions. You really need to do this step, if you can't name and describe your needs you probably don't know exactly what you want; nor if the engine can do it or not.

2 - Then you should describe why the engine can't do what you want. You'll probably discover some could be done in the engine.

3 - If even after this there's still missing features or capabilities you can go ahead and edit the code for the engine.  If you really gone through step 2, you'll probably know what code you need to edit.

Out of curiosity, could you tell us at least one thing Torque3D can't do that you need?

Edited by dejaime, 27 November 2013 - 06:45 AM.

### #6xenobrain  Members

Posted 27 November 2013 - 01:17 PM

Okay lots of points to address here.

Regarding CryENGINE:

Free for noncommercial, negotiated for commercial, with provisions for indie games.

2. the face that i don't get the source code

Most things you would add would be in the Game layer anyway.  Also, in CE3 most systems are separated into discreet libraries and interacted with through somewhat COM-inspired abstract interfaces, so it's possible to swap some functionality with your own implementations in some cases as long as you program to the interface.

3. the fact that cryengine 3 is more optimized than 2 thereby not allowing for really big open world games because of floating points accuracy.

64x64 sqkm is generally the recommended maximum size of a terrain in CE3.  San Andreas was 36 sqkm.  You've got a massive team to fill all that space with content, do you?

As for Torque3D, nice engine actually difficult to make work for a GTA clone.  No asset streaming.  This can be worked around a bit by cleverly chopping the world to make the zoning load screens happen in logical places, but imposes some restrictions on level design.

I will also point out your complaints about lipsync and AI are off base though, lipsync quality is determined by the quality of your dataset and your character rigging.

AI development can be assisted by some built in state machines, goal system, communication system etc provided by some engines, but that don't inherently mean that having those features (or not) makes the difference between "good" and "bad" AI, it just speeds development.

Anyway, have a look at the Grit Engine.  An open source engine designed specifically for large streaming worlds.

Edited by xenobrain, 27 November 2013 - 01:34 PM.

### #7/ Nathan2222_old   Members

Posted 27 November 2013 - 03:09 PM

Hi people.

I was too blown away by what i saw in the watchdogs video that i forgot what i wanted to ask.

@PeterF: I do know how to program but not C++. Unfortunately i started with VB.NET and can make simple programs, dabbled with "some" C# and when i decided to use visual C++, i couldn't find anything because everytime i clicked debug nothing shows and that really didn't help.
Is codeblocks any good cuz visual C++ doesn't seem natural.
And it won't take me years to learn C++. I learn pretty fast. My estimation is anything from 6 months to 18 months depending, it could be less.
Even if it is horribly complex, my needs won't let me not to really tweak the engine because of what i want. I am ready to learn anything so far as it will help me in this aspect but i can't buy books because i ...

@Rld: Um where would a render engine come in.

@dejaime: Torque can do almost all i want with the exception of lip synching except you have any video showing a lip synched game made with torque. Now, while torque can do most of what i want, it doesn't seem to do how i want it. For instance, if you check videos, you will see the plants looking unreal and that doesn't loo right to me. Water physics in torque is really not that good, in fact i was advised on their forum to use the triton wake generator for anything water related because torque's water physics system isn't that good. Comparing the triton wake generator water to the water i saw in the watch dogs video is like comparing a bicycle to a power bike, i.e. they both do it but one looks better. SO i will have to work on that.
Another thing is cloth physics, actually, i haven't seen any cloth physics so that's that.
I really want everything to look very good, like really and cryengine could do that but it has it's problems.

@xenobrain: Are you sure its 64x64 and not 8x8 or 6x6 because when i asked on their forum, the response was that anything after a 4x4 world would start behaving really weird (physics failing etc.) and since we don't have access to the code like torque, there is no way of changing that. The said this problem wasn't there in cryengine 2 but came in cryengine 3 because of how demanding the crysis game was on hardware so.
As for torque working for my game (it's no longer a GTA clone but rather a game that looks at all the flaws in games and makes sure none of that is there, Pieces of gta, watchdogs, need for speed, splinter cell, call of duty etc.) it should be alright or better  after i learn c++ and refurbishing it.

Like i said, i searched game engines for like a 2-3 months or more and i came across the grit engine. It's being developed by gta modders but it is so far away from doing what i need. They haven't even added npc's into the game engine, only cars. I joined their forum so.

As for the license, i am not so ready to call a company like that to ask for their prices when there are others around. It is said you have to show them what you have before they negotiate so imagine me making the game on cryengine 3 only to here that the license is $5,000-$100,000 because on their site they group games differently and my game will probably fall into the serious games group. Too risky.

The game will be for pc, using the c++ language.

If you checkout watchdogs videos, you will see the physics simulations i am referring to. Water, cloth, vegetation and it's fire looks a bit better than gta V's. One thing that didn't feel right was the driving, it  didn't look good. \other than that you can see things that are not as represented in gta v. hugging on streets, using of pc's, throing stones at camera's etc. Remove the hacking and the repitiveness and you've got a great game.

I found one video that talks about the disrupt engine and what makes everything in the game move so real because of the wind.. Watch it to the end and you will see. It starts wierldly though so please ignore the first 3- 10 minutes

Edited by Nathan2222, 27 November 2013 - 06:33 PM.

UNREAL ENGINE 4:
Total LOC: ~3M Lines
Total Languages: ~32

--
GREAT QUOTES:
I can do ALL things through Christ - Jesus Christ
--
Logic will get you from A-Z, imagination gets you everywhere - Albert Einstein
--
The problems of the world cannot be solved by skeptics or cynics whose horizons are limited by the obvious realities. - John F. Kennedy

### #8/ Nathan2222_old   Members

Posted 27 November 2013 - 03:56 PM

This is the water i saw in the video and it moves like real water for a game. How hard will it be for me to accomplish these things

UNREAL ENGINE 4:
Total LOC: ~3M Lines
Total Languages: ~32

--
GREAT QUOTES:
I can do ALL things through Christ - Jesus Christ
--
Logic will get you from A-Z, imagination gets you everywhere - Albert Einstein
--
The problems of the world cannot be solved by skeptics or cynics whose horizons are limited by the obvious realities. - John F. Kennedy

### #9Tutorial Doctor  Members

Posted 27 November 2013 - 04:25 PM

If I knew C++ you can bet I'd be modifying the engine I am using which is free and open source and the license is very clear on that.

I can only use the Lua scripting right now, but when I buckle down and apply myself to learn C++ this is the engine I will be using. It is called Maratis 3D.

As for your screenshot, I actually do think that such a look is very capable in Maratis, although it doesn't offer a lot of tools to help make it easier (you'd have to make it yourself.) I have to bake in my color and ambient occlusion before I enter Maratis.

To get the water to look like that you could use an animated normal map (which I have yet to do in Maratis, although I have done animated textures to make water).

Someone has also simulated fog in Maratis. As for the buildings I would use Google Sketchup (this is my software of choice hands down when it comes to environment modeling). My main hang up is all the time it takes to texture all the buildings (although I am finding a workflow for doing such a thing.)

Here is a link to my showcase on what technical things I was able to do with Maratis:

http://forum.maratis3d.com/viewtopic.php?id=738

I also have other posts on the site as well with more photos.

Edited by Tutorial Doctor, 27 November 2013 - 04:26 PM.

They call me the Tutorial Doctor.

### #10/ Nathan2222_old   Members

Posted 27 November 2013 - 05:12 PM

You're a really good modeler. i really like the characters.

Maratis is based on blender game engine which i plan on using. You say it can create that kind of water which torque can too but can it create the waves. The waves are important.

The UI doesn't look nice.

I'm gonna stick with torque.

Can somebody please watch that video in the link i pasted and tell me if it's possible to add that functionality in the torque engine, i.e. the part where they start talking about disrupt engine

UNREAL ENGINE 4:
Total LOC: ~3M Lines
Total Languages: ~32

--
GREAT QUOTES:
I can do ALL things through Christ - Jesus Christ
--
Logic will get you from A-Z, imagination gets you everywhere - Albert Einstein
--
The problems of the world cannot be solved by skeptics or cynics whose horizons are limited by the obvious realities. - John F. Kennedy

### #11Tutorial Doctor  Members

Posted 27 November 2013 - 05:21 PM

Maratis itself can't create much (it is just an editor) but the waves, whether in torque or cry or udk perhaps use displacement maps rather than normal maps (to actually affect the geometry), unless torque has a fluid simulation system built in.

Maratis doesn't have this type of functionality built in, but if you were to program that functionality yourself you could pretty much make your own game engine using Maratis as a base.

I am going to look into torque to see what it can do.

Edit: I just checked out torque and I see it is free. The setup is a bit complicated for me. I would actually prefer Unity 3d in that case (accept for the cost to publish with Unity3D). So it seems like Torque is best for you then.

Maratis does have a very easy to understand API though. Perhaps I will take some time out to try Torque later on.

Edited by Tutorial Doctor, 27 November 2013 - 05:36 PM.

They call me the Tutorial Doctor.

### #12/ Nathan2222_old   Members

Posted 27 November 2013 - 06:29 PM

Watch that video and check the water, you'll see what i mean.
How hard will it be to create such AI, simulation etc.

Edited by Nathan2222, 27 November 2013 - 06:33 PM.

UNREAL ENGINE 4:
Total LOC: ~3M Lines
Total Languages: ~32

--
GREAT QUOTES:
I can do ALL things through Christ - Jesus Christ
--
Logic will get you from A-Z, imagination gets you everywhere - Albert Einstein
--
The problems of the world cannot be solved by skeptics or cynics whose horizons are limited by the obvious realities. - John F. Kennedy

### #13/ Nathan2222_old   Members

Posted 27 November 2013 - 06:36 PM

Maratis itself can't create much (it is just an editor) but the waves, whether in torque or cry or udk perhaps use displacement maps rather than normal maps (to actually affect the geometry), unless torque has a fluid simulation system built in.

Maratis doesn't have this type of functionality built in, but if you were to program that functionality yourself you could pretty much make your own game engine using Maratis as a base.

I am going to look into torque to see what it can do.

Edit: I just checked out torque and I see it is free. The setup is a bit complicated for me. I would actually prefer Unity 3d in that case (accept for the cost to publish with Unity3D). So it seems like Torque is best for you then

I will be using the triton wake generator for water simulation and also physx, hopefully i can get the source codes.

No maratis and unity is too mobiley

UNREAL ENGINE 4:
Total LOC: ~3M Lines
Total Languages: ~32

--
GREAT QUOTES:
I can do ALL things through Christ - Jesus Christ
--
Logic will get you from A-Z, imagination gets you everywhere - Albert Einstein
--
The problems of the world cannot be solved by skeptics or cynics whose horizons are limited by the obvious realities. - John F. Kennedy

### #143Ddreamer  Members

Posted 27 November 2013 - 09:47 PM

Nathan!

All that long list of things that you want for a game is going to demand a team.   Not only that, but you will be in real desperate need of source and version control software.  That alone is going to require part time effort minimum.

Doing that long list of development stages you revealed here will take an individual years.  I know an expert C++ game developer who took over a decade to make something which was finished but is several years behind the times.  Contrast that with a C# expert lead programmer who I know that takes many months with a team to complete a project. You Have Know Idea the amount of hours of coding required to do what you stated is your goals.  At the typical beginner's pace of 10-50 lines of coding per day, you will be working on the same game 10 years from now by yourself.

Your skills are not ready for navigating game development at a great pace, which will takes years in its own right to earn the experience.

I am not trying to discourage you, but a team takes years to get a craft into space, let alone unto the Moon and eventually Mars, if you know what I am saying. You are aiming for Jupiter already!

Did you really take all the advice in this thread to heart?

Personal life and your private thoughts always effect your career. Research is the intellectual backbone of game development and the first order. Version Control is crucial for full management of applications and software.  The better the workflow pipeline, then the greater the potential output for a quality game.  Completing projects is the last but finest order.

by Clinton, 3Ddreamer

### #15Rld_  Members

Posted 28 November 2013 - 03:04 AM

The reason I initially stated that you could use a render engine is due to the fact that you give the impression that you want to take an entire game engine, tear it apart, fix and add to it what you want and put it back together again. Next to the fact that perhaps the things you want to add to an engine might not be feasable or possible in any or proper way (I don't know the source of torque by heart, so I'm not saying anything final here).

With the time and effort you spent on learning how the engine works from top to bottom so you don't break anything, you might as well take a barebone render engine where the graphics part is taken care off and the look and feel is largely free to your own imagining and do everything your way.

I'm not saying this is the best way to go, but also considering the fact that you still need to learn a lot, this might also be a better learning experience for you.

Look at it this way:

I'm not a car mechanic. I know a few bit here and there, but that doesn't make it viable for me to take a car, strip it down, alter/replace what I want and put it back together. Can I do it? Probably, if I take real good care. Will it be exactly what I want it to be? Very unlikely, because I don't know every detail about the car, I don't know if I accidentally removed/altered some dependency which will cause the car to break down (or even start).

Instead, I'd rather get a chasis and slowly build the car up, learning every bit I add. Add it carefully with full knowledge of what I am doing. In the end, I hopefully have what I wanted, but this time, because I took time and care about every piece, I know the car inside out and if something should break, I know where to look and how to fix it.

Perhaps it's something personal, perhaps you simply enjoy the breaking down part. It's all up to you of course.

All I can say is; Take these peoples advice, it's solid.

### #16samurliko  Members

Posted 28 November 2013 - 09:25 AM

Are you sure that what you need can't be done with shaders of scripting? You'll find that engines seen limited at first, but amazing things can be done once you start.

### #17Dwarf King  Members

Posted 28 November 2013 - 10:07 AM

Another thing is cloth physics, actually, i haven't seen any cloth physics so that's that.

Well here you go:

http://vimeo.com/5215101

"The only thing that interferes with my learning is my education"

Albert Einstein

"It is a miracle that curiosity survives formal education"

Albert Einstein

### #18ByteTroll  Members

Posted 28 November 2013 - 11:34 AM

There are a lot of other people here that have, for the most part, summed up what I am thinking.  For this reason, I will not restate their information.  With this being said, I think you need to heed other peoples warnings and take it to heart.  While I don't mean to discourage you, the fact of the matter is this: you need to reevaluate you current goals.  You say that you want to modify a game engine (that you did not code and have no knowledge of), going on to state that you have no knowledge of C++.  Plain and simple -- this is not going to happen.  It takes many man hours and huge teams of people to achieve what you are wanting to achieve.  I have 8+ years coding with C++; before that, I had several years of low-level C coding.  I (as well as most other programmers) work for 10+ hours a day.  At this rate (in a team), it would still take years to achieve what you are wanting to do.  Adding to the point of not knowing C++, you state that it won't take you years to learn C++, only a couple of months.  I don't know a single programmer (including myself) that is still not learning their language a decade after they started.

With that out of the way, I will offer you this advice.  You hint at the fact that you know how to program in another language.  I assume that your goal is to make a game.  My advice to you is move into mobile development.  This will teach you some things that can be applied to other languages, it can be done with a smaller number of man hours, and there is money to be made.  After you spend some time there, then move on to smaller projects.

"The code you write when you learn a new language is shit.
You either already know that and you are wise, or you don’t realize it for many years and you are an idiot. Either way, your learning code is objectively shit." - L. Spiro

"This is called programming. The art of typing shit into an editor/IDE is not programming, it's basically data entry. The part that makes a programmer a programmer is their problem solving skills." - Serapth

"The 'friend' relationship in c++ is the tightest coupling you can give two objects. Friends can reach out and touch your privates." - frob

### #19/ Nathan2222_old   Members

Posted 28 November 2013 - 04:06 PM

@bytetroll: I'm not doing mobile games. That's for a future future and my expectation is to create THE GAME not just any game but until i find/make the engine that's gonna help me do that, i'll make smaller games while making the engine.

I dign't say that it will take me a couple of months to become really good at c++, it will take me a couple of months to learn it not perfect it and yes i know that if you don't keep practicing, you'll know less.

@Rld: If i "misunderstood" you correctly, you may have just given me a great advice. Is this what you mean:
Rather than try to modify torque engine which will require that i read all the code and could possibly take forever, I should make an entire game engine which will not only be easier than modifying torque but i can make it as simple as i wan't to and to suit my needs,i.e. i should use a render engine such as ogre 3d as a base which would solve the rendering part of the game engine.

If this assumption is correct then which do you recommend i start with, Ogre 3d or Horde 3d:
Ogre 3d's license is perfect if i want to change it to a game engine. One problem is that it does not support dx11 but dx9. Other than that, it's perfect.

Horde 3d is smaller than ogre 3d and it's license is not that good, it also doesn't support dx11.

If you are reading this and this is what you meant, then this list below is ggoing to solve some problems, right:

Physics:
1. Physx + source code for physics engine

3. Beam Ng (car physics and by the time it's completed, everthing PS: I contacted them)
2. Custom physics engine for the game engine
3. Havok (maybe)

Sound:
1. Fmod Studio

Graphics Renderer:
1. The base which is Ogre 3d (i think it's better)

Game Engine Camera:
1. All views

Asset creator:
1. Blender
2. Zbrush
3. Gimp

Graphical Interface:
1. DirectX
2. Open GL (maybe not)

Platform:
1. Windows PC

Language:
1. C++ (obviously)
2. Lua as scripting language

Genre of games for engine:
1. OPEN WORLD
2. Racing
3. FPS (maybe)

AI:
This is a problem, anyways:
1. Custom AI for engine (this will be the real AI system)
- Character AI
- NPC AI
- Enemy AI etc.
2. Universal AI Kit from torque (i'll just use it to as a reference for creating mine)
3. Tactical AI Kit from torqque (reference also)

Lighting:
1. Ogre 3d ( please tell me ogre 3d takes care of these - dynamic shadows, particles, subsurface scattering etc.)

World Size supported by engine:
1. 6km x 6km - 10km x 10km or more

1. For open world- NONE
2. For Levels: Maybe

Others:
1. Ragdoll physics
2. Motion Capture support

I chose ogre 3d instead of horde 3d. Does it support really large world rendering without loading screens when driving in a fast vehicle. and can you give any idea on how to change to dx11.

As you've seen the list above, it's mostly gonna be an open world game engine/racing. All the sdk's help me but just a bit. I would really like if i misunderstood correctly.

I know i probably haven't covered all i need so please give me pointers.

Finally, if i was correct then this photo becomes extremely important as it will act as a blueprint, right?

I need lua as a scripting language because it's simple, small and the fastest scripting language from what i checked.

It will be a 3d game engine. It will need tons of c++ programming right?

#### Attached Thumbnails

Edited by Nathan2222, 28 November 2013 - 04:54 PM.

UNREAL ENGINE 4:
Total LOC: ~3M Lines
Total Languages: ~32

--
GREAT QUOTES:
I can do ALL things through Christ - Jesus Christ
--
Logic will get you from A-Z, imagination gets you everywhere - Albert Einstein
--
The problems of the world cannot be solved by skeptics or cynics whose horizons are limited by the obvious realities. - John F. Kennedy

Posted 28 November 2013 - 05:16 PM

Mmmkay.First you need to get a good understanding of the engine you are working with. And if you want to do great water you need to know your maths. Cloth physics, you really need to know your physics,

When I was young I had no idea how most of the programmers achieved anything. I learned though, it took a long time. I'm still learning.

"Most people think, great God will come from the sky, take away everything, and make everybody feel high" - Bob Marley

Old topic!

Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.