Thrive Game Development

Development of the evolution game Thrive.
 
HomeHome  PortalPortal  CalendarCalendar  FAQFAQ  SearchSearch  MemberlistMemberlist  UsergroupsUsergroups  RegisterRegister  Log inLog in  
Welcome new and returning members!
Sign up and introduce yourself. ADMIN knows your ASL.
If you're new, read around a bit before you post: the odds are we've already covered your suggestion.
We are working with a relatively new theme, so visual bugs are being addressed.
ADMIN reminds you that the Devblog is REQUIRED reading.
Currently: The Microbe stage environment is taking shape.
Log in
Username:
Password:
Log in automatically: 
:: I forgot my password
READ BEFORE POSTING
FAQs Wiki OE CC Thrive
Search
 
 

Display results as :
 
Rechercher Advanced Search
Statistics
We have 852 registered users
The newest registered user is xplinux557

Our users have posted a total of 22761 messages in 1101 subjects
Who is online?
In total there are 4 users online :: 2 Registered, 0 Hidden and 2 Guests :: 2 Bots

Daniferrito, NickTheNick

Most users ever online was 443 on Sun Mar 17, 2013 4:41 pm
Updated Research Web
Wed May 08, 2013 5:20 pm by NickTheNick
Okay guys, here is my first Devblog to fulfill my responsibility as Strategy Team lead.

Finally I have procured some work to show for my efforts in conceptualizing the Strategy Mode. The Research Web is a pivotal component of post-sapience gameplay, as it is what drives your species forwards from the Awakening stage to their final steps into Ascension. Through a graphing program, I have managed …

[ Full reading ]
Comments: 5
Keywords
wiki editor date organism tech biomes music Devblog microbe planet video auto prototype research Thrive Gameplay creature space progress tree underwater evolution game stage cell concept
Latest topics
» Concept Art Thread
by WJacobC Today at 6:42 pm

» Miscellaneous Bugs And Questions That Don't Deserve Their Own Thread Thread
by Tritium Today at 4:02 pm

» Building Microbe Stage
by Nimbal Today at 3:55 pm

» Another Idea: 'Over tech'
by Daniferrito Today at 2:42 pm

» Hello there!
by Doggit Today at 2:16 pm

» Organ Design
by Mysterious_Calligrapher Today at 10:36 am

» Forum Rules/Etiquette
by Mysterious_Calligrapher Today at 9:08 am

» Bilinguals wanted! Quiero personas bilingües! Je veux bilingues!
by Mysterious_Calligrapher Today at 9:05 am

» Function Part Discussion
by Daniferrito Today at 7:24 am

» Parallel work on multiple stages
by Tritium Today at 4:37 am

» types of government
by NickTheNick Yesterday at 8:05 pm

» Compound Tags and Properties
by Daniferrito Yesterday at 5:50 pm

» Food and Consumption
by NickTheNick Thu May 16, 2013 9:18 pm

» Another new guy :)
by cornflakes91 Thu May 16, 2013 6:08 am

» Strategy Mode Discussion
by cornflakes91 Thu May 16, 2013 5:59 am

» Cultural Trait Brainstorming
by NickTheNick Wed May 15, 2013 5:57 pm

» LTL Weapons
by Xazo-Tak Tue May 14, 2013 8:03 pm

» Holidays affecting gameplay?
by Thriving Cheese Tue May 14, 2013 1:16 pm

» Build system discussion
by Nimbal Tue May 14, 2013 6:58 am

» Revamping the Forum
by Xazo-Tak Mon May 13, 2013 11:11 pm

Share | .
 

 Class Structure

View previous topic View next topic Go down 
AuthorMessage
roadkillguy
Experienced


Posts: 534
Reputation: 16
Join date: 2010-08-25
Age: 19
Location: Rhode Island

PostSubject: Class Structure   Mon Jun 25, 2012 2:01 pm

By Daniferrito: This no longer stands for our current code

Here's a class structure I was thinking of, that should take care of everything up through creature stage.

Code:

Resource
    WorldObject
        Organism
            Cell
            Creature
            Plant
        Particle
        Rock
        Organics
    Atmosphere
    Soil
    BodyOfLiquid


Where a Resource is a list of compounds, a WorldObject has a position, and an Organism has an eat() function.

Depending on the class, it might be useful to have a parallel definition class structure as follows.

Code:

ResourceDef
    WorldObjectDef
        OrganismDef
            CellDef
            CreatureDef
            PlantDef
        ParticleDef
        RockDef
    AtmosphereDef
    SoilDef
    BodyOfLiquidDef


All of these will store data for a particular species, etc. Each class will contain a reference (const Def &) to its particular definition class.

EDIT:I'm pretty sure this will only be useful for Organisms, Particles, and Rocks.

That's my idea, let me know if you have questions.


Last edited by roadkillguy on Mon Jun 25, 2012 6:37 pm; edited 1 time in total
Back to top Go down
View user profile
Gawayno
Newcomer


Posts: 22
Reputation: 0
Join date: 2012-06-23
Age: 20
Location: Chicago, IL

PostSubject: Re: Class Structure   Mon Jun 25, 2012 3:30 pm

So this is what the class structure in C++ looks like huh? We would use curly brackets and a specific term, such as string, int, etc in C#.
Thanks for this, I'm starting to understand C++ even more.
Back to top Go down
View user profile
~sciocont
Overall Team Lead


Posts: 3172
Reputation: 99
Join date: 2010-07-06

PostSubject: Re: Class Structure   Mon Jun 25, 2012 4:09 pm

This seems pretty thorough. What about waste products/carcasses? They could be part of an "Organics" class under WorldObject, and that would round off anything that I can think of. They're essential to the game, given that you have to eat dead things.

_________________
Remember our goals: simplicity, science, and playability. Keep them in mind always.
[OE]|[FAQ]|[Wiki]|[My Blog]
Back to top Go down
View user profile
roadkillguy
Experienced


Posts: 534
Reputation: 16
Join date: 2010-08-25
Age: 19
Location: Rhode Island

PostSubject: Re: Class Structure   Mon Jun 25, 2012 5:11 pm

Gawayno wrote:
So this is what the class structure in C++ looks like huh? We would use curly brackets and a specific term, such as string, int, etc in C#.
Thanks for this, I'm starting to understand C++ even more.


No. I used code tags to make sure the indentations were correct. That isn't c++ at all.

Legitimate c++ is this:

Creature.h
Code:
#ifndef CREATURE_H
#define CREATURE_H

class Creature : public Organism
{
    //stuff
  public:

    Creature(const CreatureDef & _def);
};

#endif


Creature.cpp
Code:
#include "Creature.h"

Creature::Creature(const CreatureDef & _def) : m_def(_def)
{
    //other stuff
}


~sciocont wrote:
This seems pretty thorough. What about waste products/carcasses? They could be part of an "Organics" class under WorldObject, and that would round off anything that I can think of. They're essential to the game, given that you have to eat dead things.


A dead animal is still an animal. If it doesn't behave any differently, it has no need to be a different class. (Its compounds will simply deteriorate)
Back to top Go down
View user profile
~sciocont
Overall Team Lead


Posts: 3172
Reputation: 99
Join date: 2010-07-06

PostSubject: Re: Class Structure   Mon Jun 25, 2012 5:31 pm

Ok, makes sense. Still there's waste products. I hate to bring up something that seems to inconsequential, but they do contain important nutrients, which coprophagous animals can benefit from.

_________________
Remember our goals: simplicity, science, and playability. Keep them in mind always.
[OE]|[FAQ]|[Wiki]|[My Blog]
Back to top Go down
View user profile
roadkillguy
Experienced


Posts: 534
Reputation: 16
Join date: 2010-08-25
Age: 19
Location: Rhode Island

PostSubject: Re: Class Structure   Mon Jun 25, 2012 6:29 pm

~sciocont wrote:
Ok, makes sense. Still there's waste products. I hate to bring up something that seems to inconsequential, but they do contain important nutrients, which coprophagous animals can benefit from.


Ahh yes of course. Adding to OP...
Back to top Go down
View user profile
 

Class Structure

View previous topic View next topic Back to top 
Page 1 of 1

 Similar topics

-
» Structure
» Community Structure
» Structure of the MITI
» Ridgerealms coding- Structure Simulator
» GTX WEAPON [ALL CLASS]

Permissions in this forum:You cannot reply to topics in this forum
Thrive Game Development :: Hard Development :: Programming-