How is this idea?

Post your mods, mod information requests and suggestions here for the new version of the game (democracy 2)
MarkShot
Line Manager
Line Manager
Posts: 35
Joined: Fri May 30, 2008 5:59 pm

How is this idea?

Postby MarkShot » Sun Jun 08, 2008 8:02 pm

I am thinking that everything in Democracy 2 is text based. This makes modding pretty easy. What if you took it up one layer?

Here is the concept:

Have a program, Dem2Gen, which automatically generates a set of files:

* Single Mission file
* Attack files (specific or general)
* Event files (specific or general)
* Dilemma files (specific or general)

Implementation of objectives:

* Besides needing to win the election, you will have various constraints placed upon you. The constraints will be realized by making various policy changes so prohibitively expansive in term of political capital that it is infeasible to use them as solutions. This will represent party or positional inertia.

* Winning the election as always built into the game.

* Scenario objectives. You will have to resolve various situations to Win. For example, if the budget fails to get balance it will hurt you so much in the vote demographics that you cannot possible win. So, you will be forced to resolve some particular problems in the game.

Dem2Gen would have basically three inputs to function:

(1) Scenario templates. So, a template could represent various types of countries or situations: "Country afloat in oil wealth", "Country under crushing debt", "Country in the midst of social turmoil" ...

(2) Difficulty slider. Determines just how hard created scenarios are.

(3) Random generator.

The idea behind Dem2Gen is that you already have a game that has a certain amount a variability. However, the variability itself is not random to the point that things play out differently each time. Dem2Gen would provide that variability by wrapping the game engine with yet a higher level. Besides variability, you would get unexpected countries, situations, and goals upon each execution. So, every playing would be a new political world to analyze and formulate a strategy for. Hopefully, it would keep the game from becoming stale after a time.

Well, I don't intend to write it. But I think that it would not be the hardest thing to write and it would add a lot to the game. So, I am throwing the idea out.

---

Here is random game generator I wrote for 1830 (railroads and stock trading). Small changes in the rules/configuration for 1830 can have a very major impact strategy and game play. By writing an external generator, I make a game engine that had a lot of replay value effectively provide a new focus and style of play upon each game. The script besides randomly picking configuration options allow weighting of various choices. See below (written in WinBatch, a Window's scripting tool):

; Random game rule configurator for 1830
;
; Mark Kratzer on 09/07/07; revised 04/09/08

; ----- Definitions ------

GameConfigFile="D:\User\MK\Software\Games\1830\Utility\RandomGame.txt"
ConfigTag="*Undefined*"
ConfigValues="*Undefined"
ConfigProbabilities="*Undefined*"
ConfigValueDefault="*Undefined*"
ConfigSelectEnabled=@False
ConfigDelimiter="|"
NoteProgram="C:\Program Files\WinEdit\Winedit.exe"

; ----- Initialize ------

If FileExist(GameConfigFile) then FileDelete(GameConfigFile)
GameConfigFileHandle=FileOpen(GameConfigFile, "write")
FileWrite(GameConfigFileHandle, "===========================================================================")
FileWrite(GameConfigFileHandle, StrCat(" ",Timedate(),": 1830 Random Rule Configuration"))
FileWrite(GameConfigFileHandle, "===========================================================================")
FileWrite(GameConfigFileHandle, "")

; ----- Generate -----

ConfigTag="Players"
ConfigSelectEnabled=@True
ConfigValueDefault="Four"
ConfigValues="Three|Four|Five|Six"
ConfigProbabilities="25|25|25|25"
ConfigComment=""
GoSub SelectRule

ConfigTag="Difficulty"
ConfigSelectEnabled=@True
ConfigValueDefault="Hardest"
ConfigValues="Easy|Average|Hard|Hardest"
ConfigProbabilities="00|00|70|30"
ConfigComment=""
GoSub SelectRule

ConfigTag="Random Map"
ConfigSelectEnabled=@False
ConfigValueDefault="No"
ConfigValues="No|Yes"
ConfigProbabilities="50|50"
ConfigComment=""
GoSub SelectRule

ConfigTag="Random Revenues"
ConfigSelectEnabled=@False
ConfigValueDefault="No"
ConfigValues="No|Yes"
ConfigProbabilities="90|10"
ConfigComment=""
GoSub SelectRule

ConfigTag="Split Revenues"
ConfigSelectEnabled=@False
ConfigValueDefault="No"
ConfigValues="No|Yes"
ConfigProbabilities="90|10"
ConfigComment=""
GoSub SelectRule

ConfigTag="Reading RR"
ConfigSelectEnabled=@True
ConfigValueDefault="No"
ConfigValues="No|Yes"
ConfigProbabilities="80|20"
ConfigComment="Yes - Third 6-train recommended."
GoSub SelectRule

ConfigTag="No Diesels"
ConfigSelectEnabled=@True
ConfigValueDefault="No"
ConfigValues="No|Yes"
ConfigProbabilities="80|20"
ConfigComment="Yes - Third 6-train recommended."
GoSub SelectRule

ConfigTag="Game Length"
ConfigSelectEnabled=@True
ConfigValueDefault="Normal"
ConfigValues="Normal|Short|Extended"
ConfigProbabilities="80|10|10"
ConfigComment="Short - No Diesels recommended."
GoSub SelectRule

ConfigTag="Unlimited Tiles"
ConfigSelectEnabled=@False
ConfigValueDefault="Yes"
ConfigValues="No|Yes"
ConfigProbabilities="50|50"
ConfigComment=""
GoSub SelectRule

ConfigTag="Optional 6 Train"
ConfigSelectEnabled=@True
ConfigValueDefault="No"
ConfigValues="No|Yes"
ConfigProbabilities="80|20"
ConfigComment=""
GoSub SelectRule

ConfigTag="Delayed Obsolescence"
ConfigSelectEnabled=@False
ConfigValueDefault="No"
ConfigValues="No|Yes"
ConfigProbabilities="50|50"
ConfigComment=""
GoSub SelectRule

ConfigTag="Additional Tiles"
ConfigSelectEnabled=@False
ConfigValueDefault="No"
ConfigValues="No|Yes"
ConfigProbabilities="50|50"
ConfigComment=""
GoSub SelectRule

ConfigTag="Delayed Comp Sales"
ConfigSelectEnabled=@False
ConfigValueDefault="No"
ConfigValues="No|Yes"
ConfigProbabilities="50|50"
ConfigComment=""
GoSub SelectRule

FileClose(GameConfigFileHandle)
RunShell(NoteProgram, GameConfigFile, ".", @ZOOMED, @NOWAIT)
Exit

; ----- Subroutines -----

:SelectRule

RuleLine=""

If ConfigSelectEnabled Then
RuleSelect="enabled"
Else
RuleSelect="disabled"
End If

If !ConfigSelectEnabled Then
RuleLine=StrCat(ConfigTag, " (", RuleSelect, ") = ", ConfigValueDefault)
Else
Selector=Random(99)+1
OptionCount=ItemCount(ConfigProbabilities,"|")
Probability=0
For I=1 to OptionCount by 1
ProbabilityValue=ItemExtract(I, ConfigProbabilities, "|")
Probability=Probability+ProbabilityValue
If Selector <= Probability Then
ConfigValue=ItemExtract(I, ConfigValues, "|")
If ConfigComment=="" Then
RuleLine=StrCat(ConfigTag, " (", RuleSelect, ") = ", ConfigValue, " (", ProbabilityValue, ")")
Else
RuleLine=StrCat(ConfigTag, " (", RuleSelect, ") = ", ConfigValue, " (", ProbabilityValue, ") {",ConfigComment,"}")
End If
Break
End If
Next
End If

FileWrite(GameConfigFileHandle, RuleLine)
FileWrite(GameConfigFileHandle, "")

Return


Sample output:

===========================================================================
Mon 5/26/2008 3:17:54 AM: 1830 Random Rule Configuration
===========================================================================

Players (enabled) = Four (25)

Difficulty (enabled) = Hard (70)

Random Map (disabled) = No

Random Revenues (disabled) = No

Split Revenues (disabled) = No

Reading RR (enabled) = Yes (20) {Yes - Third 6-train recommended.}

No Diesels (enabled) = No (80) {Yes - Third 6-train recommended.}

Game Length (enabled) = Normal (80) {Short - No Diesels recommended.}

Unlimited Tiles (disabled) = Yes

Optional 6 Train (enabled) = No (80)

Delayed Obsolescence (disabled) = No

Additional Tiles (disabled) = No

Delayed Comp Sales (disabled) = No
TomPhil
Supreme Robot
Supreme Robot
Posts: 323
Joined: Tue Jan 23, 2007 12:48 pm
Location: Stockport, UK

Re: How is this idea?

Postby TomPhil » Sun Jun 08, 2008 11:42 pm

I think I get you as far as the random scenario generator is concerned. I have been thinking about a number of programming possibilities similar to this, and I agree that it should not be that hard to do. The main problem I suppose would be that you would have to run the generator a number of times for each template, generate quite a number of scenarios, then test them all, which would be very time consuming.

I sort of get you on the objectives, although I think this may be harder to do than you imagine. For example, if you set the objective to be to eliminate poverty, I'm not sure how you could program this into the game using events and dilemmas.

I don't understand what an "attack file" is.

Actually, it would be quite an interesting feature to be added to Democracy to be able to create scenarios with objectives. I have thought this in the past - it would give the game another very interesting dimension. I've thought this before - often you buy games and there are two modes to play - one is where you have missions with specific objectives and the game is won when you achieve them, and the other is a "sandbox" or "custom" mode where you can simply play without any set objectives for as long as you like. Often I find the latter of these modes is fine for a time, but then you get bored because there is nothing specific to achieve. I would love to see an option in Democracy to create scenarios with set options (such as "eliminate carbon emissions" or "get 75% of the vote in an election), perhaps also with time limits. This would really add something to the game - you would be able to play until you won or lost, rather than just indefinately until you got bored.
MarkShot
Line Manager
Line Manager
Posts: 35
Joined: Fri May 30, 2008 5:59 pm

Re: How is this idea?

Postby MarkShot » Mon Jun 09, 2008 12:17 am

How to create objectives in the game (as it currently is)? I would imagine that you create triggering conditions when a specific is resolved that pushes your approval rating up quite a bit. The scenario would be architected such that without solving the primary objective situations, your chances for election would be nil.

What might be nice is an event/trigger editor for this game with different time frames, dependencies, and absolute/relative time options. Have you ever seen RT3 (Railroad Tycoon 3) from PopTop? It has a very nice scenario editor. The game itself is weak on AI and for some other reasons, but the editor design is top notch.

Of course, for Cliff to make a Dem3 and address replayability by either including a sophisticated scenario editor or random/dynamic scenario generator, he would have to weight out what would yield the best ROI. I would say unless he is guaranteed a large customer base (making scenarios), then he is better off with the generator idea. The generator would have value and be a selling feature on Day #1 when Dem3 is launched. The editor if it pans out might still take a year before its impact is felt.
TomPhil
Supreme Robot
Supreme Robot
Posts: 323
Joined: Tue Jan 23, 2007 12:48 pm
Location: Stockport, UK

Re: How is this idea?

Postby TomPhil » Mon Jun 09, 2008 10:37 am

I see what you mean but I think that it would be very difficult to implement at current, especially as there is no real way to make events only come up after a certain amount of time and there is always a somewhat random element to them. You would be limited to the objectives being achieved in one term, as if you made the game unwinnable without objectives being achieved, you would get chucked out at the next election if you failed to meet them. To try to set precise objectives that you won if you achieved and lost if you did not achieve woul I think be impossible given the current set-up, unfortunately.

However, I do think that it would be a good idea for either a new version of Democracy 2 or Democracy 3 to add the possibility of setting objectives. They could be added to the mission file something like this:

[objectives]
ForeignRelations => 0.75
Patriot => 0.8

When you went to pick a scenario, there would be a separate list for scenarios that had objectives as opposed to those which did not. You would be able to see the objectives before you started playing, and there would be a button in the game to call up the objectives and see how close you were to achieving them. On achieving the objectives, you would be rewarded with fireworks and a congratulations screen. Thinking about it now, I think that this would solve the problem a number of people have regarding long-term playability with the game. In many other games, you have a set of missions or scenarios with objectives that form the core of the game, and then the sandbox mode where you play without objectives is secondary. Often I find when playing these games that I am more attracted to the scenarios with objectives, as there is something to achieve, something to aim for. You get that sense of achievement when you meet the goals, and then you move on to the next one. The problem with playing without objectives is that you just carry on playing until you get bored, which isn't a very positive way to play. I suggested the adding of term limits which to some extent addressed this, but still it would be more positive to actually have something specific to aim towards.
User avatar
jeffryfisher
Type III Robot
Type III Robot
Posts: 72
Joined: Wed Nov 07, 2012 11:58 pm

Re: Scenario objectives

Postby jeffryfisher » Sun Nov 18, 2012 6:00 pm

Sounds like you want some "countries" (scenarios) to start with a couple of manifesto promises in place. That should be dirt-easy to script. What the patch would need is:

a) A new mission-file section tag such as [manifesto] and a grammar for defining promises.

b) A mechanism to alert the player at the beginning that they're there, maybe adding a few lines to the box that tells us what situations we have to start with.

Return to “Modding (democracy 2)”

Who is online

Users browsing this forum: No registered users and 1 guest