Read-only archive of the Armageddon Games Forums Archive (2000–2026) · About this archive

Next Gen ZC. (Otherwise known as ZC3.0)

48 replies · 74,284 views · Started 20 June 2015

Mostly to Gleeok but could apply to everyone
[MENTION=42714]Gleeok[/MENTION]
I'm really not trying to be offensive, just spreading knowledge.

Data structures and OOP are one in the same. OOP is just organization. Here's an example program I was using myself with a team for a university project for software change requests.
https://github.com/Gr1N/EasyPaint

The implementation for classes (data structure) is still data-oriented but designed in a way to improve stability and balance, speed is important but you'd be better off writing everything in assembly if that's your main goal.

The classes used for drawing graphics and memory management can still be data-oriented, but encapsulated.

Samer wrote:Mostly to Gleeok but could apply to everyone
[MENTION=42714]Gleeok[/MENTION]
I'm really not trying to be offensive, just spreading knowledge.

And I'm really sorry I even brought up concerns about the performance of drawing tiles and maps in Solarus. 😞

I only did so because I know how it works internally. :badrazz:

From SDL 2.03 source:


static int
GL_RenderCopy(SDL_Renderer * renderer, SDL_Texture * texture,
const SDL_Rect * srcrect, const SDL_FRect * dstrect)
{
GL_RenderData *data = (GL_RenderData *) renderer->driverdata;
GL_TextureData *texturedata = (GL_TextureData *) texture->driverdata;
GLfloat minx, miny, maxx, maxy;
GLfloat minu, maxu, minv, maxv;

GL_ActivateRenderer(renderer);

data->glEnable(texturedata->type);
if (texturedata->yuv) {
data->glActiveTextureARB(GL_TEXTURE2_ARB);
data->glBindTexture(texturedata->type, texturedata->vtexture);

data->glActiveTextureARB(GL_TEXTURE1_ARB);
data->glBindTexture(texturedata->type, texturedata->utexture);

data->glActiveTextureARB(GL_TEXTURE0_ARB);
}
data->glBindTexture(texturedata->type, texturedata->texture);

if (texture->modMode) {
GL_SetColor(data, texture->r, texture->g, texture->b, texture->a);
} else {
GL_SetColor(data, 255, 255, 255, 255);
}

GL_SetBlendMode(data, texture->blendMode);

if (texturedata->yuv) {
GL_SetShader(data, SHADER_YV12);
} else {
GL_SetShader(data, SHADER_RGB);
}

minx = dstrect->x;
miny = dstrect->y;
maxx = dstrect->x + dstrect->w;
maxy = dstrect->y + dstrect->h;

minu = (GLfloat) srcrect->x / texture->w;
minu *= texturedata->texw;
maxu = (GLfloat) (srcrect->x + srcrect->w) / texture->w;
maxu *= texturedata->texw;
minv = (GLfloat) srcrect->y / texture->h;
minv *= texturedata->texh;
maxv = (GLfloat) (srcrect->y + srcrect->h) / texture->h;
maxv *= texturedata->texh;

data->glBegin(GL_TRIANGLE_STRIP);
data->glTexCoord2f(minu, minv);
data->glVertex2f(minx, miny);
data->glTexCoord2f(maxu, minv);
data->glVertex2f(maxx, miny);
data->glTexCoord2f(minu, maxv);
data->glVertex2f(minx, maxy);
data->glTexCoord2f(maxu, maxv);
data->glVertex2f(maxx, maxy);
data->glEnd();

data->glDisable(texturedata->type);

return GL_CheckError("", renderer);
}

Can we drop it now?

Samer wrote:C++ is usually the most balanced programming language for games.
Memory management has to be done manually though.

It's not that Java and others are bad, they just aren't really cross-compatible and they spring up memory leaks like there's no tomorrow.

Sharing this Game Design Book:
Intro to Game Development

It's pretty big, and it's graduate level but I'm sure everyone here knows what they're doing.
It's too big to preview so you have to download it.

Thank you...
I can use this.
J~

[MENTION=61120]Jaydeadone[/MENTION]
No problem, it's for the good of the community. Sharing is caring and w/e.
I just wanted to put an end to useless banter.

I put that out there because ZC suffers from too many flaws.
I'm glad you could use it.😃

Samer wrote:[MENTION=61120]Jaydeadone[/MENTION]
No problem, it's for the good of the community. Sharing is caring and w/e.
I just wanted to put an end to useless banter.

I put that out there because ZC suffers from too many flaws.
I'm glad you could use it.😃

Well don't expect much contribution out of me for quite awhile...I am still in the beginner's phase of of Python and then I plan to learn C++. The memory management part of C++ kind of scares the shit out of me...

J~

[MENTION=61120]Jaydeadone[/MENTION]
Don't worry about it bro. It all comes with practice.

One rule of thumb, NEVER delete pointers outside the destructor as which it will relatively always cause Heap Corruption.
I'd start with data structures first before moving to Object-Oriented. If you don't know data structures it will be really difficult, tedious, and you will give up.
I can send a link for my Data Structures & Algorithm Analysis if you want and slides to Software Engineering using the AGILE manifesto/Scrum/XP, etc.

Start with the basics, I've been there. Ambitions w/o a plan relatively always end up in failure and/or defective software.
Software development is the same as making games (quests are different, they're more like rom hacks).

Depending on how you want your memory managed there are many different ways to do it. For saving, the Doubly-Linked List (dynamically allocated) is the best one. If you need A LOT, then you'd need like an AVL Tree, or Balanced Binary Search Tree.

Start with the basics.

Samer wrote:[MENTION=61120]Jaydeadone[/MENTION]
Don't worry about it bro. It all comes with practice.

Start with the basics.

Is C++ for dummies basic enough? Lol...
My first goal is to make copies of programs, then open up the working program and tweak it and see how it reacts. Something like Fallout or Baldur's Gate comes to mind. These would be easy to mess with I think. They might have their own language mixed in though...BG uses the Infinity engine. IE: adding a weapon or enemy that doesn't exist in the original game...but this also requires that I have a concept of how the graphics work. I am certain I will frustratingly fail my first few attempts.

J~

I would actually recommend to start with the basics of the basics. 😉 Not only will you have no idea what a big game is doing, you also won't know why, or how.

What is the basics? Don't bother with any big libraries (including stl), and just use plain data such as simple structs, arrays, and pointers for everything. You won't have any memory problems if you don't allocate memory for every stupid little thing that shouldn't even of been allocated in the first place. KISS: Keep it simple stupid. Make a simple game, like breakout or asteroids. Once you understand what you are doing then you can do more complicated things and learn design patterns. I can honestly tell you that I've never once ever, ever used a BTree (ie., map),or Doubly-Linked List, in game programming. They are mostly useless. Just take a simple graphics API like SDL or allegro, and make something, anything, using only basic c++. Don't use templates.

Sometimes I feel like I'm going insane from all this craziness where I am, but [MENTION=42714]Gleeok[/MENTION] is right, basics of basics.

C++ for dummies in the beginning is good enough. I think codeacedemy might help you too. Sometimes craziness makes us (me) forget the struggle we had to go through.
You are doing good, practice, I have serious ADHD and I'm only 23 I just don't know how to put my age on here.

I think the lack of backwards compatibility sets a bad precedent, or it could...........but then the part of this being capable of making ALTTP style quests gives me an idea.

What if this WASN'T Zelda Classic 3.0, but ALTTP Classic? ALTTP's popularity was high enough to spark the development of A Link Between Worlds, and with that, comes an opportunity to reignite interest in Zelda Classic and the whole AGN. It would be easy to distinguish ALTTP Classic quests from ZC quests and separate them into different databases. And then, the old Zelda Classic could always be updated again if anyone at AGN so chooses without it seeming weird. Not to mention, it doesn't isolate itself from past custom quests, but compliments their existence by being both a different game and a different tool, which would not have happened without a long devoted fanbase of the former.

I think this idea is seriously worth considering. Plus, it may inspire someone to finally make Zelda 2 Classic......I hope anyway........

Gleeok wrote:I would actually recommend to start with the basics of the basics. 😉 Not only will you have no idea what a big game is doing, you also won't know why, or how.

What is the basics? Don't bother with any big libraries (including stl), and just use plain data such as simple structs, arrays, and pointers for everything. You won't have any memory problems if you don't allocate memory for every stupid little thing that shouldn't even of been allocated in the first place. KISS: Keep it simple stupid. Make a simple game, like breakout or asteroids. Once you understand what you are doing then you can do more complicated things and learn design patterns. I can honestly tell you that I've never once ever, ever used a BTree (ie., map),or Doubly-Linked List, in game programming. They are mostly useless. Just take a simple graphics API like SDL or allegro, and make something, anything, using only basic c++. Don't use templates.

Thank you very much for the advice. I tend to take on projects bigger than my skills most of the time, in everything I attempt. This has both had positive and negative results. (However, it usually ends up with my frustrated to the point of taking a hiatus). I'll try to program a couple of your recommendations and move from there.
Thanks again for the Advice,
J~

Chris Miller
http://www.codeacademy.com

This might be of help to you.

Thanks Chris, I'll check this out.

Samer
Sometimes I feel like I'm going insane from all this craziness where I am, but @Gleeok is right, basics of basics.

C++ for dummies in the beginning is good enough. I think codeacedemy might help you too. Sometimes craziness makes us (me) forget the struggle we had to go through.
You are doing good, practice, I have serious ADHD and I'm only 23 I just don't know how to put my age on here.

Thanks for the vote of confidence Samer and I totally know how you feel with the ADHD...I am pretty sure I managed to slip through school wearing a good mask to keep from being medicated. In my adult life I have somewhat managed to get a hold on my randomness in tasks and have been learning to prioritize like normal people do. It's not always easy though.
Thanks again for all your patience and help.
J~

ALTTP Classic sounds like a good title, yet 2.5 quests should either have a dedicated 3.0 zelda-w.exe for playback plus it's own zquest.exe because some of us are only just beginning to learn what 2.5 can do plus some of us have been using it for years now.

If we don't include the default graphics we might as well make 32x32 the default tile size and 20x15 tiles with anti-aliasing for a change since we are probably going to be using 24 bit real color.
You might say this is madness. Note that Zelda Classic's color depth is hardcoded at 8-bit (256 colors 16 of which are system reserves). The palette system is stupid and archaic and most programmers use shaders now a days.

tl;dr it's not 1986 we need to update the graphics mode.

My two cents:

efficient, efficient, efficient!

Wherever possible make things more efficient. One thing that annoys me is the ever-increasing bloat of software. RAM usage can be whatever it needs to be, but processing power required should be as low as feasible. Especially considering this will be a 2D thing.

Personally i have an affinity for netbook. I prefer them vastly over touchscreen-based devices (which are garbage). If ZC 3.0 can run at 60FPS no matter what (barring maybe having a metric shit ton of sprites/effects/whatever) on screen at once of an amount that is abnormal) on say, a CPU that is 1.5 GHz dual-core (which I know doesn't mean a lot as 1.5 GHz varies in power depending on what CPU model you're dealing with) then it will be perfect.

To that end: MULTI-THREADING.

Please please PLEASE, if it's reasonably possible/feasible to do so, grant ZC 3 the ability to use as many cores as are available, as necessary. I assume ZC 3 will be hardware-accelerated so CPU power becomes less of an issue, but still.

So yeah that's about it from me. My thing is efficiency. If this was the year 2115 then I want ZC 3 to still be playable on an Intel N2600 (CPU model).

Gleeok wrote:This has been brought up an inordinate amount recently and based that it might be time to take it seriously. Here are a few resources from past discussions and proposals:

Recent thread (Very recent, only a few weeks old) :
http://armageddongames.net/showthread.php?96959-ZC-3-0-From-Scratch-Plan

Old DarkDragon post that was previously hidden from public view:

To summarize, any discussion on this in the past two years has just boiled down to the following:

1. Will be open source and primarily written in c/c++.
2. Take advantage of well tested 3rd party libs for portability (ie,; windowing, input, etc.). Don't use allegro.
3. A game engine or framework should be at it's core, and should be independent of Zelda-related IP or other copyrighted materials. The community can easily add a Zelda resource pack just like using a tileset in ZC.
4. Use qt for the GUI.
5. Use a fast and powerful scripting language like Lua, or C#. (Alternates have been brought up before, such as python or javascript, but are usually met with mixed results, however there's nothing stopping anyone from adding bindings to all of these later on!)

Obviously no single person is crazy enough to do this by themselves.

I'm willing to contribute one component to the project if it gets started, and maybe more as things get finished, or I finish with that. I also have a lot of things that I've done for my own project that may be able to be used without much work as well. maybe more if the core code is very similar. Maybe lots if it is compatible.

If anyone is interested in working on it then reply here and feel free to throw yer two cents into the well and make a wish.

[edit]
Side note: This isn't a "Add more combo flags to ZQuest, or add this feature to ZC" discussion. Please use the suggestion forum for that.

Since plans have changed since then, is this really needed here, it might confuse some people.