Jump to content

Recommended Posts

Hi. I see this commit here, which is a good commit for what the game has now: https://trac.wildfiregames.com/changeset/19673

 

Also, some technical discussion here: https://code.wildfiregames.com/D460

 

I was wondering if it would be better for the civ.json files to call the templates and auras directly and get the information directly from these files, rather than having to manually keep the civ.json files up to date. Maybe what I am suggesting is too difficult for the benefit, but I think it would simplify things a lot and eventually allow for a better presentation in the History section of the game. 

 

So, instead of 

Spoiler

{
	"Name":"Athenians",
	"Code":"athen",
	"Culture":[ "helle" ],
	"Region":[ "medit", "europe", "greece" ],
	
	"Emblem":"session/portraits/emblems/emblem_athenians.png",
	
	"History":"As the cradle of Western civilization and the birthplace of democracy, Athens was famed as a center for the arts, learning and philosophy. The Athenians were also powerful warriors, particularly at sea. At its peak, Athens dominated a large part of the Hellenic world for several decades.",
	"Music":[
			{"File":"Harvest_Festival.ogg", "Type":"peace"},
			{"File":"Forging_a_City-State.ogg", "Type":"peace"},
			{"File":"The_Hellespont.ogg", "Type":"peace"}
		],
	"Factions":
	[
		{
			"Name":"Athenians",
			"Description":"A Hellenic people of the Ionian tribe.",
			"Technologies":
			[
				{
					"Name":"Iphicratean Reforms",
					"History":"",
					"Description":"Athenian triremes can train Marines (Epibates Athenaikos)."
				},
				{
					"Name":"Long Walls",
					"History":"The Long Walls of Athens were constructed under the auspices of the wily Themistocles and extended 6 km from the city to the port of Piraeus. This secured the city's sea supply routes and prevented an enemy from starving out the city during a siege.",
					"Description":"Stone walls can be built in neutral territory. Construction time for walls is reduced by 50%."
				},
				{
					"Name":"Othismos",
					"History":"The classical phalanx formation was developed about VIII century BC. It was eight men deep and up to eight hundred men wide. The men within overlapped their shields, presenting a formidable shield wall brimming with 8 foot spears.",
					"Description":"The player gains the ability to order spear-armed troops into Phalanx formation, providing greater attack and armor."
				}
			],
			"Heroes":
			[
				{
					"Name":"Themistocles",
					"Class":"",
					"Armament":"",
					"Emblem":"",
					"History":"The general whom persuaded the Athenians to invest their income from silver mines in a war navy of 200 Triremes. A key figure during the Persian Wars, he commanded the victorious Athenian navy at the decisive battle of Salamis in 479 B.C. Later, he pursued an active policy against the Persians in the Aegean, thereby laying the foundations of future Athenian power. Ostracised by the Athenians, he was forced to flee to the protection of the Persians."
				},
				{
					"Name":"Pericles",
					"Class":"",
					"Armament":"",
					"Emblem":"",
					"History":"Pericles was the foremost Athenian politician of the 5th Century B.C."
				},
				{
					"Name":"Iphicrates",
					"Class":"",
					"Armament":"",
					"Emblem":"",
					"History":"."
				}
			]
		}
	],
	"CivBonuses":
	[
		{
			"Name":"Silver Owls",
			"History":"The mines at Laureion in Attica provided Athens with a wealth of silver from which to mint her famous and highly prized coin, The Athenian Owl.",
			"Description":"Metal mining gathering rates increased by +10% for each passing age."
		},
		{
			"Name":"Hellenization",
			"History":"The Greeks were highly successful in Hellenising various foreigners. During the Hellenistic Age, Greek was the lingua franca of the Ancient World, spoken widely from Spain to India.",
			"Description":"Constructing a Theatron increases the territory expanse of all buildings by +20%."
		}
	],
	"TeamBonuses":
	[
		{
			"Name":"Delian League",
			"History":"Shortly after the great naval victories at Salamis and Mykale, the Greek city-states instituted the so-called Delian League in 478 B.C., whose purpose was to push the Persians out of the Aegean region. The allied states contributed ships and money, while the Athenians offered their entire navy.",
			"Description":"Ships -25% build time."
		}
	],
	"Structures":
	[
		{
			"Name":"Theatron",
			"Class":"",
			"Emblem":"",
			"History":"Greek theatres were places where the immortal tragedies of Aeschylus, Sophocles and many other talented dramatists were staged to the delight of the populace. They were instrumental in enriching Hellenic culture.",
			"Requirements":"",
			"Phase":"City",
			"Special":"The Hellenization civ bonus. Building a Theatron increases the territory effect of all buildings by 25%."
		},
		{
			"Name":"Gymnasion",
			"Class":"",
			"Emblem":"",
			"History":"The Gymnasion was a vital place in Hellenic cities, where physical exercises were performed and social contacts established.",
			"Requirements":"",
			"Phase":"City",
			"Special":"Train champion units and research technologies pertaining to champion units."
		},
		{
			"Name":"Prytaneion",
			"Class":"",
			"Emblem":"",
			"History":"The Prytaneion is the meeting place for the city elders to dine and to make swift decisions.",
			"Requirements":"",
			"Phase":"City",
			"Special":"Train heroes and research technology pertaining to heroes."
		}
	],
	"StartEntities":
	[
		{
			"Template": "structures/athen_civil_centre"
		},
		{
			"Template": "units/athen_support_female_citizen",
			"Count": 4
		},
		{
			"Template": "units/athen_infantry_spearman_b",
			"Count": 2
		},
		{
			"Template": "units/athen_infantry_slinger_b",
			"Count": 2
		},
		{
			"Template": "units/athen_cavalry_javelinist_b"
		}
	],
	"Formations":
	[
		"formations/null",
		"formations/line_closed",
		"formations/line_open",
		"formations/column_closed",
		"formations/wedge",
		"formations/phalanx"
	],
	"AINames":
	[
		"Cimon",
		"Aristides",
		"Xenophon",
		"Hippias",
		"Cleisthenes",
		"Thucydides",
		"Alcibiades",
		"Miltiades",
		"Cleon",
		"Cleophon",
		"Thrasybulus",
		"Demosthenes"
	],
	"SkirmishReplacements":
	{
		"skirmish/units/default_infantry_ranged_b": "units/athen_infantry_slinger_b",
		"skirmish/structures/default_house_10": "structures/athen_house",
		"skirmish/structures/default_stoa": "structures/athen_stoa"
	},
	"SelectableInGameSetup": true
}

 

 

It could look like:

 

Spoiler

{
	"Name":"Athenians",
	"Code":"athen",
	"Culture":[ "helle" ],
	"Region":[ "medit", "europe", "greece" ],
	
	"Emblem":"session/portraits/emblems/emblem_athenians.png",
	
	"History":"As the cradle of Western civilization and the birthplace of democracy, Athens was famed as a center for the arts, learning and philosophy. The Athenians were also powerful warriors, particularly at sea. At its peak, Athens dominated a large part of the Hellenic world for several decades.",
	"Music":[
			{"File":"Harvest_Festival.ogg", "Type":"peace"},
			{"File":"Forging_a_City-State.ogg", "Type":"peace"},
			{"File":"The_Hellespont.ogg", "Type":"peace"}
		],
	"Factions":
	[
		{
			"Name":"Athenians",
			"Description":"A Hellenic people of the Ionian tribe.",
			"Technologies":
			[
				{
					"Technology":"mercenaries/athen_reforms"
				},
				{
					"Technology":"hellenes/special_long_walls"
				},
				{
					"Technology":"hellenes/special_periclean_strategem"
				}
			],
			"Heroes":
			[
				{
					"Unit":"athen_hero_themistocles"
				},
				{
					"Unit":"athen_hero_pericles"
				},
				{
					"Unit":"athen_hero_iphicrates"
				}
			]
		}
	],
	"CivBonuses":
	[
		{
			"Name":"Silver Owls",
			"History":"The mines at Laureion in Attica provided Athens with a wealth of silver from which to mint her famous and highly prized coin, The Athenian Owl.",
			"Description":"Metal mining gathering rates increased by +10% for each passing age."
		},
		{
			"Aura":"auras/hellenization"
		}
	],
	"TeamBonuses":
	[
		{
			"TeamBonus":"athen_player_team_bonus"
		}
	],
	"Structures":
	[
		{
			"Structure":"athen_theatron"
		},
		{
			"Structure":"athen_gymnasion"
		},
		{
			"Structure":"athen_prytaneion"
		}
	],
	"StartEntities":
	[
		{
			"Template": "structures/athen_civil_centre"
		},
		{
			"Template": "units/athen_support_female_citizen",
			"Count": 4
		},
		{
			"Template": "units/athen_infantry_spearman_b",
			"Count": 2
		},
		{
			"Template": "units/athen_infantry_slinger_b",
			"Count": 2
		},
		{
			"Template": "units/athen_cavalry_javelinist_b"
		}
	],
	"Formations":
	[
		"formations/null",
		"formations/line_closed",
		"formations/line_open",
		"formations/column_closed",
		"formations/wedge",
		"formations/phalanx"
	],
	"AINames":
	[
		"Cimon",
		"Aristides",
		"Xenophon",
		"Hippias",
		"Cleisthenes",
		"Thucydides",
		"Alcibiades",
		"Miltiades",
		"Cleon",
		"Cleophon",
		"Thrasybulus",
		"Demosthenes"
	],
	"SkirmishReplacements":
	{
		"skirmish/units/default_infantry_ranged_b": "units/athen_infantry_slinger_b",
		"skirmish/structures/default_house_10": "structures/athen_house",
		"skirmish/structures/default_stoa": "structures/athen_stoa"
	},
	"SelectableInGameSetup": true
}

 

That's a reduction of 40 lines from just one civ file, or about 25% and looks a lot cleaner. The History section would pull the relevant information directly from the aura, technology, and template files listed. See, I left the Silver Owls bonus written out because it's part of their phase tech, but I could just as easily pull those effects out of the phase tech into a different tech file and call that instead.

Edited by wowgetoffyourcellphone
  • Like 2
Link to comment
Share on other sites

I would say keep this style from @s0600204's old tech tree patch, which was awesome when it worked, btw. It just needs some minor layout rework.

dJ8P1QB.png

As for further mockups, I'd be happy to make some if I was assured they'd be taken seriously. No offense to you personally, but one of the reasons I have not bothered to try to join the team is the general rule of open source development of lots of intensive work going to waste. With modding, I can do exactly what I want to when I want to. Sadly, my programming skills are limited to copying and pasting and editing other people's work, so I can't make cool @#$% like that image happen on my own, only lament the eventual incompatibility of cool patches sitting on Trac. You have been rather active though, so I am cautiously optimistic.

 

Edited by wowgetoffyourcellphone
  • Like 3
Link to comment
Share on other sites

D295 (currently waiting on the review and acceptance of D517 (so as to minimise merge conflicts)), splits the Structure Tree code to make it easier to reuse the more generic parts of the Structure Tree code in other gui pages such as (as mentioned as an example in D295's description) adapting the "Civilisation Info" page to load civ/team bonuses, special technologies, heroes, etc. directly from templates which could thus lead to a purging of unnecessary information from {civ}.json files.

Or, to put it another way, there are already revisions ready to be reviewed on phabricator that lead (in some way) to the proposed outcome, they just need to be reviewed.

Now, admittedly we will very shortly be in feature freeze in preparation for the next alpha release, so merging of D295 will no doubt have to wait until after. But D517, being a bug fix, could make it in, so long as it is reviewed and accepted in time.

@wowgetoffyourcellphone: As D517 was created in response to your remarks here, perhaps you would like to review it? Or at least confirm (on phabricator) that it fixes/remedies your problem?

  • Like 2
Link to comment
Share on other sites

14 hours ago, wowgetoffyourcellphone said:

As for further mockups, I'd be happy to make some if I was assured they'd be taken seriously. No offense to you personally, but one of the reasons I have not bothered to try to join the team is the general rule of open source development of lots of intensive work going to waste. With modding, I can do exactly what I want to when I want to.

That's what is world developers' intent to fix by:

* creating a real world base (living standard) for the active, contributing open source community (distributed food production, free(dom) emergency aid, ...)

* showing that it's easy to switch between code project flavors (e.g. libav vs. ffmpeg, walker vs. roller, 0 A.D. vs. 0 B.C.E., mod public vs. mod public_mod vs. public_mod_mod, ...) fixing such quarrels that you quote (e.g. ffmpeg vs. libav package war of Debian maintainers).

* creating a real world bot net to protect freedom of goodhearted, lovely, freedom peaceful fighters, ... (real world physical, psychological security)

* hardening against crises (emergency trade one good type vs. another good type, maybe independent open source driven virtual currency for far distance trade of perishable goods that can not be sent easily).

- - - - - - - -

Hopefully D517 , then D295 and then your (@wowgetoffyourcellphone) changeset 19673 - related to ticket #3212 (structree equivalent for units) - gets in. Thanks for your work.

  • Like 2
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

×
×
  • Create New...