Complete.Org: Mailing Lists: Archives: freeciv-dev: November 2001:
[Freeciv-Dev] Re: non-smallpox idea
Home

[Freeciv-Dev] Re: non-smallpox idea

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
To: Daniel L Speyer <dspeyer@xxxxxxxxxxx>
Cc: freeciv-dev@xxxxxxxxxxx
Subject: [Freeciv-Dev] Re: non-smallpox idea
From: Josh Cogliati <jjc@xxxxxxxxxxxxxxxxxxxxxxxxx>
Date: Fri, 23 Nov 2001 09:31:36 -0700
Reply-to: freeciv-dev@xxxxxxxxxxx

On Thu, Nov 22, 2001 at 02:52:07PM -0500, Daniel L Speyer wrote:
> Just another thought, ths one probably changes gameplay too much, but what
> gov't has ever realy controlled what was researched?  Maybe you should get
> points toward available technologies from what you have.  For example:
> 
> Roads                 Horseback Riding, The Wheel
> Large Cities  Code of Laws, Monarchy, Republic  //This should anti-pox
>                                                 //nicely
> Barracks      Warrior Code
> Mines         Bronze & Iron Working
> Irrigation    Feudalism, Pottery
> etc.
> 
> Of course, you still would need the pre-requisites, but instead of just
> pushing research and counting turns, your nation would shape what tech you
> got.
Summary:
How about having a knowledge data file as well.  Basically it would be a
count of how much experience you had in a given area.  There would 
be a listing of different knowledge types:
Trade,
Construction,
Navigation,
Metalworking ...
Then the buildings and the units would contribute to it.
For example a Marketplace could contribute two trade points per turn,
and building a trireme would contribute one navigation point.
Also each technology would have knowledge point requirements as well.
So Navigation would require 5 navigation points, Trade might require 6 trade 
points and so on.  

This makes getting technology more realistic since one of the best
ways of getting new technology is using the existing technology and
learning from that.  This also could allow some requirements (or all)
to be elimated in favor of knowledge points.  This forces players 
to use the technology that they have developed or remain stuck in the 
stone age.  This method would allow the fires, candles, lightbulbs 
idea, the fire, water, air ... idea, and the uncontrolled research 
idea to be implemented with rulesets and if the knowledge file is blank 
for the default ruleset it doesn't impact default gameplay.


***What it the data files would look like:
An example knowledge file might look like this:
[knowledge_trade]
name  = _("Trade")

[knowledge_navigation]
name  = _("Navigation")

[knowledge_construction]
name =  _("Construction")

An example buildings file would look something like this:
[building_marketplace]
name            = _("Marketplace")
...
use_knowledge   = {"trade",2,"economics",1}
build_knowledge = {"construction",1}

[building_city_walls]
name            = _("City Walls")
...
use_knowledge   = {}
build_knowledge = {"construction",2}

Units file:
[unit_trireme]
name          = _("Trireme")
...
build_knowledge = {"navigation",1}

And technology file:
[advance_trade]
name     = _("Trade")
req1     = "Currency"
req2     = "Code of Laws"
flags    = ""
knowledge_requirement = {"trade",6}

[advance_navigation]
name     = _("Navigation")
req1     = "Seafaring"
req2     = "Astronomy"
flags    = "Reduce_Trireme_Loss2"
knowledge_requirement = {"navigation",5}

[advance_construction]
name     = _("Construction")
req1     = "Masonry"
req2     = "None"
flags    = "Fortress"
knowledge_requirement = {"construction",8}

[advance_railroad]
name     = _("Railroad")
req1     = "Steam Engine"
req2     = "Bridge Building"
flags    = "Railroad","Trade_Revenue_Reduce"
knowledge_requirement = {"construction",20}

***How to implement:

At start up read in the knowledge.ruleset file and assign a number to 
each knowlegde type.  Read the rest of the ruleset files.

Each turn:
foreach building in game:
   if building.has_use_knowledge:
       foreach use_knowledge in building.use_knowledge
           player.knowledge[use_knowledge.type] += use_knowledge.amount

Each time a building is built:
foreach build_knowlegde in building.build_knowledge:
    player.knowledge[build_knowledge.type] += build_knowledge.amount

Each time a unit is built:
foreach build_knowlegde in unit.build_knowledge:
    player.knowledge[build_knowledge.type] += build_knowledge.amount

When a technology is about to be discovered (or maybe even stolen),
can_get = true
foreach require_knowledge in tech.require_knowledge:
   if player.knowledge[require_knowledge.type] < require_knowledge.amount:
        error need more knowledge in knowledge name
        can_get = false
if can_get = true:
   get technology.

Also the technology dialogs and the science dialog would need this information.
The science dialog should warn if there are any knowledge deficiencies for 
the current reseach request.

The AI would have to know about this (probably the most significant amount 
of code would be here).

***Impact on gameplay.

This would require fairly different gameplay.  As such I think that 
if it was used it should be added as a new ruleset, not as the default 
ruleset.  

***Variation.
For building use have a users catagory, for example:
content citizens, all citizens, scientists ...
and multiply the use_knowledge.amount * the number of users.



-- 
Josh Cogliati
jjc@xxxxxxxxx
This message created in Linux, the choice of a GNU generation.



[Prev in Thread] Current Thread [Next in Thread]