annotate doc/balance.md @ 31:d1ae50439686

Added tag 0.9.2 for changeset a51e44094df2
author ark
date 2026-10-20 17:58 +0200
parents 3f2811aebb3d
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
0
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
1 balance
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
2 -------
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
3
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
4 all game numbers in one place. the values used by the game are in the config
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
5 file (see architecture.md); this document explains them and records where each
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
6 one comes from.
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
7
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
8 source markers:
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
9
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
10 - notes: from the original design notes or the original drawing sheet,
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
11 decided
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
12 - decided: decided after the notes were written
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
13 - guess: a starting value for playtesting, expected to change
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
14 - derived: calculated from other values
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
15
15
c1c7e4f54bf6 balance work prep
ark
parents: 14
diff changeset
16 notes and decided values are not fixed either. they come from the original
c1c7e4f54bf6 balance work prep
ark
parents: 14
diff changeset
17 drawing sheet and the first design rounds, made without experience in game
c1c7e4f54bf6 balance work prep
ark
parents: 14
diff changeset
18 design, and are all open to change in balancing.
c1c7e4f54bf6 balance work prep
ark
parents: 14
diff changeset
19
0
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
20 units: distances are in map pixels, that is pixels of the map image as
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
21 scanned. times are in seconds, speeds in map pixels per second.
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
22
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
23
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
24 scale
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
25 -----
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
26
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
27 | item | value | source |
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
28 |------------------------------|-------|--------|
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
29 | map images | 1.0 | notes |
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
30 | towers, monsters, projectiles | 0.25 | notes ("maps scaled approx 400%") |
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
31 | coins | 0.4 | guess, 0.25 makes them about 10 pixels |
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
32 | hp bars | 0.25 | guess |
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
33
9
53f015966118 map, path, tower placement adjustments
ark
parents: 8
diff changeset
34 measured from the earlier masks, which covered the whole road (approximate,
53f015966118 map, path, tower placement adjustments
ark
parents: 8
diff changeset
35 from red area divided by path width):
0
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
36
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
37 | map | size | path width | path length, all branches |
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
38 |------|---------|------------|---------------------------|
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
39 | map0 | 705x697 | 56 | 1930 |
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
40 | map1 | 663x590 | 48 | 1350 |
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
41 | map2 | 618x537 | 42 | 2075 |
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
42 | map3 | 642x459 | 52 | 905 |
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
43
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
44 a single route on map1 or map2 is shorter than the total. exact route lengths
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
45 come from the build (see architecture.md).
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
46
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
47
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
48 monsters
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
49 --------
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
50
23
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
51 | monster | hp | coins | coins per hp | speed | source |
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
52 |---------|----|-------|--------------|-------|--------|
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
53 | m0 | 5 | 1 | 0.20 | 35 | hp, coins: notes; speed: guess |
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
54 | m1 | 10 | 1 | 0.10 | 40 | hp: notes; coins: decided (was 2); speed: guess |
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
55 | m2 | 15 | 2 | 0.13 | 45 | hp: notes; coins: decided (was 3); speed: guess |
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
56 | m3 | 20 | 2 | 0.10 | 40 | hp: notes; coins: decided (was 4); speed: guess |
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
57 | m4 | 30 | 3 | 0.10 | 35 | hp: notes; coins: decided (was 6); speed: guess |
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
58 | b0 | 150 | 30 | 0.20 | 25 | hp: decided, 5 x the notes; coins: notes; speed: guess |
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
59 | b1 | 250 | 50 | 0.20 | 25 | as above |
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
60 | b2 | 350 | 70 | 0.20 | 25 | as above |
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
61 | b3 | 500 | 100 | 0.20 | 25 | as above |
0
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
62
23
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
63 monster hp is the same on every map (decided). a monster that took two hits
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
64 on one map must not take four on a later one. a map gets harder through the
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
65 size of its waves and the mix of monsters.
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
66
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
67 the notes had every monster drop 0.2 coins per hp. regular monster coins are
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
68 now set apart from hp (decided): m0 keeps 0.2, the others drop 0.10 to 0.13.
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
69 the mix of monsters then sets the coins per hp of a map. the notes gave
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
70 bosses hp equal to their coins; balancing raised it to 5 times that
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
71 (decided).
0
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
72
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
73 time to walk the whole path at 35-45 speed (derived): map0 about 50 s, map3
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
74 about 23 s.
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
75
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
76 animation (all guesses):
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
77
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
78 - one hop takes 0.35 s
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
79 - hop height 5
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
80 - squash on landing 6 % (wider and flatter), stretch in the air 4 %
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
81 - idle bob 2 %
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
82 - each monster starts at a random point in its hop cycle, so a group does not
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
83 hop in step
8
2c4fed8baed9 art update, persistent sound setting, tower selling as double action
ark
parents: 6
diff changeset
84 - the death puff shows for 0.4 s
0
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
85
10
22b604680c5a adjusted monster movement to be less uniform
ark
parents: 9
diff changeset
86 variation between monsters, so a group does not walk in single file (all
22b604680c5a adjusted monster movement to be less uniform
ark
parents: 9
diff changeset
87 guesses):
22b604680c5a adjusted monster movement to be less uniform
ark
parents: 9
diff changeset
88
22b604680c5a adjusted monster movement to be less uniform
ark
parents: 9
diff changeset
89 - each monster's speed differs from its table speed by up to 5 % either way.
22b604680c5a adjusted monster movement to be less uniform
ark
parents: 9
diff changeset
90 faster ones overtake slower ones
22b604680c5a adjusted monster movement to be less uniform
ark
parents: 9
diff changeset
91 - a monster walks beside the centre line of the road, at most 0.45 of the
22b604680c5a adjusted monster movement to be less uniform
ark
parents: 9
diff changeset
92 road half width away from it: 8.6, 7.7, 7.2 and 9.9 pixels by map
22b604680c5a adjusted monster movement to be less uniform
ark
parents: 9
diff changeset
93 - half of that is a fixed lean to one side, chosen at spawn. the other half
22b604680c5a adjusted monster movement to be less uniform
ark
parents: 9
diff changeset
94 wanders, with a new random value every 40 pixels along the route and a
22b604680c5a adjusted monster movement to be less uniform
ark
parents: 9
diff changeset
95 smooth change between them
22b604680c5a adjusted monster movement to be less uniform
ark
parents: 9
diff changeset
96 - the offset grows from 0 over the first 20 pixels of the route
22b604680c5a adjusted monster movement to be less uniform
ark
parents: 9
diff changeset
97 - on the inside of tight bends the offset is reduced, so a monster never moves
22b604680c5a adjusted monster movement to be less uniform
ark
parents: 9
diff changeset
98 backwards. monsters may bunch up there
22b604680c5a adjusted monster movement to be less uniform
ark
parents: 9
diff changeset
99
0
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
100
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
101 route preference
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
102 ----------------
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
103
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
104 on maps with several routes, a monster picks one at spawn. faster monsters
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
105 prefer longer or straighter routes, slower ones prefer shortcuts (decided).
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
106
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
107 proposed rule (guess):
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
108
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
109 - for each route the build calculates its length and how much it turns (sum of
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
110 direction changes along the route)
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
111 - each route gets a value between 0 and 1: the average of its length relative
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
112 to the longest route and its straightness relative to the straightest route
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
113 - each monster gets a speed factor: its speed minus the reference speed,
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
114 divided by the reference speed, limited to -1..1
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
115 - route weight = 1 + bias * speed factor * (2 * route value - 1), at least 0.1
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
116 - a monster at the reference speed sees all routes as equally likely
23
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
117 - a boss always takes the shortest route (decided)
0
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
118
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
119 | parameter | value | source |
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
120 |-----------------|-------|--------|
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
121 | reference speed | 40 | guess |
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
122 | bias | 3 | guess |
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
123
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
124 with the speeds above, m2 is the only regular monster faster than the
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
125 reference, and the effect on it is small. the speeds may need to spread out
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
126 more for the preference to be visible.
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
127
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
128
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
129 towers
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
130 ------
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
131
15
c1c7e4f54bf6 balance work prep
ark
parents: 14
diff changeset
132 towers have 5 levels (decided). the config sets damage, range, slow and cost
c1c7e4f54bf6 balance work prep
ark
parents: 14
diff changeset
133 for level 1 and level 5 only. the build fills in the levels between in equal
c1c7e4f54bf6 balance work prep
ark
parents: 14
diff changeset
134 steps, rounded to whole numbers where both ends are whole.
c1c7e4f54bf6 balance work prep
ark
parents: 14
diff changeset
135
c1c7e4f54bf6 balance work prep
ark
parents: 14
diff changeset
136 the drawing sheet gives five damage values for t0 and t1, and four for t2 and
24
3f2811aebb3d splash screen buttons, help button, info screen
ark
parents: 23
diff changeset
137 t3. level 5 of t3 continues the trend (guess). t2 does no damage (decided);
3f2811aebb3d splash screen buttons, help button, info screen
ark
parents: 23
diff changeset
138 it only slows. the equal steps change
15
c1c7e4f54bf6 balance work prep
ark
parents: 14
diff changeset
139 three values from the sheet: t1 level 2 from 7 to 8, t1 level 4 from 17 to 18,
c1c7e4f54bf6 balance work prep
ark
parents: 14
diff changeset
140 and t3 level 2 from 5 to 4 (decided).
0
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
141
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
142 | tower | damage by level | cost | range by level | attack every | projectile speed | source |
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
143 |-------|------------------|------|---------------------|--------------|------------------|--------|
6
910b26feca76 full game flow
ark
parents: 0
diff changeset
144 | t0 | 5,10,15,20,25 | 5 | 60,63,66,69,72 | 1.5 s | none (melee) | damage, cost: notes; range level 1: decided (was 45); rest: guess |
15
c1c7e4f54bf6 balance work prep
ark
parents: 14
diff changeset
145 | t1 | 3,8,13,18,23 | 10 | 100,104,108,112,116 | 0.7 s | 300 | damage levels 1 and 5, cost: notes; range: guess |
24
3f2811aebb3d splash screen buttons, help button, info screen
ark
parents: 23
diff changeset
146 | t2 | none | 20 | 90,94,98,102,106 | 1.2 s | 220 | damage: decided; cost: notes; rest: guess |
15
c1c7e4f54bf6 balance work prep
ark
parents: 14
diff changeset
147 | t3 | 1,4,7,10,13 | 25 | 220,230,240,250,260 | 1.3 s | 800 | damage level 1: notes; cost: decided (was 40), may go lower; rest: guess |
c1c7e4f54bf6 balance work prep
ark
parents: 14
diff changeset
148
c1c7e4f54bf6 balance work prep
ark
parents: 14
diff changeset
149 the cost column is the build cost, level 1.
0
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
150
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
151 rules:
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
152
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
153 - attack speed stays the same at every level (decided). t0 is slower than the
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
154 others (decided), t1 faster than t2, t2 faster than t3 (notes)
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
155 - range grows about 4 % per level (decided "slightly", amount guessed)
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
156 - t0 damages every monster in range at once, each attack
24
3f2811aebb3d splash screen buttons, help button, info screen
ark
parents: 23
diff changeset
157 - t2 slow: p2 bursts where it lands into a freeze splash of radius 28,
3f2811aebb3d splash screen buttons, help button, info screen
ark
parents: 23
diff changeset
158 about two monsters across (decided, radius guessed). every monster the
3f2811aebb3d splash screen buttons, help button, info screen
ark
parents: 23
diff changeset
159 splash touches moves at 0.60, 0.55, 0.50, 0.45, 0.40 of its speed by
3f2811aebb3d splash screen buttons, help button, info screen
ark
parents: 23
diff changeset
160 level, for 2 s (guess). a new hit restarts the time. slows do not add up;
0
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
161 the strongest one applies
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
162 - p1, p2, p3 home in on their target. if the target dies first, the
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
163 projectile flies on to the last position and disappears (guess)
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
164 - towers aim at the monster furthest along its route (guess)
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
165
15
c1c7e4f54bf6 balance work prep
ark
parents: 14
diff changeset
166 costs: the price of building, or of the upgrade to a level. they started as
c1c7e4f54bf6 balance work prep
ark
parents: 14
diff changeset
167 level n costs base cost x n (decided); the config sets levels 1 and 5:
0
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
168
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
169 | tower | level 1 (build) | level 2 | level 3 | level 4 | level 5 | total |
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
170 |-------|-----------------|---------|---------|---------|---------|-------|
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
171 | t0 | 5 | 10 | 15 | 20 | 25 | 75 |
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
172 | t1 | 10 | 20 | 30 | 40 | 50 | 150 |
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
173 | t2 | 20 | 40 | 60 | 80 | 100 | 300 |
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
174 | t3 | 25 | 50 | 75 | 100 | 125 | 375 |
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
175
6
910b26feca76 full game flow
ark
parents: 0
diff changeset
176 selling refunds half of everything paid for the tower, build and upgrades,
13
8df95050fc8b no more build during pause; tower popup closes on any click outside it
ark
parents: 10
diff changeset
177 rounded down (decided). a tower is sold whole.
0
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
178
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
179 | tower | level 1 | level 2 | level 3 | level 4 | level 5 |
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
180 |-------|---------|---------|---------|---------|---------|
6
910b26feca76 full game flow
ark
parents: 0
diff changeset
181 | t0 | 2 | 7 | 15 | 25 | 37 |
910b26feca76 full game flow
ark
parents: 0
diff changeset
182 | t1 | 5 | 15 | 30 | 50 | 75 |
910b26feca76 full game flow
ark
parents: 0
diff changeset
183 | t2 | 10 | 30 | 60 | 100 | 150 |
910b26feca76 full game flow
ark
parents: 0
diff changeset
184 | t3 | 12 | 37 | 75 | 125 | 187 |
0
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
185
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
186 damage per second against a single target, at the guessed attack times
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
187 (derived):
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
188
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
189 | tower | level 1 | level 2 | level 3 | level 4 | level 5 |
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
190 |-------|---------|---------|---------|---------|---------|
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
191 | t0 | 3.3 | 6.7 | 10.0 | 13.3 | 16.7 |
15
c1c7e4f54bf6 balance work prep
ark
parents: 14
diff changeset
192 | t1 | 4.3 | 11.4 | 18.6 | 25.7 | 32.9 |
c1c7e4f54bf6 balance work prep
ark
parents: 14
diff changeset
193 | t3 | 0.8 | 3.1 | 5.4 | 7.7 | 10.0 |
0
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
194
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
195 t3 is meant to be weaker than the other towers; its range lets it reach more
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
196 targets (decided). to keep the gap moderate, its cost went from 40 to 25 and
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
197 its attack time from 2.0 s to 1.3 s, just slower than t2 as the notes require
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
198 (decided, amount guessed). at level 1 it deals about a fifth of t1's damage per
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
199 second at two and a half times the cost. its range covers more path, roughly
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
200 three times as much on a winding map (estimate).
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
201
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
202
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
203 placement
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
204 ---------
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
205
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
206 | parameter | value | source |
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
207 |--------------------------------------------|-------|--------|
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
208 | tower footprint radius | 16 | guess |
9
53f015966118 map, path, tower placement adjustments
ark
parents: 8
diff changeset
209 | road half width, centre line to road edge | per map: 19, 17, 16, 22 | measured from the earlier masks |
53f015966118 map, path, tower placement adjustments
ark
parents: 8
diff changeset
210 | largest gap between footprint and road edge | 14 | guess |
53f015966118 map, path, tower placement adjustments
ark
parents: 8
diff changeset
211 | space between footprint and spawn point | per map: 50 | decided |
53f015966118 map, path, tower placement adjustments
ark
parents: 8
diff changeset
212 | space between footprint and exit point | per map: 40 | decided |
22
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
213 | smallest distance between tower centres | 40 | decided (was 32, two footprints; towers stood too close together) |
0
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
214 | distance from the map edge | 16 | guess |
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
215 | snap radius, how far a tap may be from a legal position | 48 | guess |
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
216 | placement grid cell | 4 | guess |
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
217
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
218 towers may not be placed on the entrance or exit areas.
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
219
9
53f015966118 map, path, tower placement adjustments
ark
parents: 8
diff changeset
220 the spawn point is where the path leaves the blue entrance area. the space
53f015966118 map, path, tower placement adjustments
ark
parents: 8
diff changeset
221 between it and a tower footprint is one to one and a half times the average
53f015966118 map, path, tower placement adjustments
ark
parents: 8
diff changeset
222 tower size (decided). level 1 towers average about 36 pixels across at sprite
53f015966118 map, path, tower placement adjustments
ark
parents: 8
diff changeset
223 scale 0.25, so the space is 36 to 53 pixels.
53f015966118 map, path, tower placement adjustments
ark
parents: 8
diff changeset
224
53f015966118 map, path, tower placement adjustments
ark
parents: 8
diff changeset
225 the exit point is where the path enters the green exit area. towers keep a
53f015966118 map, path, tower placement adjustments
ark
parents: 8
diff changeset
226 somewhat smaller space from it (decided), so they do not cover the building
53f015966118 map, path, tower placement adjustments
ark
parents: 8
diff changeset
227 drawn at the exit.
53f015966118 map, path, tower placement adjustments
ark
parents: 8
diff changeset
228
0
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
229
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
230 economy
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
231 -------
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
232
23
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
233 | map | starting coins |
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
234 |------|----------------|
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
235 | map0 | 10 |
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
236 | map1 | 20 |
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
237 | map2 | 40 |
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
238 | map3 | 60 |
0
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
239
23
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
240 starting coins are from the notes. the source sheet gives 50 for map3. the
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
241 notes raise it to 60 to make the step from map1 to map3 more even (10, 20,
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
242 40, 60 instead of 10, 20, 40, 50). likely to change after playtesting.
0
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
243
23
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
244 the notes set the coins dropped per map to 10 times the starting coins. this
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
245 is no longer a target (decided): the coins a map pays follow from its waves.
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
246 the build prints, per map, the coins dropped by regular monsters and the
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
247 boss, the total with the starting coins, and the coins per hp of the regular
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
248 monsters.
0
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
249
23
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
250 coins per map from the current wave lists (derived):
0
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
251
23
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
252 | map | regular monsters | boss | dropped in all | with starting coins | regular hp | coins per hp |
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
253 |------|------------------|------|----------------|---------------------|------------|--------------|
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
254 | map0 | 48 | 30 | 78 | 88 | 395 | 0.12 |
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
255 | map1 | 139 | 50 | 189 | 209 | 1145 | 0.12 |
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
256 | map2 | 326 | 70 | 396 | 436 | 2615 | 0.12 |
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
257 | map3 | 157 | 100 | 257 | 317 | 1160 | 0.14 |
0
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
258
23
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
259 early start bonuses come on top.
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
260
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
261 all monster levels appear on all maps (decided).
0
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
262
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
263
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
264 waves
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
265 -----
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
266
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
267 | parameter | value | source |
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
268 |------------------------------------|---------------------|--------|
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
269 | waves per map | 6, 8, 10, 12 | guess |
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
270 | break before the first wave | 40 s | guess |
23
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
271 | break between waves, from the last spawn of a wave | 25 s | guess ("longer", decided) |
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
272 | time between spawns | 1.0, 0.65, 0.65, 0.5 s by map | guess, fitted in the simulation |
0
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
273 | early start bonus, coins per second left | 0.05, 0.1, 0.2, 0.3 by map | guess (starting coins / 200) |
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
274
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
275 the bonus is rounded down. if every break is skipped at once, the bonus adds
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
276 about 6, 17, 45 and 82 coins per map (derived).
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
277
23
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
278 shape of a map's waves (decided): each wave is at least as hard as the one
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
279 before, and the last wave is the largest. the boss comes in the last wave and
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
280 spawns first. early waves are mostly m0 and m1; later waves mix monster
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
281 levels.
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
282
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
283 the wave lists in the config are drafted by tools/balance.py
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
284 (architecture.md) from a few numbers per map, and may be edited by hand
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
285 afterwards:
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
286
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
287 - the number of waves
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
288 - the number of regular monsters in the first and in the last wave. the waves
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
289 between grow in equal steps
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
290 - the share of each monster level in the map's regular monsters, by count
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
291 - the wave in which each monster level first appears
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
292
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
293 each monster level gets a weight per wave that grows by one per wave from its
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
294 first wave. the weights are scaled until the wave sizes and the shares are
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
295 met, then rounded to whole monsters per wave. later waves therefore hold more
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
296 of the levels that came in late. every level keeps at least one monster.
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
297
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
298 the draft numbers are kept in the map's section of the config, next to the
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
299 other map settings. the game does not read them.
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
300
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
301 draft numbers, fitted in the simulation to the targets in balancing
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
302 (guess):
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
303
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
304 | map | waves | regular monsters, first and last wave | share by count, m0-m4 | first wave of m0-m4 |
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
305 |------|-------|-----------------|---------------------|---------------|
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
306 | map0 | 6 | 4, 7 | 36, 25, 18, 12, 9 % | 1, 2, 2, 4, 5 |
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
307 | map1 | 8 | 6, 17 | 36, 25, 18, 12, 9 % | 1, 2, 3, 5, 6 |
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
308 | map2 | 10 | 10, 36 | 39, 26, 17, 11, 7 % | 1, 2, 4, 6, 8 |
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
309 | map3 | 12 | 5, 16 | 52, 26, 13, 6, 3 % | 1, 2, 4, 6, 9 |
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
310
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
311 resulting monster counts (derived):
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
312
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
313 | map | m0 | m1 | m2 | m3 | m4 | regular monsters |
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
314 |------|----|----|----|----|----|------------------|
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
315 | map0 | 12 | 9 | 5 | 4 | 3 | 33 |
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
316 | map1 | 32 | 22 | 17 | 12 | 9 | 92 |
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
317 | map2 | 90 | 59 | 39 | 27 | 15 | 230 |
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
318 | map3 | 65 | 33 | 17 | 8 | 3 | 126 |
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
319
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
320 map3 has fewer and weaker monsters than map2. its 60 starting coins already
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
321 pay for much of what the naive player needs against b3, so the waves before
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
322 may pay only about 130 coins (see balancing).
0
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
323
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
324
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
325 hearts
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
326 ------
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
327
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
328 | parameter | value | source |
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
329 |-------------------------|-------|--------|
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
330 | hearts per map | 10 | decided |
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
331 | heart cost of a monster | 1 | decided |
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
332 | heart cost of a boss | 5 | decided |
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
333
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
334
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
335 coins in flight
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
336 ---------------
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
337
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
338 | parameter | value | source |
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
339 |----------------------------------|-------|--------|
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
340 | flight time to the counter | 0.7 s | guess |
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
341 | most coin sprites for one death | 8 | guess |
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
342
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
343 coins are added to the counter at the moment the monster dies; the flying
23
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
344 coins only show it (guess). the same holds for an early start bonus, whose
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
345 coins fly from the exits. this keeps the counter correct for a player who
0
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
346 builds right after a kill.
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
347
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
348
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
349 controls
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
350 --------
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
351
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
352 | parameter | value | source |
7af9dd4e2595 initial art and design/planning docs
ark
parents:
diff changeset
353 |------------|--------|--------|
8
2c4fed8baed9 art update, persistent sound setting, tower selling as double action
ark
parents: 6
diff changeset
354 | game speeds | 1x, 2x, 4x | decided |
22
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
355
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
356
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
357 balancing
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
358 ---------
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
359
23
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
360 the first values were set without a way to estimate their effect, and the
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
361 game was far too easy. two t1 towers won every map, t2 was never needed, and
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
362 many coins were left over when a map was won. the aim is a game where the
22
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
363 player has to think about where to place towers and which ones to build. a
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
364 player who only buys plain firepower should need nearly every coin a map
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
365 pays in order to win it. coins left over then come from better choices.
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
366
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
367 two scripted players mark the range (decided):
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
368
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
369 - naive: builds t1 only, on placement cells of median coverage, whenever it
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
370 can afford one. it should win with about 5 of its 10 hearts left and with
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
371 next to no coins at the start of the last wave
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
372 - greedy: builds on the best cells, and upgrades when no good cell is left.
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
373 it should win with coins to spare
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
374
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
375 rules for changing values:
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
376
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
377 - shop prices and starting coins stay multiples of 5. round upgrade prices
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
378 are preferred
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
379 - values the player does not see are free: hp, damage, coin drops, speeds,
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
380 attack times
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
381 - shop prices are set first. hp, damage and the wave mix are then fitted to
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
382 them
23
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
383 - the main control is coins per hp, set by the mix of monsters. m0 drops
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
384 0.2 coins per hp, the other regular monsters 0.10 to 0.13. a mix with
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
385 fewer m0 pays less for the same hp
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
386 - monster hp stays the same on every map. wave size and the mix make a map
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
387 harder
22
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
388
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
389 the coins of the last wave, the boss's included, arrive when the map is as
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
390 good as won. leftover coins are therefore measured at the start of the last
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
391 wave. the last wave's coins are left out of the calculation. the boss keeps
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
392 its drop as a visible reward (decided).
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
393
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
394 the calculation goes wave by wave, not per map. at the start of each wave
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
395 the player has the starting coins, the coins dropped in earlier waves and
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
396 any early start bonus. these coins buy a certain amount of firepower. the
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
397 wave sets two demands on it:
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
398
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
399 - throughput: the towers' damage per second has to keep up with the hp
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
400 arriving per second. the time a monster spends in range gives some buffer
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
401 - single target: the toughest monster of the wave, m4 or the boss, has to
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
402 die within its time in range
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
403
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
404 damage is counted in whole shots. t1 at level 1 needs 2 shots for the 5 hp
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
405 of an m0, not five thirds of one.
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
406
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
407 simplifications in tools/balance.py:
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
408
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
409 - a tower attacks from the first monster of a wave reaching it until the
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
410 last has passed. it is idle when no monster is in range. with route
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
411 length c in range and spacing s between monsters, the share of time with
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
412 a monster in range is taken as 1 - e^(-c/s)
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
413 - for the single target demand the monster gets every tower's full
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
414 attention while in range. in the game, faster monsters overtake the
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
415 boss and draw fire away from it
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
416 - the naive player builds at the start of a wave with the coins on hand
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
417 and never starts a wave early. the greedy player always starts early and
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
418 takes the bonus. coins dropped during a wave count from the next wave
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
419 - monsters that leak cost one heart each and drop no coins, so a leaky
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
420 wave leaves less for the next one
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
421 - routes are equally likely; the route preference is left out. the boss
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
422 takes the shortest route
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
423 - towers keep their level 1 range when upgraded
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
424
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
425 the time a monster spends in range comes from coverage: the length of route
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
426 within a tower's range, measured for every legal placement cell from the
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
427 build's route and placement data. the median cell stands for the naive
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
428 player and the best cells for the greedy one. for more than one tower,
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
429 cells are picked one after the other, each counting only route that no
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
430 earlier tower covers. maps with several routes are measured per route.
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
431
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
432 t1 coverage at range 100 and footprint radius 16, in map pixels of route
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
433 within range, the mean over routes on maps with several. top 10 % is the
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
434 coverage the best tenth of the cells reach:
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
435
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
436 | map | routes | legal cells | best | top 10 % | median |
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
437 |------|--------|-------------|------|----------|--------|
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
438 | map0 | 1 | 2893 | 415 | 360 | 228 |
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
439 | map1 | 3 | 2132 | 325 | 232 | 129 |
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
440 | map2 | 6 | 1857 | 276 | 195 | 111 |
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
441 | map3 | 1 | 1369 | 422 | 311 | 174 |
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
442
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
443 route lengths: map0 2068, map1 737 to 1048, map2 722 to 1363, map3 1035.
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
444
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
445 value per coin is damage per second divided by all coins paid for the
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
446 tower. for t1 it falls with level: 0.43, 0.38, 0.31, 0.26 and 0.22. this
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
447 is the intended trade between upgrading and building another tower. t0 at
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
448 level 1 reaches 0.67 against a single target, kills an m0 in one hit and
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
449 damages every monster in range. it may be the better buy for a naive
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
450 player than t1, so the calculation lists value per coin for every tower and
23
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
451 level, area damage included. the simulation measures 1.2 to 1.7 monsters
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
452 hit per t0 attack over whole runs, on median cells as on the best ones.
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
453 at that rate t0 at level 1 gives 0.8 to 1.1 against m0, two to three times
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
454 t1.
22
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
455
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
456 t2 works as a time multiplier. a slow to 0.6 of the speed gives 1.67 times
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
457 the time in range for every tower covering the same stretch. this only
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
458 helps against the single target demand, so t2 needs faster monsters or
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
459 tough monsters spaced apart to pay off. it is tuned after the t1 baseline.
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
460
23
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
461 tools/simulate.js (architecture.md) plays the same two players in the game
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
462 code. with the fitted waves, the two tools agree on the coins on hand at
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
463 each wave. they differ in the coins a wave needs:
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
464
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
465 - the boss needs 5 to 20 % more in the simulation: 49, 143, 338 and 206
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
466 coins for the naive player against 40, 130, 320 and 170 in the
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
467 calculation. faster monsters overtake the boss and draw fire away from it
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
468 - regular waves on map2 need up to 1.5 times as much. towers on median
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
469 cells cover the six routes unevenly, and monsters on a route with little
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
470 cover get through. the mean over routes hides this
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
471 - about a tenth of the shots are lost because the target died before the
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
472 projectile arrived
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
473 - route preference changes nothing: with bias 0 the results are the same,
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
474 since the speeds lie close to the reference speed
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
475 - the players in the simulation also build during a wave, with coins from
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
476 the monsters killed in it
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
477
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
478 tools/balance.py was left as it is. the waves were fitted with the
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
479 simulation.
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
480
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
481 with the fitted waves the naive player loses hearts to regular monsters
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
482 only in the first two or three waves. towers stay and add up. what a wave
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
483 demands, hp arriving per second, follows from the mix and the spawn
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
484 interval; wave size sets how long the wave lasts and what it pays. the boss
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
485 is the one demand that grows faster than the coins. the naive player loses
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
486 its hearts there, 5 at once, in most runs. the target of about 5 hearts
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
487 left is met on average over the seeds: the boss gets through in most runs
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
488 and dies in a few.
2f555a54c332 layout fixes and balancing
ark
parents: 22
diff changeset
489
22
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
490 order of work (decided):
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
491
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
492 1. the calculation, tools/balance.py (architecture.md): value per coin for
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
493 every tower, the wave demands against t1 only
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
494 2. shop prices fixed, then hp, damage and waves fitted to them
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
495 3. t2 after the t1 baseline
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
496 4. a headless simulation of the real game code with the two scripted
ad1b478fc4dc balancing work, docs and scripts
ark
parents: 15
diff changeset
497 players confirms the result