FreeOrion

Forums for the FreeOrion project
It is currently Thu May 23, 2013 2:04 am

All times are UTC




Post new topic Reply to topic  [ 39 posts ]  Go to page Previous  1, 2, 3  Next
Author Message
 Post subject: Re: Can a poor environment be terraformed?
PostPosted: Sun Jul 24, 2011 9:34 pm 
Offline
Design & Graphics Lead
User avatar

Joined: Sat Sep 23, 2006 7:09 pm
Posts: 3693
Location: USA — midwest
Geoff the Medio wrote:
Having planet types, planet sizes, and star types defined in a text file instead of hard-coded is possible but would be a big job that I'm not keen on tackling in the short-term. I might get inspired to do it at some point, though.
I know, i just didn't want my previous comments to encourage moving it in the opposite direction.

Geoff the Medio wrote:
eleazar wrote:
So perhaps define EP_STANDARD_TERRAN and so forth for each of the 9 standard EP in a separate file from the species. This would include information on which planets are "poor," "adequate", etc. and also which steps to take to terraform.

The section of the species definition about environmental preferences is quite concise and self-contained; I don't think it's worth the effort to add a separate set of symbols and definitions just for that...

My main concern is that the terraforming buildings definition needs to reference each species by name. If put a layer of abstraction in there, it seems tidy to also include the rest of the EP stuff.

_________________
—• Read this First before posting Game Design Ideas!
—• Design Philosophy

—•— My Ideas, Organized —•— Get an Avatar —•— Acronyms —•—


Top
 Profile  
 
 Post subject: Re: Can a poor environment be terraformed?
PostPosted: Sun Jul 24, 2011 11:18 pm 
Offline
Programming, Design, and De Facto Lead
User avatar

Joined: Wed Oct 08, 2003 1:33 am
Posts: 7891
Location: Vancouver, BC
eleazar wrote:
My main concern is that the terraforming buildings definition needs to reference each species by name.

Avoiding that and making terraforming content more practical was the motivation for my suggestion a few posts ago for an effect (or perhaps a referencable property for use in an effect) to change a planet's type to the next better for its species (or another species that would be determined dynamically - without referencing a particular species by name).


Top
 Profile  
 
 Post subject: Re: Can a poor environment be terraformed?
PostPosted: Mon Jul 25, 2011 7:43 am 
Offline
Space Squid
User avatar

Joined: Wed Jul 20, 2011 12:03 pm
Posts: 85
Geoff the Medio wrote:
eleazar wrote:
My main concern is that the terraforming buildings definition needs to reference each species by name.

Avoiding that and making terraforming content more practical was the motivation for my suggestion a few posts ago for an effect (or perhaps a referencable property for use in an effect) to change a planet's type to the next better for its species (or another species that would be determined dynamically - without referencing a particular species by name).

In my previous post I explained (obviuosly very poorly) how this can be done. I don't know how to write the code, but I know the required algorthim, which I could use to calculate it. Please let me know what is confusing about my post and I will try to explain better. Or if it doesn't work tell me why and I can try to correct it.


Top
 Profile  
 
 Post subject: Re: Can a poor environment be terraformed?
PostPosted: Mon Jul 25, 2011 8:15 am 
Offline
Programming, Design, and De Facto Lead
User avatar

Joined: Wed Oct 08, 2003 1:33 am
Posts: 7891
Location: Vancouver, BC
OllyG wrote:
In my previous post I explained (obviuosly very poorly) how this can be done. I don't know how to write the code, but I know the required algorthim, which I could use to calculate it. Please let me know what is confusing about my post and I will try to explain better. Or if it doesn't work tell me why and I can try to correct it.

Your post was missing an image and hard to read, but is or seemed to be an overly complicated description of a simple calculation that also introduced unnecessary new terminology or possibly required unnecessary changes to how species are defined. It also appears to assume a simple ordering of planets from worst to best, which isn't applicable to the current design and is even less applicable to possible cases like there being more than one best planet type for a species. You also don't give any consideration to how this could be accomplished within the existing effects system with a minimum of code changes and what would be easiest to use for content scripters.

A better method would be to find the best planet type(s) for a species, and find which is the fewest steps from a planet's current type, and then report the next planet type in the direction of the best one. For content scripters, this could probably be set up as a referencable property for planets to be used in the SetPlanetType effect, as in
Code:
SetPlanetType type = Target.NextBestPlanetTypeForSpecies
. A more flexible system would allow the scripter to specify a species for which the next best planet type is being determined, which need not be the species currently on the planet (if there even is a species on the planet).


Top
 Profile  
 
 Post subject: Re: Can a poor environment be terraformed?
PostPosted: Mon Jul 25, 2011 3:17 pm 
Offline
Space Krill

Joined: Sat Jul 23, 2011 8:40 pm
Posts: 2
If we're suggesting a fundamental change to the terraforming system one *possible* solution would be composite planet types i.e.
Have a planet type determined by the percentage of the planet's surface that corresponds to that planet type.

e.g. Under the new system a planet is 30% Tundra, 10% Radiated & 60% Ocean, the displayed planet type would be Ocean but terraforming would increase the % of the planet which corresponds to the occuping species EP, whilst decreasing the other types.

Issues; would the % of enviroment types be visible to players? Before or after Colonisation? It would allow species with more than 1 EP, how would these planets be terraformed

Pros; simplifies terraforming, introduces new game possibilities? Would allow for more linear population increases that jumping from Adequate to Good as % would increase slowly?

Cons; introduces possibility of two or more dominant environments on a single planet (e.g. 50% Desert, 50% Ocean) what would the displayed planet type be? What would the bonuses/penalties be? What if a planet is 50% Good EP, 50% Hostile EP? Complicates planet creation at start-up (although random number generation could be used)?


Top
 Profile  
 
 Post subject: Re: Can a poor environment be terraformed?
PostPosted: Mon Jul 25, 2011 4:06 pm 
Offline
Design & Graphics Lead
User avatar

Joined: Sat Sep 23, 2006 7:09 pm
Posts: 3693
Location: USA — midwest
Academician wrote:
If we're suggesting a fundamental change to the terraforming system one *possible* solution would be composite planet types i.e.
Have a planet type determined by the percentage of the planet's surface that corresponds to that planet type.

I don't think planets are going to fundamentally change. The simplified model of planet types was chosen for the sake of it's simplicity-- over more complicated models, some IIRC similar to what you've suggested.

You've laid out Pros and Cons well, except i don't think it really simplifies terraforming. The Cons are significant, not because they are insurmountable, but any solutions would tend to move FO away from being the kind of game we're trying to make.

What we want here (in my non-authoritative, but informed opinion) is a better way to make terraforming do what it was supposed to do all along.

_________________
—• Read this First before posting Game Design Ideas!
—• Design Philosophy

—•— My Ideas, Organized —•— Get an Avatar —•— Acronyms —•—


Top
 Profile  
 
 Post subject: Re: Can a poor environment be terraformed?
PostPosted: Mon Jul 25, 2011 9:40 pm 
Offline
Designer and Programmer
User avatar

Joined: Tue Aug 14, 2007 6:33 pm
Posts: 1772
Location: Orion
OllyG wrote:
Ok Bigjoe5, should I play Trith and Gyisache when testing the game or is it only terraforming which is affected?

As far as I know, only Terraforming is affected. And as Academician pointed out, it actually only works for Trith, since eleazar also changed the Gyisache EP to Swamp.

eleazar wrote:
I'm not sure exactly what you are asking.
The wheel looks like this:
Attachment:
EP wheel.png
I believe he is referring to the fact that the planet types are numbered from 1-9 (or something like that), with Swamp and Ocean being the "bookends" and asking if what he's described will make Terraforming work for each species. And I think the answer is "probably/I don't remember", although hopefully defining Terraforming in that manner will end up being unnecessary.

_________________
Warning: Antarans in dimensional portal are closer than they appear.


Top
 Profile  
 
 Post subject: Re: Can a poor environment be terraformed?
PostPosted: Tue Jul 26, 2011 8:35 am 
Offline
Programming, Design, and De Facto Lead
User avatar

Joined: Wed Oct 08, 2003 1:33 am
Posts: 7891
Location: Vancouver, BC
I've added an (untested) property to planets for scripting to aide terraforming effects. It's used like this:
Code:
SetPlanetType Target.NextBetterPlanetType

NextBetterPlanetType returns the planet type that is one step towards one of the referenced planet's species' optimal planet types. This always returns a move towards the overall optimum, ignoring any local optimums that might result in moving to a worse planet type before arriving at (one of) the best.


Top
 Profile  
 
 Post subject: Re: Can a poor environment be terraformed?
PostPosted: Thu Aug 25, 2011 2:35 pm 
Offline
Programming, Design, and De Facto Lead
User avatar

Joined: Wed Oct 08, 2003 1:33 am
Posts: 7891
Location: Vancouver, BC
Geoff the Medio wrote:
I've added an (untested) property to planets for scripting to aide terraforming effects. It's used like this:
Code:
SetPlanetType Target.NextBetterPlanetType

NextBetterPlanetType returns the planet type that is one step towards one of the referenced planet's species' optimal planet types. This always returns a move towards the overall optimum, ignoring any local optimums that might result in moving to a worse planet type before arriving at (one of) the best.

It'd be nice if the content files were updated soon to make terraforming work for all species. The property mentioned above should make this possible...


Top
 Profile  
 
 Post subject: Re: Can a poor environment be terraformed?
PostPosted: Fri Aug 26, 2011 7:45 pm 
Offline
Designer and Programmer
User avatar

Joined: Tue Aug 14, 2007 6:33 pm
Posts: 1772
Location: Orion
I tried using this building as the Humans on a Swamp planet:



Code:
BuildingType
    name = "BLD_REMOTE_TERRAFORM"
    description = "BLD_REMOTE_TERRAFORM_DESC"
    buildcost = 1
    buildtime = 1
    location = And [
        OwnedBy TheEmpire Source.Owner
        Not Planet environment = [Uninhabitable Good]
    ]
    effectsgroups = [
        EffectsGroup
            scope = And [
                Contains Source
                Planet
            ]
            effects = SetPlanetType Target.NextBetterPlanetType

        EffectsGroup
            scope = Source
            effects = Destroy
    ]
    graphic = ""


What should have happened was Swamp --> Ocean --> Terran

What actually happened was Swamp --> Toxic --> Inferno --> Radiated --> Inferno

Edit:

I tried again as Egassem (EP Inferno) and got Swamp --> Ocean --> Terran --> Ocean

_________________
Warning: Antarans in dimensional portal are closer than they appear.


Last edited by Bigjoe5 on Fri Aug 26, 2011 7:48 pm, edited 1 time in total.

Top
 Profile  
 
 Post subject: Re: Can a poor environment be terraformed?
PostPosted: Fri Aug 26, 2011 7:47 pm 
Offline
Programming, Design, and De Facto Lead
User avatar

Joined: Wed Oct 08, 2003 1:33 am
Posts: 7891
Location: Vancouver, BC
Bigjoe5 wrote:
What should have happened was Swamp --> Ocean --> Terran

What actually happened was Swamp --> Toxic --> Inferno --> Radiated --> Inferno
So it's doing exactly the opposite of what it claims. Amusing...

Edit: In Species.cpp line 282 change > to < and try again? /Edit


Top
 Profile  
 
 Post subject: Re: Can a poor environment be terraformed?
PostPosted: Fri Aug 26, 2011 8:13 pm 
Offline
Designer and Programmer
User avatar

Joined: Tue Aug 14, 2007 6:33 pm
Posts: 1772
Location: Orion
Geoff the Medio wrote:
Edit: In Species.cpp line 282 change > to < and try again? /Edit

That seems to have fixed the problem. Here are the new Terraforming buildings:

Code:
BuildingType
    name = "BLD_TERRAFORM"
    description = "BLD_TERRAFORM_DESC"
    buildcost = 720
    buildtime = 1
    location = And [
        OwnedBy TheEmpire Source.Owner
        TargetPopulation low = 1 high = 999
        Not Planet environment = [Uninhabitable Good]
        ]
    effectsgroups = [
        EffectsGroup
            scope = And [
                Contains Source
                Planet
            ]
            effects = SetPlanetType Target.NextBetterPlanetType

        EffectsGroup
            scope = Source
            effects = Destroy
    ]
    graphic = ""

BuildingType
    name = "BLD_REMOTE_TERRAFORM"
    description = "BLD_REMOTE_TERRAFORM_DESC"
    buildcost = 60
    buildtime = 16
    location = And [
        OwnedBy TheEmpire Source.Owner
        Not Planet environment = [Uninhabitable Good]
    ]
    effectsgroups = [
        EffectsGroup
            scope = And [
                Contains Source
                Planet
            ]
            effects = SetPlanetType Target.NextBetterPlanetType

        EffectsGroup
            scope = Source
            effects = Destroy
    ]
    graphic = ""

_________________
Warning: Antarans in dimensional portal are closer than they appear.


Top
 Profile  
 
 Post subject: Re: Can a poor environment be terraformed?
PostPosted: Thu Sep 01, 2011 9:34 pm 
Offline
Space Floater

Joined: Mon Apr 25, 2011 6:32 am
Posts: 15
Which files need to be changed ​​to test their effect?


Top
 Profile  
 
 Post subject: Re: Can a poor environment be terraformed?
PostPosted: Thu Sep 01, 2011 9:37 pm 
Offline
Programming, Design, and De Facto Lead
User avatar

Joined: Wed Oct 08, 2003 1:33 am
Posts: 7891
Location: Vancouver, BC
kupferdrache wrote:
Which files need to be changed ​​to test their effect?

None; those changes were added to the SVN version.


Top
 Profile  
 
 Post subject: Re: Can a poor environment be terraformed?
PostPosted: Thu Sep 01, 2011 10:01 pm 
Offline
Space Floater

Joined: Mon Apr 25, 2011 6:32 am
Posts: 15
in svn 4217 the change isn't in or? for me it looks so.


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 39 posts ]  Go to page Previous  1, 2, 3  Next

All times are UTC


Who is online

Users browsing this forum: No registered users and 0 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
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group