Debian Codegraph @

res/editor_examples/repeating_requests_examples.xml

raw
1 <?xml version="1.0"?>
2 <!DOCTYPE events>
3 <!-- This example document shows how you might use events to create a map where you have to use repeating requests to obtain Caesar's favour.
4 What this aims to do is make Caesar lose favour more quickly when favour is high, but then the player repeating requests that can be rapidly
5 fulfilled to build up favour.
6 Though the player first have to build up a city that can produce enough to fulfill those requests that rapidly.
7
8 For the purpose of this example, we will assume we have 5 requests setup.
9 The first request, set to start at +2 years:
10 16 wheat, 1 year deadline, 6 months extension, +2 favour on fulfilled, -1 favour on extension, -10 favour on ignored.
11 The second request, set to start at +10 years:
12 32 wheat, 3 year deadline, 12 months extension, +2 favour on fulfilled, -1 favour on extension, -20 favour on ignored.
13 The third request, set to start at +12 years:
14 8 wine, 3 year deadline, 12 months extension, +2 favour on fulfilled, -1 favour on extension, -5 favour on ignored.
15 The fourth request, set to start at +12 years:
16 16 oil, 4 year deadline, 12 months extension, +4 favour on fulfilled, -2 favour on extension, -10 favour on ignored.
17 The fifth request, set to start at +12 years:
18 16 weapons, 4 year deadline, 12 months extension, +8 favour on fulfilled, -2 favour on extension, -10 favour on ignored.
19
20 What we want, is for the first request to repeat once every 2 years, but only until 10 years in.
21 After that we want the new request to be the one that repeats, and since it will be the main way to get favour with Caesar, repeat as often as possible.
22 That way, if the player wants to get high favour, they will have to ship loads of wheat, as you only get 1 favour per request.
23 However, since it has a long deadline, the player can ignore it for a while if they don't want to worry about favour at that moment. -->
24 <events version="1">
25 <!-- First request (id = 0) -->
26 <event repeat_months_min="12" repeat_months_max="12"> <!-- At most once per year -->
27 <conditions>
28 <time check="gte" amount="24"/> <!-- 2 years -->
29 <time check="lte" amount="120"/> <!-- 10 years -->
30 <request_is_ongoing request_id="0" check_for_ongoing="false"/> <!-- Only start this if it isn't currently ongoing -->
31 </conditions>
32 <actions>
33 <request_immediately_start request_id="0"/>
34 </actions>
35 </event>
36 <!-- Second request (id = 1) -->
37 <event repeat_months_min="1" repeat_months_max="1"> <!-- Immediately repeated upon completion / ignored -->
38 <conditions>
39 <time check="gte" amount="120"/> <!-- 10 years -->
40 <request_is_ongoing request_id="1" check_for_ongoing="false"/>
41 </conditions>
42 <actions>
43 <request_immediately_start request_id="1"/>
44 </actions>
45 </event>
46 <!-- Third request (id = 2) -->
47 <event repeat_months_min="1" repeat_months_max="1"> <!-- Immediately repeated upon completion / ignored -->
48 <conditions>
49 <time check="gte" amount="144"/> <!-- 12 years -->
50 <request_is_ongoing request_id="2" check_for_ongoing="false"/>
51 </conditions>
52 <actions>
53 <request_immediately_start request_id="2"/>
54 </actions>
55 </event>
56 <!-- Fourth request (id = 3) -->
57 <event repeat_months_min="8" repeat_months_max="12"> <!-- Random, roughly 10 months -->
58 <conditions>
59 <time check="gte" amount="144"/>
60 <request_is_ongoing request_id="3" check_for_ongoing="false"/>
61 </conditions>
62 <actions>
63 <request_immediately_start request_id="3"/>
64 </actions>
65 </event>
66 <!-- Fifth request (id = 4) -->
67 <event repeat_months_min="8" repeat_months_max="12"> <!-- Random, roughly 10 months -->
68 <conditions>
69 <time check="gte" amount="144"/>
70 <request_is_ongoing request_id="4" check_for_ongoing="false"/>
71 </conditions>
72 <actions>
73 <request_immediately_start request_id="4"/>
74 </actions>
75 </event>
76 <!-- Make it harder to keep Caesar's favour high (basically we counter gifts, of which a lavish gift can grant 10 favour per year without penalty).
77 This way the player has to make use of the repeatng requests to get to the target of 95 favour.
78 If fact, since the player will lose 1 favour per month, they will have to be constantly fulfilling multiple repeating requests to
79 get to the target favor -->
80 <event repeat_months_min="1" repeat_months_max="1"> <!-- Every month... -->
81 <conditions>
82 <stats_favor check="gte" value="40"/> <!-- when Caesar's favour is above 40, then... -->
83 </conditions>
84 <actions>
85 <favor_add amount="-1"/> <!-- drop Caesar's favor by 1. -->
86 </actions>
87 </event>
88 </events>