Merge lp:~widelands-dev/widelands/terrain_affinity into lp:widelands
- terrain_affinity
- Merge into trunk
Status: | Merged | ||||
---|---|---|---|---|---|
Merged at revision: | 7058 | ||||
Proposed branch: | lp:~widelands-dev/widelands/terrain_affinity | ||||
Merge into: | lp:widelands | ||||
Diff against target: |
6867 lines (+3007/-2410) 128 files modified
CMakeLists.txt (+4/-3) src/logic/CMakeLists.txt (+2/-0) src/logic/description_maintainer.h (+9/-0) src/logic/game.cc (+5/-0) src/logic/game.h (+3/-0) src/logic/immovable.cc (+51/-36) src/logic/immovable.h (+12/-5) src/logic/terrain_affinity.cc (+129/-0) src/logic/terrain_affinity.h (+73/-0) src/logic/worker.cc (+66/-61) src/logic/world/editor_category.cc (+5/-0) src/logic/world/terrain_description.cc (+27/-3) src/logic/world/terrain_description.h (+13/-0) tribes/atlanteans/forester/conf (+1/-1) tribes/barbarians/ranger/conf (+1/-1) tribes/empire/forester/conf (+1/-1) world/immovables/trees/alder/init.lua (+115/-0) world/immovables/trees/alder_summer_mature/init.lua (+0/-23) world/immovables/trees/alder_summer_old/init.lua (+0/-30) world/immovables/trees/alder_summer_pole/init.lua (+0/-23) world/immovables/trees/alder_summer_sapling/init.lua (+0/-23) world/immovables/trees/aspen/init.lua (+116/-0) world/immovables/trees/aspen_summer_mature/init.lua (+0/-26) world/immovables/trees/aspen_summer_old/init.lua (+0/-36) world/immovables/trees/aspen_summer_pole/init.lua (+0/-23) world/immovables/trees/aspen_summer_sapling/init.lua (+0/-23) world/immovables/trees/beech/init.lua (+107/-0) world/immovables/trees/beech_summer_mature/init.lua (+0/-23) world/immovables/trees/beech_summer_old/init.lua (+0/-30) world/immovables/trees/beech_summer_pole/init.lua (+0/-23) world/immovables/trees/beech_summer_sapling/init.lua (+0/-23) world/immovables/trees/birch/init.lua (+110/-0) world/immovables/trees/birch_summer_mature/init.lua (+0/-26) world/immovables/trees/birch_summer_old/init.lua (+0/-30) world/immovables/trees/birch_summer_pole/init.lua (+0/-23) world/immovables/trees/birch_summer_sapling/init.lua (+0/-23) world/immovables/trees/cirrus/init.lua (+103/-0) world/immovables/trees/cirrus_wasteland_mature/init.lua (+0/-23) world/immovables/trees/cirrus_wasteland_old/init.lua (+0/-26) world/immovables/trees/cirrus_wasteland_pole/init.lua (+0/-23) world/immovables/trees/cirrus_wasteland_sapling/init.lua (+0/-23) world/immovables/trees/larch/init.lua (+107/-0) world/immovables/trees/larch_summer_mature/init.lua (+0/-23) world/immovables/trees/larch_summer_old/init.lua (+0/-30) world/immovables/trees/larch_summer_pole/init.lua (+0/-23) world/immovables/trees/larch_summer_sapling/init.lua (+0/-23) world/immovables/trees/liana/init.lua (+106/-0) world/immovables/trees/liana_wasteland_mature/init.lua (+0/-26) world/immovables/trees/liana_wasteland_old/init.lua (+0/-26) world/immovables/trees/liana_wasteland_pole/init.lua (+0/-23) world/immovables/trees/liana_wasteland_sapling/init.lua (+0/-23) world/immovables/trees/maple/init.lua (+107/-0) world/immovables/trees/maple_winter_mature/init.lua (+0/-23) world/immovables/trees/maple_winter_old/init.lua (+0/-30) world/immovables/trees/maple_winter_pole/init.lua (+0/-23) world/immovables/trees/maple_winter_sapling/init.lua (+0/-23) world/immovables/trees/mushroom_dark/init.lua (+103/-0) world/immovables/trees/mushroom_dark_wasteland_mature/init.lua (+0/-23) world/immovables/trees/mushroom_dark_wasteland_old/init.lua (+0/-26) world/immovables/trees/mushroom_dark_wasteland_pole/init.lua (+0/-23) world/immovables/trees/mushroom_dark_wasteland_sapling/init.lua (+0/-23) world/immovables/trees/mushroom_green/init.lua (+103/-0) world/immovables/trees/mushroom_green_wasteland_mature/init.lua (+0/-23) world/immovables/trees/mushroom_green_wasteland_old/init.lua (+0/-26) world/immovables/trees/mushroom_green_wasteland_pole/init.lua (+0/-23) world/immovables/trees/mushroom_green_wasteland_sapling/init.lua (+0/-23) world/immovables/trees/mushroom_red/init.lua (+106/-0) world/immovables/trees/mushroom_red_wasteland_mature/init.lua (+0/-26) world/immovables/trees/mushroom_red_wasteland_old/init.lua (+0/-26) world/immovables/trees/mushroom_red_wasteland_pole/init.lua (+0/-23) world/immovables/trees/mushroom_red_wasteland_sapling/init.lua (+0/-23) world/immovables/trees/oak/init.lua (+113/-0) world/immovables/trees/oak_summer_mature/init.lua (+0/-23) world/immovables/trees/oak_summer_old/init.lua (+0/-36) world/immovables/trees/oak_summer_pole/init.lua (+0/-23) world/immovables/trees/oak_summer_sapling/init.lua (+0/-23) world/immovables/trees/palm_borassus/init.lua (+107/-0) world/immovables/trees/palm_borassus_desert_mature/init.lua (+0/-23) world/immovables/trees/palm_borassus_desert_old/init.lua (+0/-30) world/immovables/trees/palm_borassus_desert_pole/init.lua (+0/-23) world/immovables/trees/palm_borassus_desert_sapling/init.lua (+0/-23) world/immovables/trees/palm_coconut/init.lua (+107/-0) world/immovables/trees/palm_coconut_desert_mature/init.lua (+0/-23) world/immovables/trees/palm_coconut_desert_old/init.lua (+0/-30) world/immovables/trees/palm_coconut_desert_pole/init.lua (+0/-23) world/immovables/trees/palm_coconut_desert_sapling/init.lua (+0/-23) world/immovables/trees/palm_date/init.lua (+110/-0) world/immovables/trees/palm_date_desert_mature/init.lua (+0/-26) world/immovables/trees/palm_date_desert_old/init.lua (+0/-30) world/immovables/trees/palm_date_desert_pole/init.lua (+0/-23) world/immovables/trees/palm_date_desert_sapling/init.lua (+0/-23) world/immovables/trees/palm_oil/init.lua (+111/-0) world/immovables/trees/palm_oil_desert_mature/init.lua (+0/-27) world/immovables/trees/palm_oil_desert_old/init.lua (+0/-30) world/immovables/trees/palm_oil_desert_pole/init.lua (+0/-23) world/immovables/trees/palm_oil_desert_sapling/init.lua (+0/-23) world/immovables/trees/palm_roystonea/init.lua (+107/-0) world/immovables/trees/palm_roystonea_desert_mature/init.lua (+0/-23) world/immovables/trees/palm_roystonea_desert_old/init.lua (+0/-30) world/immovables/trees/palm_roystonea_desert_pole/init.lua (+0/-23) world/immovables/trees/palm_roystonea_desert_sapling/init.lua (+0/-23) world/immovables/trees/rowan/init.lua (+110/-0) world/immovables/trees/rowan_summer_mature/init.lua (+0/-26) world/immovables/trees/rowan_summer_old/init.lua (+0/-30) world/immovables/trees/rowan_summer_pole/init.lua (+0/-23) world/immovables/trees/rowan_summer_sapling/init.lua (+0/-23) world/immovables/trees/spruce/init.lua (+107/-0) world/immovables/trees/spruce_summer_mature/init.lua (+0/-23) world/immovables/trees/spruce_summer_old/init.lua (+0/-30) world/immovables/trees/spruce_summer_pole/init.lua (+0/-23) world/immovables/trees/spruce_summer_sapling/init.lua (+0/-23) world/immovables/trees/twine/init.lua (+103/-0) world/immovables/trees/twine_wasteland_mature/init.lua (+0/-23) world/immovables/trees/twine_wasteland_old/init.lua (+0/-26) world/immovables/trees/twine_wasteland_pole/init.lua (+0/-23) world/immovables/trees/twine_wasteland_sapling/init.lua (+0/-23) world/immovables/trees/umbrella_green/init.lua (+103/-0) world/immovables/trees/umbrella_green_wasteland_mature/init.lua (+0/-23) world/immovables/trees/umbrella_green_wasteland_old/init.lua (+0/-26) world/immovables/trees/umbrella_green_wasteland_pole/init.lua (+0/-23) world/immovables/trees/umbrella_green_wasteland_sapling/init.lua (+0/-23) world/immovables/trees/umbrella_red/init.lua (+106/-0) world/immovables/trees/umbrella_red_wasteland_mature/init.lua (+0/-26) world/immovables/trees/umbrella_red_wasteland_old/init.lua (+0/-26) world/immovables/trees/umbrella_red_wasteland_pole/init.lua (+0/-23) world/immovables/trees/umbrella_red_wasteland_sapling/init.lua (+0/-23) world/init.lua (+26/-116) world/terrains/init.lua (+212/-0) |
||||
To merge this branch: | bzr merge lp:~widelands-dev/widelands/terrain_affinity | ||||
Related bugs: |
|
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Tino | Approve | ||
Review via email: mp+224045@code.launchpad.net |
Commit message
Description of the change
Suggested commit message:
Bring back terrain affinity for trees (only) by implementing a model as developed in bug 1328635. Each terrain type gains 3 properties (humidity, temperature, fertility) and each immovable that can "grow" must define its preferred values for these as well as a pickiness value (between 0 (not picky) and 1 (very picky)) that describes how it copes in non ideal situations.
This also changes plant to always plant one of the 6 best matching immovables for the chosen field.
<<<
The core of the work for this branch is not yet done though: defining the model parameter for each terrain and tree. I need help figuring out the values (3 for each soil and 4 for each tree). I added NOCOMM() in each place where change needs to be done. I would be thankful if somebody could take that off of me and figure out suitable values that fit the engine, makes all worlds (the old winter, green, black and desert maps) playable and looks nice. I'd rather continue fixing bugs and review the many open pull requests. Volunteers?
SirVer (sirver) wrote : | # |
Tino (tino79) wrote : | # |
Ok, i've put Albert's values into the branch.
Not sure if we should test these first or merge the branch and tweak later...
SirVer (sirver) wrote : | # |
Thanks tino!
I went ahead and merged this now as it seems nobody wanted to review the code.
Preview Diff
1 | === modified file 'CMakeLists.txt' |
2 | --- CMakeLists.txt 2014-07-01 17:49:06 +0000 |
3 | +++ CMakeLists.txt 2014-07-06 08:25:52 +0000 |
4 | @@ -122,7 +122,9 @@ |
5 | add_flag(WL_COMPILE_DIAGNOSTICS "-Wno-switch-enum") |
6 | add_flag(WL_COMPILE_DIAGNOSTICS "-Wno-missing-noreturn") |
7 | add_flag(WL_COMPILE_DIAGNOSTICS "-Wno-implicit-fallthrough") |
8 | - add_flag(WL_COMPILE_DIAGNOSTICS "-Qunused-arguments") |
9 | + |
10 | + # TODO(sirver): weak-vtables should be enabled, but leads to lot of errors right now. |
11 | + add_flag(WL_COMPILE_DIAGNOSTICS "-Wno-weak-vtables") |
12 | |
13 | # This warning warns when a default case is at a switch that handles all |
14 | # cases. While this is super nice, silencing this warning for clang will add |
15 | @@ -132,8 +134,7 @@ |
16 | add_flag(WL_COMPILE_DIAGNOSTICS "-Wno-covered-switch-default") |
17 | add_flag(WL_COMPILE_DIAGNOSTICS "-Wno-unreachable-code") |
18 | |
19 | - # TODO(sirver): weak-vtables should be enabled, but leads to lot of errors right now. |
20 | - add_flag(WL_COMPILE_DIAGNOSTICS "-Wno-weak-vtables") |
21 | + add_flag(WL_COMPILE_DIAGNOSTICS "-Qunused-arguments") |
22 | else() |
23 | # Assuming GCC 4.7 or higher. |
24 | if(WIN32) |
25 | |
26 | === modified file 'src/logic/CMakeLists.txt' |
27 | --- src/logic/CMakeLists.txt 2014-07-05 14:22:44 +0000 |
28 | +++ src/logic/CMakeLists.txt 2014-07-06 08:25:52 +0000 |
29 | @@ -108,6 +108,8 @@ |
30 | immovable.cc |
31 | immovable.h |
32 | immovable_program.h |
33 | + terrain_affinity.cc |
34 | + terrain_affinity.h |
35 | instances.cc |
36 | instances.h |
37 | map.cc |
38 | |
39 | === modified file 'src/logic/description_maintainer.h' |
40 | --- src/logic/description_maintainer.h 2014-07-05 16:41:51 +0000 |
41 | +++ src/logic/description_maintainer.h 2014-07-06 08:25:52 +0000 |
42 | @@ -20,6 +20,7 @@ |
43 | #ifndef WL_LOGIC_DESCRIPTION_MAINTAINER_H |
44 | #define WL_LOGIC_DESCRIPTION_MAINTAINER_H |
45 | |
46 | +#include <cassert> |
47 | #include <map> |
48 | #include <memory> |
49 | #include <string> |
50 | @@ -55,6 +56,14 @@ |
51 | return (idx >= 0 && idx < static_cast<int32_t>(items_.size())) ? items_[idx].get() : nullptr; |
52 | } |
53 | |
54 | + // Returns the entry at 'index'. If 'index' is out of bounds the result is |
55 | + // undefined. |
56 | + // TODO(sirver): this should be called get and the other should be called get_mutable. |
57 | + T& get_unmutable(const uint32_t index) const { |
58 | + assert(0 <= index && index < items_.size()); |
59 | + return *items_.at(index); |
60 | + } |
61 | + |
62 | private: |
63 | typedef std::map<std::string, int> NameToIndexMap; |
64 | std::vector<std::unique_ptr<T>> items_; |
65 | |
66 | === modified file 'src/logic/game.cc' |
67 | --- src/logic/game.cc 2014-07-05 13:14:42 +0000 |
68 | +++ src/logic/game.cc 2014-07-06 08:25:52 +0000 |
69 | @@ -20,6 +20,7 @@ |
70 | #include "logic/game.h" |
71 | |
72 | #include <cstring> |
73 | +#include <limits> |
74 | #include <memory> |
75 | #include <string> |
76 | |
77 | @@ -1154,4 +1155,8 @@ |
78 | } |
79 | } |
80 | |
81 | +double logic_rand_as_double(Game* game) { |
82 | + return static_cast<double>(game->logic_rand()) / std::numeric_limits<uint32_t>::max(); |
83 | +} |
84 | + |
85 | } |
86 | |
87 | === modified file 'src/logic/game.h' |
88 | --- src/logic/game.h 2014-07-05 16:41:51 +0000 |
89 | +++ src/logic/game.h 2014-07-06 08:25:52 +0000 |
90 | @@ -274,6 +274,9 @@ |
91 | return location; |
92 | } |
93 | |
94 | +// Returns a value between [0., 1]. |
95 | +double logic_rand_as_double(Game* game); |
96 | + |
97 | } |
98 | |
99 | #endif // end of include guard: WL_LOGIC_GAME_H |
100 | |
101 | === modified file 'src/logic/immovable.cc' |
102 | --- src/logic/immovable.cc 2014-07-05 14:22:44 +0000 |
103 | +++ src/logic/immovable.cc 2014-07-06 08:25:52 +0000 |
104 | @@ -44,6 +44,7 @@ |
105 | #include "logic/map.h" |
106 | #include "logic/mapfringeregion.h" |
107 | #include "logic/player.h" |
108 | +#include "logic/terrain_affinity.h" |
109 | #include "logic/tribe.h" |
110 | #include "logic/widelands_geometry_io.h" |
111 | #include "logic/worker.h" |
112 | @@ -297,6 +298,10 @@ |
113 | add_animation(animation, g_gr->animations().load(*anims->get_table(animation))); |
114 | } |
115 | |
116 | + if (table.has_key("terrain_affinity")) { |
117 | + terrain_affinity_.reset(new TerrainAffinity(*table.get_table("terrain_affinity"), name())); |
118 | + } |
119 | + |
120 | std::unique_ptr<LuaTable> programs = table.get_table("programs"); |
121 | for (const std::string& program_name : programs->keys<std::string>()) { |
122 | try { |
123 | @@ -322,6 +327,13 @@ |
124 | return *editor_category_; |
125 | } |
126 | |
127 | +bool Immovable_Descr::has_terrain_affinity() const { |
128 | + return terrain_affinity_.get() != nullptr; |
129 | +} |
130 | + |
131 | +const TerrainAffinity& Immovable_Descr::terrain_affinity() const { |
132 | + return *terrain_affinity_; |
133 | +} |
134 | |
135 | void Immovable_Descr::make_sure_default_program_is_there() { |
136 | if (!m_programs.count("program")) { // default program |
137 | @@ -495,10 +507,6 @@ |
138 | schedule_act(game, 1); |
139 | } |
140 | |
141 | -uint32_t Immovable_Descr::terrain_suitability(FCoords const, const Map&) const { |
142 | - return 6 * 255; |
143 | -} |
144 | - |
145 | /** |
146 | * Run program timer. |
147 | */ |
148 | @@ -958,6 +966,11 @@ |
149 | ImmovableProgram::ActGrow::ActGrow |
150 | (char * parameters, Immovable_Descr & descr) |
151 | { |
152 | + if (!descr.has_terrain_affinity()) { |
153 | + throw game_data_error( |
154 | + "Immovable %s can 'grow', but has no terrain_affinity entry.", descr.name().c_str()); |
155 | + } |
156 | + |
157 | try { |
158 | tribe = true; |
159 | for (char * p = parameters;;) |
160 | @@ -995,22 +1008,21 @@ |
161 | } |
162 | } |
163 | |
164 | -void ImmovableProgram::ActGrow::execute |
165 | - (Game & game, Immovable & immovable) const |
166 | -{ |
167 | - const Map & map = game .map (); |
168 | - const Immovable_Descr & descr = immovable.descr(); |
169 | +void ImmovableProgram::ActGrow::execute(Game& game, Immovable& immovable) const { |
170 | + const Map& map = game.map(); |
171 | FCoords const f = map.get_fcoords(immovable.get_position()); |
172 | - if (game.logic_rand() % (6 * 255) < descr.terrain_suitability(f, map)) { |
173 | - Tribe_Descr const * const owner_tribe = |
174 | - tribe ? immovable.descr().get_owner_tribe() : nullptr; |
175 | - immovable.remove(game); // Now immovable is a dangling reference! |
176 | + const Immovable_Descr& descr = immovable.descr(); |
177 | + |
178 | + if (logic_rand_as_double(&game) < |
179 | + probability_to_grow(descr.terrain_affinity(), f, map, game.world().terrains())) { |
180 | + Tribe_Descr const* const owner_tribe = tribe ? descr.get_owner_tribe() : nullptr; |
181 | + immovable.remove(game); // Now immovable is a dangling reference! |
182 | game.create_immovable(f, type_name, owner_tribe); |
183 | - } else |
184 | + } else { |
185 | immovable.program_step(game); |
186 | + } |
187 | } |
188 | |
189 | - |
190 | /** |
191 | * remove |
192 | */ |
193 | @@ -1041,7 +1053,6 @@ |
194 | immovable.program_step(game); |
195 | } |
196 | |
197 | - |
198 | ImmovableProgram::ActSeed::ActSeed(char * parameters, Immovable_Descr & descr) |
199 | { |
200 | try { |
201 | @@ -1098,31 +1109,35 @@ |
202 | void ImmovableProgram::ActSeed::execute |
203 | (Game & game, Immovable & immovable) const |
204 | { |
205 | - const Immovable_Descr & descr = immovable.descr(); |
206 | - const Map & map = game.map(); |
207 | - if |
208 | - (game.logic_rand() % (6 * 256) |
209 | - < |
210 | - descr.terrain_suitability |
211 | - (map.get_fcoords(immovable.get_position()), map)) |
212 | - { |
213 | - MapFringeRegion<> mr(map, Area<>(immovable.get_position(), 0)); |
214 | + const Map& map = game.map(); |
215 | + FCoords const f = map.get_fcoords(immovable.get_position()); |
216 | + const Immovable_Descr& descr = immovable.descr(); |
217 | + double p = |
218 | + probability_to_grow(descr.terrain_affinity(), f, map, game.world().terrains()); |
219 | + |
220 | + if (logic_rand_as_double(&game) < |
221 | + probability_to_grow(descr.terrain_affinity(), f, map, game.world().terrains())) { |
222 | + // Seed a new tree. |
223 | + MapFringeRegion<> mr(map, Area<>(f, 0)); |
224 | uint32_t fringe_size = 0; |
225 | do { |
226 | mr.extend(map); |
227 | fringe_size += 6; |
228 | - } while (game.logic_rand() % 256 < probability); |
229 | - for (uint32_t n = game.logic_rand() % fringe_size; n; --n) |
230 | + } while (game.logic_rand() % std::numeric_limits<uint8_t>::max() < probability); |
231 | + |
232 | + for (uint32_t n = game.logic_rand() % fringe_size; n; --n) { |
233 | mr.advance(map); |
234 | - FCoords const f = map.get_fcoords(mr.location()); |
235 | - if |
236 | - (not f.field->get_immovable() and |
237 | - (f.field->nodecaps() & MOVECAPS_WALK) and |
238 | - game.logic_rand() % (6 * 256) < descr.terrain_suitability(f, map)) |
239 | - game.create_immovable |
240 | - (mr.location(), |
241 | - type_name, |
242 | - tribe ? immovable.descr().get_owner_tribe() : nullptr); |
243 | + } |
244 | + |
245 | + const FCoords new_location = map.get_fcoords(mr.location()); |
246 | + if (!new_location.field->get_immovable() && |
247 | + (new_location.field->nodecaps() & MOVECAPS_WALK) && |
248 | + logic_rand_as_double(&game) < |
249 | + probability_to_grow( |
250 | + descr.terrain_affinity(), new_location, map, game.world().terrains())) { |
251 | + game.create_immovable( |
252 | + mr.location(), type_name, tribe ? immovable.descr().get_owner_tribe() : nullptr); |
253 | + } |
254 | } |
255 | |
256 | immovable.program_step(game); |
257 | |
258 | === modified file 'src/logic/immovable.h' |
259 | --- src/logic/immovable.h 2014-07-05 16:41:51 +0000 |
260 | +++ src/logic/immovable.h 2014-07-06 08:25:52 +0000 |
261 | @@ -35,6 +35,7 @@ |
262 | |
263 | class Economy; |
264 | class Map; |
265 | +class TerrainAffinity; |
266 | class WareInstance; |
267 | class Worker; |
268 | class World; |
269 | @@ -109,14 +110,19 @@ |
270 | |
271 | Tribe_Descr const * get_owner_tribe() const {return m_owner_tribe;} |
272 | |
273 | - /// How well the terrain around f suits an immovable of this type. |
274 | - uint32_t terrain_suitability(FCoords, const Map &) const; |
275 | - |
276 | const Buildcost & buildcost() const {return m_buildcost;} |
277 | |
278 | // Returns the editor category. |
279 | const EditorCategory& editor_category() const; |
280 | |
281 | + // Every immovable that can 'grow' needs to have terrain affinity defined, |
282 | + // all others do not. Returns true if this one has it defined. |
283 | + bool has_terrain_affinity() const; |
284 | + |
285 | + // Returns the terrain affinity. If !has_terrain_affinity() this will return |
286 | + // an undefined value. |
287 | + const TerrainAffinity& terrain_affinity() const; |
288 | + |
289 | protected: |
290 | int32_t m_size; |
291 | Programs m_programs; |
292 | @@ -130,10 +136,11 @@ |
293 | Buildcost m_buildcost; |
294 | |
295 | private: |
296 | - EditorCategory* editor_category_; // not owned. |
297 | - |
298 | // Adds a default program if none was defined. |
299 | void make_sure_default_program_is_there(); |
300 | + |
301 | + EditorCategory* editor_category_; // not owned. |
302 | + std::unique_ptr<TerrainAffinity> terrain_affinity_; |
303 | }; |
304 | |
305 | class Immovable : public BaseImmovable { |
306 | |
307 | === added file 'src/logic/terrain_affinity.cc' |
308 | --- src/logic/terrain_affinity.cc 1970-01-01 00:00:00 +0000 |
309 | +++ src/logic/terrain_affinity.cc 2014-07-06 08:25:52 +0000 |
310 | @@ -0,0 +1,129 @@ |
311 | +/* |
312 | + * Copyright (C) 2006-2014 by the Widelands Development Team |
313 | + * |
314 | + * This program is free software; you can redistribute it and/or |
315 | + * modify it under the terms of the GNU General Public License |
316 | + * as published by the Free Software Foundation; either version 2 |
317 | + * of the License, or (at your option) any later version. |
318 | + * |
319 | + * This program is distributed in the hope that it will be useful, |
320 | + * but WITHOUT ANY WARRANTY; without even the implied warranty of |
321 | + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
322 | + * GNU General Public License for more details. |
323 | + * |
324 | + * You should have received a copy of the GNU General Public License |
325 | + * along with this program; if not, write to the Free Software |
326 | + * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. |
327 | + * |
328 | + */ |
329 | + |
330 | +#include "logic/terrain_affinity.h" |
331 | + |
332 | +#include <vector> |
333 | + |
334 | +#include "logic/description_maintainer.h" |
335 | +#include "logic/field.h" |
336 | +#include "logic/map.h" |
337 | +#include "logic/widelands_geometry.h" |
338 | +#include "logic/world/terrain_description.h" |
339 | +#include "scripting/lua_table.h" |
340 | + |
341 | +namespace Widelands { |
342 | + |
343 | +namespace { |
344 | + |
345 | +constexpr double pow2(const double& a) { |
346 | + return a * a; |
347 | +} |
348 | + |
349 | +} // namespace |
350 | + |
351 | +TerrainAffinity::TerrainAffinity(const LuaTable& table, const std::string& immovable_name) |
352 | + : preferred_fertility_(table.get_double("preferred_fertility")), |
353 | + preferred_humidity_(table.get_double("preferred_humidity")), |
354 | + preferred_temperature_(table.get_double("preferred_temperature")), |
355 | + pickiness_(table.get_double("pickiness")) { |
356 | + if (!(0 <= preferred_fertility_ && preferred_fertility_ <= 1.)) { |
357 | + throw game_data_error("%s: preferred_fertility is not in [0, 1].", immovable_name.c_str()); |
358 | + } |
359 | + if (!(0 <= preferred_humidity_ && preferred_humidity_ <= 1.)) { |
360 | + throw game_data_error("%s: preferred_humidity is not in [0, 1].", immovable_name.c_str()); |
361 | + } |
362 | + if (!(0 <= pickiness_ && pickiness_ <= 1.)) { |
363 | + throw game_data_error("%s: pickiness is not in [0, 1].", immovable_name.c_str()); |
364 | + } |
365 | + if (preferred_temperature_ < 0) { |
366 | + throw game_data_error("%s: preferred_temperature is not in Kelvin.", immovable_name.c_str()); |
367 | + } |
368 | +} |
369 | + |
370 | +double TerrainAffinity::preferred_temperature() const { |
371 | + return preferred_temperature_; |
372 | +} |
373 | + |
374 | +double TerrainAffinity::preferred_fertility() const { |
375 | + return preferred_fertility_; |
376 | +} |
377 | + |
378 | +double TerrainAffinity::preferred_humidity() const { |
379 | + return preferred_humidity_; |
380 | +} |
381 | + |
382 | +double TerrainAffinity::pickiness() const { |
383 | + return pickiness_; |
384 | +} |
385 | + |
386 | +double probability_to_grow(const TerrainAffinity& affinity, |
387 | + const FCoords& fcoords, |
388 | + const Map& map, |
389 | + const DescriptionMaintainer<TerrainDescription>& terrains) { |
390 | + double terrain_humidity = 0; |
391 | + double terrain_fertility = 0; |
392 | + double terrain_temperature = 0; |
393 | + |
394 | + const auto average = [&terrain_humidity, &terrain_fertility, &terrain_temperature, &terrains]( |
395 | + const int terrain_index) { |
396 | + const TerrainDescription& t = terrains.get_unmutable(terrain_index); |
397 | + terrain_humidity += t.humidity() / 6.; |
398 | + terrain_temperature += t.temperature() / 6.; |
399 | + terrain_fertility += t.fertility() / 6.; |
400 | + }; |
401 | + |
402 | + average(fcoords.field->terrain_d()); |
403 | + average(fcoords.field->terrain_r()); |
404 | + { |
405 | + FCoords tln; |
406 | + map.get_tln(fcoords, &tln); |
407 | + average(tln.field->terrain_d()); |
408 | + average(tln.field->terrain_r()); |
409 | + } |
410 | + |
411 | + { |
412 | + FCoords trn; |
413 | + map.get_trn(fcoords, &trn); |
414 | + average(trn.field->terrain_d()); |
415 | + } |
416 | + |
417 | + { |
418 | + FCoords ln; |
419 | + map.get_ln(fcoords, &ln); |
420 | + average(ln.field->terrain_r()); |
421 | + } |
422 | + |
423 | + const double sigma_fertility = (1. - affinity.pickiness()) * 0.25 + 1e-2; |
424 | + const double sigma_humidity = (1. - affinity.pickiness()) * 0.25 + 1e-2; |
425 | + const double sigma_temperature = (1. - affinity.pickiness()) * 12.5 + 1e-1; |
426 | + |
427 | + const double pure_gauss = exp( |
428 | + -pow2(affinity.preferred_fertility() - terrain_fertility) / (2 * pow2(sigma_fertility)) - |
429 | + pow2(affinity.preferred_humidity() - terrain_humidity) / (2 * pow2(sigma_temperature)) - |
430 | + pow2(affinity.preferred_temperature() - terrain_temperature) / (2 * pow2(sigma_temperature))); |
431 | + |
432 | + double advanced_gauss = pure_gauss * 1.1 + 0.05; |
433 | + if (advanced_gauss > 0.95) |
434 | + advanced_gauss = 0.95; |
435 | + |
436 | + return advanced_gauss; |
437 | +} |
438 | + |
439 | +} // namespace Widelands |
440 | |
441 | === added file 'src/logic/terrain_affinity.h' |
442 | --- src/logic/terrain_affinity.h 1970-01-01 00:00:00 +0000 |
443 | +++ src/logic/terrain_affinity.h 2014-07-06 08:25:52 +0000 |
444 | @@ -0,0 +1,73 @@ |
445 | +/* |
446 | + * Copyright (C) 2006-2014 by the Widelands Development Team |
447 | + * |
448 | + * This program is free software; you can redistribute it and/or |
449 | + * modify it under the terms of the GNU General Public License |
450 | + * as published by the Free Software Foundation; either version 2 |
451 | + * of the License, or (at your option) any later version. |
452 | + * |
453 | + * This program is distributed in the hope that it will be useful, |
454 | + * but WITHOUT ANY WARRANTY; without even the implied warranty of |
455 | + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
456 | + * GNU General Public License for more details. |
457 | + * |
458 | + * You should have received a copy of the GNU General Public License |
459 | + * along with this program; if not, write to the Free Software |
460 | + * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. |
461 | + * |
462 | + */ |
463 | + |
464 | +#ifndef WL_LOGIC_TERRAIN_AFFINITY_H |
465 | +#define WL_LOGIC_TERRAIN_AFFINITY_H |
466 | + |
467 | +#include <string> |
468 | + |
469 | +#include <boost/noncopyable.hpp> |
470 | + |
471 | +#include "logic/description_maintainer.h" |
472 | + |
473 | +class LuaTable; |
474 | + |
475 | +namespace Widelands { |
476 | + |
477 | +class Map; |
478 | +class TerrainDescription; |
479 | +class World; |
480 | +struct FCoords; |
481 | + |
482 | +// Describes the parameters and the pickiness of Immovables towards terrain |
483 | +// parameters. Alls immovables that use 'grow' in any of their programs must |
484 | +// define this. |
485 | +class TerrainAffinity : boost::noncopyable { |
486 | +public: |
487 | + explicit TerrainAffinity(const LuaTable& table, const std::string& immovable_name); |
488 | + |
489 | + // Preferred temperature in Kelvin. |
490 | + double preferred_temperature() const; |
491 | + |
492 | + // Preferred fertility in percent [0, 1]. |
493 | + double preferred_fertility() const; |
494 | + |
495 | + // Preferred humidity in percent [0, 1]. |
496 | + double preferred_humidity() const; |
497 | + |
498 | + // A value in [0, 1] that defines how well this can deal with non-ideal |
499 | + // situations. Lower means it is less picky, i.e. it can deal better. |
500 | + double pickiness() const; |
501 | + |
502 | +private: |
503 | + double preferred_fertility_; |
504 | + double preferred_humidity_; |
505 | + double preferred_temperature_; |
506 | + double pickiness_; |
507 | +}; |
508 | + |
509 | +// Returns a value in [0., 1.] that describes the suitability for the |
510 | +// 'immovable_affinity' for 'field'. Higher is better suited. |
511 | +double probability_to_grow |
512 | + (const TerrainAffinity& immovable_affinity, const FCoords& fcoords, |
513 | + const Map& map, const DescriptionMaintainer<TerrainDescription>& terrains); |
514 | + |
515 | +} // namespace Widelands |
516 | + |
517 | +#endif // end of include guard: WL_LOGIC_TERRAIN_AFFINITY_H |
518 | |
519 | === modified file 'src/logic/worker.cc' |
520 | --- src/logic/worker.cc 2014-07-05 12:48:58 +0000 |
521 | +++ src/logic/worker.cc 2014-07-06 08:25:52 +0000 |
522 | @@ -19,7 +19,9 @@ |
523 | |
524 | #include "logic/worker.h" |
525 | |
526 | +#include <iterator> |
527 | #include <memory> |
528 | +#include <tuple> |
529 | |
530 | #include <boost/format.hpp> |
531 | |
532 | @@ -49,6 +51,7 @@ |
533 | #include "logic/message_queue.h" |
534 | #include "logic/player.h" |
535 | #include "logic/soldier.h" |
536 | +#include "logic/terrain_affinity.h" |
537 | #include "logic/tribe.h" |
538 | #include "logic/warehouse.h" |
539 | #include "logic/worker_program.h" |
540 | @@ -806,73 +809,75 @@ |
541 | return true; |
542 | } |
543 | |
544 | - std::vector<int32_t> best_fitting; |
545 | std::vector<bool> is_tribe_specific; |
546 | - uint32_t terrain_suitability = 0; |
547 | - for (uint8_t i = 0; i < action.sparamv.size(); ++i) { |
548 | - std::vector<std::string> const list(split_string(action.sparamv[i], ":")); |
549 | - std::string immovable; |
550 | - |
551 | - if (list.size() == 1) { |
552 | - state.svar1 = "world"; |
553 | - immovable = list[0]; |
554 | - state.ivar2 = game.world().get_immovable_index(immovable.c_str()); |
555 | - if (state.ivar2 > 0) { |
556 | - Immovable_Descr const * imm = |
557 | - game.world().get_immovable_descr(state.ivar2); |
558 | - uint32_t suits = imm->terrain_suitability(fpos, map); |
559 | - // Remove existing, if this immovable suits better |
560 | - if (suits > terrain_suitability) { |
561 | - best_fitting.clear(); |
562 | - is_tribe_specific.clear(); |
563 | - } |
564 | - if (suits >= terrain_suitability) { |
565 | - terrain_suitability = suits; |
566 | - best_fitting.push_back(state.ivar2); |
567 | - is_tribe_specific.push_back(false); |
568 | - } |
569 | - continue; |
570 | - } |
571 | - } else { |
572 | - state.svar1 = "tribe"; |
573 | - immovable = list[1]; |
574 | - state.ivar2 = descr().tribe().get_immovable_index(immovable.c_str()); |
575 | - if (state.ivar2 > 0) { |
576 | - Immovable_Descr const * imm = |
577 | - descr().tribe().get_immovable_descr(state.ivar2); |
578 | - uint32_t suits = imm->terrain_suitability(fpos, map); |
579 | - // Remove existing, if this immovable suits better |
580 | - if (suits > terrain_suitability) { |
581 | - best_fitting.clear(); |
582 | - is_tribe_specific.clear(); |
583 | - } |
584 | - if (suits >= terrain_suitability) { |
585 | - terrain_suitability = suits; |
586 | - best_fitting.push_back(state.ivar2); |
587 | - is_tribe_specific.push_back(true); |
588 | - } |
589 | - continue; |
590 | - } |
591 | - } |
592 | - |
593 | - // Only here if immovable was not found |
594 | - molog(" WARNING: Unknown immovable %s\n", action.sparamv[i].c_str()); |
595 | - send_signal(game, "fail"); |
596 | - pop_task(game); |
597 | - return true; |
598 | - } |
599 | - |
600 | - assert(best_fitting.size() == is_tribe_specific.size()); |
601 | - if (best_fitting.empty()) { |
602 | + |
603 | + // Figure the (at most) six best fitting immovables (as judged by terrain |
604 | + // affinity). We will pick one of them at random later. The container is |
605 | + // picked to be a stable sorting one, so that no deyncs happen in |
606 | + // multiplayer. |
607 | + std::set<std::tuple<double, uint32_t>> best_suited_immovables_index; |
608 | + |
609 | + // Checks if the 'immovable_description' has a terrain_affinity, if so use it. Otherwise assume it |
610 | + // to be 1. (perfect fit). Adds it to the best_suited_immovables_index. |
611 | + const auto test_suitability = [&best_suited_immovables_index, &fpos, &map, &game]( |
612 | + const uint32_t index, const Immovable_Descr& immovable_description) { |
613 | + double p = 1.; |
614 | + if (immovable_description.has_terrain_affinity()) { |
615 | + p = probability_to_grow( |
616 | + immovable_description.terrain_affinity(), fpos, map, game.world().terrains()); |
617 | + } |
618 | + best_suited_immovables_index.insert(std::make_tuple(p, index)); |
619 | + if (best_suited_immovables_index.size() > 6) { |
620 | + best_suited_immovables_index.erase(best_suited_immovables_index.begin()); |
621 | + } |
622 | + }; |
623 | + |
624 | + if (action.sparamv.size() != 1) { |
625 | + throw game_data_error("plant takes only one argument."); |
626 | + } |
627 | + |
628 | + std::vector<std::string> const list(split_string(action.sparamv[0], ":")); |
629 | + |
630 | + if (list.size() != 2) { |
631 | + throw game_data_error("plant takes either tribe:<immovable> or attrib:<attribute>"); |
632 | + } |
633 | + |
634 | + if (list[0] == "attrib") { |
635 | + state.svar1 = "world"; |
636 | + |
637 | + const DescriptionMaintainer<Immovable_Descr>& immovables = game.world().immovables(); |
638 | + |
639 | + const uint32_t attribute_id = Immovable_Descr::get_attribute_id(list[1]); |
640 | + for (uint32_t i = 0; i < immovables.get_nitems(); ++i) { |
641 | + Immovable_Descr& immovable_descr = immovables.get_unmutable(i); |
642 | + if (!immovable_descr.has_attribute(attribute_id)) { |
643 | + continue; |
644 | + } |
645 | + test_suitability(i, immovable_descr); |
646 | + } |
647 | + } else { |
648 | + state.svar1 = "tribe"; |
649 | + uint32_t immovable_index = descr().tribe().get_immovable_index(list[1]); |
650 | + |
651 | + if (immovable_index > 0) { |
652 | + const Immovable_Descr* imm = descr().tribe().get_immovable_descr(immovable_index); |
653 | + test_suitability(immovable_index, *imm); |
654 | + } |
655 | + } |
656 | + |
657 | + if (best_suited_immovables_index.empty()) { |
658 | molog(" WARNING: No suitable immovable found!"); |
659 | send_signal(game, "fail"); |
660 | pop_task(game); |
661 | return true; |
662 | } |
663 | - uint32_t const idx = game.logic_rand() % best_fitting.size(); |
664 | - |
665 | - Immovable & newimm = game.create_immovable |
666 | - (pos, best_fitting[idx], is_tribe_specific[idx] ? &descr().tribe() : nullptr); |
667 | + |
668 | + // Randomly pick one of the immovables to be planted. |
669 | + const uint32_t idx = game.logic_rand() % best_suited_immovables_index.size(); |
670 | + state.ivar2 = std::get<1>(*std::next(best_suited_immovables_index.begin(), idx)); |
671 | + |
672 | + Immovable& newimm = |
673 | + game.create_immovable(pos, state.ivar2, state.svar1 == "tribe" ? &descr().tribe() : nullptr); |
674 | newimm.set_owner(get_owner()); |
675 | |
676 | if (action.iparam1 == Action::plantUnlessObject) |
677 | |
678 | === modified file 'src/logic/world/editor_category.cc' |
679 | --- src/logic/world/editor_category.cc 2014-05-01 11:46:05 +0000 |
680 | +++ src/logic/world/editor_category.cc 2014-07-06 08:25:52 +0000 |
681 | @@ -20,6 +20,8 @@ |
682 | #include "logic/world/editor_category.h" |
683 | |
684 | #include "graphic/graphic.h" |
685 | +#include "io/filesystem/layered_filesystem.h" |
686 | +#include "logic/game_data_error.h" |
687 | #include "scripting/lua_table.h" |
688 | |
689 | namespace Widelands { |
690 | @@ -28,6 +30,9 @@ |
691 | : name_(table.get_string("name")), |
692 | descname_(table.get_string("descname")), |
693 | image_file_(table.get_string("picture")) { |
694 | + if (!g_fs->FileExists(image_file_)) { |
695 | + throw game_data_error("EditorCategory %s has non-existing \"picture\".", name_.c_str()); |
696 | + } |
697 | } |
698 | |
699 | const std::string& EditorCategory::name() const { |
700 | |
701 | === modified file 'src/logic/world/terrain_description.cc' |
702 | --- src/logic/world/terrain_description.cc 2014-07-05 14:22:44 +0000 |
703 | +++ src/logic/world/terrain_description.cc 2014-07-06 08:25:52 +0000 |
704 | @@ -71,8 +71,20 @@ |
705 | is_(TerrainTypeFromString(table.get_string("is"))), |
706 | default_resource_index_(world.get_resource(table.get_string("default_resource").c_str())), |
707 | default_resource_amount_(table.get_int("default_resource_amount")), |
708 | - dither_layer_(table.get_int("dither_layer")) { |
709 | + dither_layer_(table.get_int("dither_layer")), |
710 | + temperature_(table.get_double("temperature")), |
711 | + fertility_(table.get_double("fertility")), |
712 | + humidity_(table.get_double("humidity")) { |
713 | |
714 | + if (!(0 <= fertility_ && fertility_ <= 1.)) { |
715 | + throw game_data_error("%s: fertility is not in [0, 1].", name_.c_str()); |
716 | + } |
717 | + if (!(0 <= humidity_ && humidity_ <= 1.)) { |
718 | + throw game_data_error("%s: humidity is not in [0, 1].", name_.c_str()); |
719 | + } |
720 | + if (temperature_ < 0) { |
721 | + throw game_data_error("%s: temperature is not in Kelvin.", name_.c_str()); |
722 | + } |
723 | |
724 | const std::vector<std::string> textures = |
725 | table.get_table("textures")->array_entries<std::string>(); |
726 | @@ -100,8 +112,8 @@ |
727 | int editor_category_index = |
728 | world.editor_terrain_categories().get_index(table.get_string("editor_category")); |
729 | if (editor_category_index < 0) { |
730 | - throw game_data_error("Unknown editor_category: %s\n", |
731 | - table.get_string("editor_category").c_str()); |
732 | + throw game_data_error( |
733 | + "Unknown editor_category: %s\n", table.get_string("editor_category").c_str()); |
734 | } |
735 | editor_category_ = world.editor_terrain_categories().get(editor_category_index); |
736 | } |
737 | @@ -158,4 +170,16 @@ |
738 | return dither_layer_; |
739 | } |
740 | |
741 | +double TerrainDescription::temperature() const { |
742 | + return temperature_; |
743 | +} |
744 | + |
745 | +double TerrainDescription::humidity() const { |
746 | + return humidity_; |
747 | +} |
748 | + |
749 | +double TerrainDescription::fertility() const { |
750 | + return fertility_; |
751 | +} |
752 | + |
753 | } // namespace Widelands |
754 | |
755 | === modified file 'src/logic/world/terrain_description.h' |
756 | --- src/logic/world/terrain_description.h 2014-07-05 16:41:51 +0000 |
757 | +++ src/logic/world/terrain_description.h 2014-07-06 08:25:52 +0000 |
758 | @@ -83,6 +83,16 @@ |
759 | /// Returns the editor category. |
760 | const EditorCategory& editor_category() const; |
761 | |
762 | + /// Parameters for terrain affinity of immovables. |
763 | + /// Temperature in Kelvin. |
764 | + double temperature() const; |
765 | + |
766 | + /// Humidity in percent [0, 1]. |
767 | + double humidity() const; |
768 | + |
769 | + /// Fertility in percent [0, 1]. |
770 | + double fertility() const; |
771 | + |
772 | private: |
773 | const std::string name_; |
774 | const std::string descname_; |
775 | @@ -94,6 +104,9 @@ |
776 | const std::vector<std::string> texture_paths_; |
777 | int32_t dither_layer_; |
778 | uint32_t texture_; ///< renderer's texture |
779 | + double temperature_; |
780 | + double fertility_; |
781 | + double humidity_; |
782 | }; |
783 | |
784 | } // namespace Widelands |
785 | |
786 | === modified file 'tribes/atlanteans/forester/conf' |
787 | --- tribes/atlanteans/forester/conf 2014-04-26 13:55:11 +0000 |
788 | +++ tribes/atlanteans/forester/conf 2014-07-06 08:25:52 +0000 |
789 | @@ -10,7 +10,7 @@ |
790 | 1=walk coords |
791 | 2=animation dig 2000 # Play a planting animation |
792 | 3=animation crop 1000 # Play a planting animation |
793 | -4=plant aspen_summer_sapling oak_summer_sapling spruce_summer_sapling alder_summer_sapling birch_summer_sapling beech_summer_sapling larch_summer_sapling rowan_summer_sapling |
794 | +4=plant attrib:tree_sapling |
795 | 5=animation water 2000 |
796 | 6=return |
797 | |
798 | |
799 | === modified file 'tribes/barbarians/ranger/conf' |
800 | --- tribes/barbarians/ranger/conf 2014-04-26 13:55:11 +0000 |
801 | +++ tribes/barbarians/ranger/conf 2014-07-06 08:25:52 +0000 |
802 | @@ -10,7 +10,7 @@ |
803 | 1=walk coords |
804 | 2=animation dig 2000 # Play a planting animation |
805 | 3=animation crop 1000 # Play a planting animation |
806 | -4=plant aspen_summer_sapling oak_summer_sapling spruce_summer_sapling alder_summer_sapling birch_summer_sapling beech_summer_sapling larch_summer_sapling rowan_summer_sapling |
807 | +4=plant attrib:tree_sapling |
808 | 5=animation water 2000 |
809 | 6=return |
810 | |
811 | |
812 | === modified file 'tribes/empire/forester/conf' |
813 | --- tribes/empire/forester/conf 2014-04-26 13:55:11 +0000 |
814 | +++ tribes/empire/forester/conf 2014-07-06 08:25:52 +0000 |
815 | @@ -10,7 +10,7 @@ |
816 | 1=walk coords |
817 | 2=animation dig 2000 # Play a planting animation |
818 | 3=animation crop 1000 # Play a planting animation |
819 | -4=plant aspen_summer_sapling oak_summer_sapling spruce_summer_sapling alder_summer_sapling birch_summer_sapling beech_summer_sapling larch_summer_sapling rowan_summer_sapling |
820 | +4=plant attrib:tree_sapling |
821 | 5=animation water 2000 |
822 | 6=return |
823 | |
824 | |
825 | === added directory 'world/immovables/trees/alder' |
826 | === added file 'world/immovables/trees/alder/init.lua' |
827 | --- world/immovables/trees/alder/init.lua 1970-01-01 00:00:00 +0000 |
828 | +++ world/immovables/trees/alder/init.lua 2014-07-06 08:25:52 +0000 |
829 | @@ -0,0 +1,115 @@ |
830 | +dirname = path.dirname(__file__) |
831 | + |
832 | +terrain_affinity = { |
833 | + -- In Kelvin. |
834 | + preferred_temperature = 293, |
835 | + |
836 | + -- In percent (1 being very wet). |
837 | + preferred_humidity = 0.6, |
838 | + |
839 | + -- In percent (1 being very fertile). |
840 | + preferred_fertility = 0.7, |
841 | + |
842 | + -- A value in [0, 1] that defines how well this can deal with non-ideal |
843 | + -- situations. Lower means it is less picky, i.e. it can deal better. |
844 | + pickiness = 0.5, |
845 | +} |
846 | + |
847 | +world:new_immovable_type{ |
848 | + name = "alder_summer_sapling", |
849 | + descname = _ "Alder (Sapling)", |
850 | + editor_category = "trees_deciduous", |
851 | + size = "small", |
852 | + attributes = { "tree_sapling" }, |
853 | + terrain_affinity = terrain_affinity, |
854 | + programs = { |
855 | + program = { |
856 | + "animate=idle 57500", |
857 | + "remove=21", |
858 | + "grow=alder_summer_pole", |
859 | + }, |
860 | + }, |
861 | + animations = { |
862 | + idle = { |
863 | + pictures = path.list_directory(dirname .. "sapling/", "idle_\\d+.png"), |
864 | + hotspot = { 5, 12 }, |
865 | + fps = 8, |
866 | + }, |
867 | + }, |
868 | +} |
869 | + |
870 | +world:new_immovable_type{ |
871 | + name = "alder_summer_pole", |
872 | + descname = _ "Alder (Pole)", |
873 | + editor_category = "trees_deciduous", |
874 | + size = "small", |
875 | + attributes = {}, |
876 | + terrain_affinity = terrain_affinity, |
877 | + programs = { |
878 | + program = { |
879 | + "animate=idle 52500", |
880 | + "remove=19", |
881 | + "grow=alder_summer_mature", |
882 | + }, |
883 | + }, |
884 | + animations = { |
885 | + idle = { |
886 | + pictures = path.list_directory(dirname .. "pole/", "idle_\\d+.png"), |
887 | + hotspot = { 12, 28 }, |
888 | + fps = 8, |
889 | + }, |
890 | + }, |
891 | +} |
892 | + |
893 | +world:new_immovable_type{ |
894 | + name = "alder_summer_mature", |
895 | + descname = _ "Alder (Mature)", |
896 | + editor_category = "trees_deciduous", |
897 | + size = "small", |
898 | + attributes = {}, |
899 | + terrain_affinity = terrain_affinity, |
900 | + programs = { |
901 | + program = { |
902 | + "animate=idle 50000", |
903 | + "remove=18", |
904 | + "grow=alder_summer_old", |
905 | + }, |
906 | + }, |
907 | + animations = { |
908 | + idle = { |
909 | + pictures = path.list_directory(dirname .. "mature/", "idle_\\d+.png"), |
910 | + hotspot = { 18, 48 }, |
911 | + fps = 8, |
912 | + }, |
913 | + }, |
914 | +} |
915 | + |
916 | +world:new_immovable_type{ |
917 | + name = "alder_summer_old", |
918 | + descname = _ "Alder (Old)", |
919 | + editor_category = "trees_deciduous", |
920 | + size = "small", |
921 | + attributes = { "tree" }, |
922 | + terrain_affinity = terrain_affinity, |
923 | + programs = { |
924 | + program = { |
925 | + "animate=idle 1550000", |
926 | + "transform=deadtree4 5", |
927 | + "seed=alder_summer_sapling", |
928 | + }, |
929 | + fall = { |
930 | + "remove=", |
931 | + }, |
932 | + }, |
933 | + animations = { |
934 | + idle = { |
935 | + pictures = path.list_directory(dirname .. "old/", "idle_\\d+.png"), |
936 | + hotspot = { 23, 59 }, |
937 | + fps = 10, |
938 | + sound_effect = { |
939 | + directory = "sound/animals", |
940 | + name = "bird4", |
941 | + }, |
942 | + }, |
943 | + }, |
944 | +} |
945 | |
946 | === renamed directory 'world/immovables/trees/alder_summer_mature' => 'world/immovables/trees/alder/mature' |
947 | === renamed directory 'world/immovables/trees/alder_summer_old' => 'world/immovables/trees/alder/old' |
948 | === renamed directory 'world/immovables/trees/alder_summer_pole' => 'world/immovables/trees/alder/pole' |
949 | === renamed directory 'world/immovables/trees/alder_summer_sapling' => 'world/immovables/trees/alder/sapling' |
950 | === removed file 'world/immovables/trees/alder_summer_mature/init.lua' |
951 | --- world/immovables/trees/alder_summer_mature/init.lua 2014-05-03 08:40:59 +0000 |
952 | +++ world/immovables/trees/alder_summer_mature/init.lua 1970-01-01 00:00:00 +0000 |
953 | @@ -1,23 +0,0 @@ |
954 | -dirname = path.dirname(__file__) |
955 | - |
956 | -world:new_immovable_type{ |
957 | - name = "alder_summer_mature", |
958 | - descname = _ "Alder (Mature)", |
959 | - editor_category = "trees_deciduous", |
960 | - size = "small", |
961 | - attributes = {}, |
962 | - programs = { |
963 | - program = { |
964 | - "animate=idle 50000", |
965 | - "remove=18", |
966 | - "grow=alder_summer_old", |
967 | - }, |
968 | - }, |
969 | - animations = { |
970 | - idle = { |
971 | - pictures = path.list_directory(dirname, "idle_\\d+.png"), |
972 | - hotspot = { 18, 48 }, |
973 | - fps = 8, |
974 | - }, |
975 | - }, |
976 | -} |
977 | |
978 | === removed file 'world/immovables/trees/alder_summer_old/init.lua' |
979 | --- world/immovables/trees/alder_summer_old/init.lua 2014-05-03 08:40:59 +0000 |
980 | +++ world/immovables/trees/alder_summer_old/init.lua 1970-01-01 00:00:00 +0000 |
981 | @@ -1,30 +0,0 @@ |
982 | -dirname = path.dirname(__file__) |
983 | - |
984 | -world:new_immovable_type{ |
985 | - name = "alder_summer_old", |
986 | - descname = _ "Alder (Old)", |
987 | - editor_category = "trees_deciduous", |
988 | - size = "small", |
989 | - attributes = { "tree" }, |
990 | - programs = { |
991 | - program = { |
992 | - "animate=idle 1550000", |
993 | - "transform=deadtree4 5", |
994 | - "seed=alder_summer_sapling", |
995 | - }, |
996 | - fall = { |
997 | - "remove=", |
998 | - }, |
999 | - }, |
1000 | - animations = { |
1001 | - idle = { |
1002 | - pictures = path.list_directory(dirname, "idle_\\d+.png"), |
1003 | - hotspot = { 23, 59 }, |
1004 | - fps = 10, |
1005 | - sound_effect = { |
1006 | - directory = "sound/animals", |
1007 | - name = "bird4", |
1008 | - }, |
1009 | - }, |
1010 | - }, |
1011 | -} |
1012 | |
1013 | === removed file 'world/immovables/trees/alder_summer_pole/init.lua' |
1014 | --- world/immovables/trees/alder_summer_pole/init.lua 2014-05-03 08:40:59 +0000 |
1015 | +++ world/immovables/trees/alder_summer_pole/init.lua 1970-01-01 00:00:00 +0000 |
1016 | @@ -1,23 +0,0 @@ |
1017 | -dirname = path.dirname(__file__) |
1018 | - |
1019 | -world:new_immovable_type{ |
1020 | - name = "alder_summer_pole", |
1021 | - descname = _ "Alder (Pole)", |
1022 | - editor_category = "trees_deciduous", |
1023 | - size = "small", |
1024 | - attributes = {}, |
1025 | - programs = { |
1026 | - program = { |
1027 | - "animate=idle 52500", |
1028 | - "remove=19", |
1029 | - "grow=alder_summer_mature", |
1030 | - }, |
1031 | - }, |
1032 | - animations = { |
1033 | - idle = { |
1034 | - pictures = path.list_directory(dirname, "idle_\\d+.png"), |
1035 | - hotspot = { 12, 28 }, |
1036 | - fps = 8, |
1037 | - }, |
1038 | - }, |
1039 | -} |
1040 | |
1041 | === removed file 'world/immovables/trees/alder_summer_sapling/init.lua' |
1042 | --- world/immovables/trees/alder_summer_sapling/init.lua 2014-05-03 08:40:59 +0000 |
1043 | +++ world/immovables/trees/alder_summer_sapling/init.lua 1970-01-01 00:00:00 +0000 |
1044 | @@ -1,23 +0,0 @@ |
1045 | -dirname = path.dirname(__file__) |
1046 | - |
1047 | -world:new_immovable_type{ |
1048 | - name = "alder_summer_sapling", |
1049 | - descname = _ "Alder (Sapling)", |
1050 | - editor_category = "trees_deciduous", |
1051 | - size = "small", |
1052 | - attributes = { "seed" }, |
1053 | - programs = { |
1054 | - program = { |
1055 | - "animate=idle 57500", |
1056 | - "remove=21", |
1057 | - "grow=alder_summer_pole", |
1058 | - }, |
1059 | - }, |
1060 | - animations = { |
1061 | - idle = { |
1062 | - pictures = path.list_directory(dirname, "idle_\\d+.png"), |
1063 | - hotspot = { 5, 12 }, |
1064 | - fps = 8, |
1065 | - }, |
1066 | - }, |
1067 | -} |
1068 | |
1069 | === added directory 'world/immovables/trees/aspen' |
1070 | === added file 'world/immovables/trees/aspen/init.lua' |
1071 | --- world/immovables/trees/aspen/init.lua 1970-01-01 00:00:00 +0000 |
1072 | +++ world/immovables/trees/aspen/init.lua 2014-07-06 08:25:52 +0000 |
1073 | @@ -0,0 +1,116 @@ |
1074 | +dirname = path.dirname(__file__) |
1075 | + |
1076 | +terrain_affinity = { |
1077 | + preferred_temperature = 293, |
1078 | + preferred_humidity = 0.6, |
1079 | + preferred_fertility = 0.7, |
1080 | + pickiness = 0.5, |
1081 | +} |
1082 | + |
1083 | +world:new_immovable_type{ |
1084 | + name = "aspen_summer_sapling", |
1085 | + descname = _ "Aspen (Sapling)", |
1086 | + editor_category = "trees_deciduous", |
1087 | + size = "small", |
1088 | + attributes = { "tree_sapling" }, |
1089 | + terrain_affinity = terrain_affinity, |
1090 | + programs = { |
1091 | + program = { |
1092 | + "animate=idle 38000", |
1093 | + "remove=50", |
1094 | + "grow=aspen_summer_pole", |
1095 | + }, |
1096 | + }, |
1097 | + animations = { |
1098 | + idle = { |
1099 | + pictures = path.list_directory(dirname .. "sapling/", "idle_\\d+.png"), |
1100 | + hotspot = { 5, 12 }, |
1101 | + fps = 8, |
1102 | + }, |
1103 | + }, |
1104 | +} |
1105 | + |
1106 | +world:new_immovable_type{ |
1107 | + name = "aspen_summer_pole", |
1108 | + descname = _ "Aspen (Pole)", |
1109 | + editor_category = "trees_deciduous", |
1110 | + size = "small", |
1111 | + attributes = {}, |
1112 | + terrain_affinity = terrain_affinity, |
1113 | + programs = { |
1114 | + program = { |
1115 | + "animate=idle 38000", |
1116 | + "remove=47", |
1117 | + "grow=aspen_summer_mature", |
1118 | + }, |
1119 | + }, |
1120 | + animations = { |
1121 | + idle = { |
1122 | + pictures = path.list_directory(dirname .. "pole/", "idle_\\d+.png"), |
1123 | + hotspot = { 12, 28 }, |
1124 | + fps = 8, |
1125 | + }, |
1126 | + }, |
1127 | +} |
1128 | + |
1129 | +world:new_immovable_type{ |
1130 | + name = "aspen_summer_mature", |
1131 | + descname = _ "Aspen (Mature)", |
1132 | + editor_category = "trees_deciduous", |
1133 | + size = "small", |
1134 | + attributes = {}, |
1135 | + terrain_affinity = terrain_affinity, |
1136 | + programs = { |
1137 | + program = { |
1138 | + "animate=idle 20000", |
1139 | + "remove=30", |
1140 | + "seed=aspen_summer_sapling", |
1141 | + "animate=idle 20000", |
1142 | + "remove=20", |
1143 | + "grow=aspen_summer_old", |
1144 | + }, |
1145 | + }, |
1146 | + animations = { |
1147 | + idle = { |
1148 | + pictures = path.list_directory(dirname .. "mature/", "idle_\\d+.png"), |
1149 | + hotspot = { 18, 47 }, |
1150 | + fps = 8, |
1151 | + }, |
1152 | + }, |
1153 | +} |
1154 | + |
1155 | +world:new_immovable_type{ |
1156 | + name = "aspen_summer_old", |
1157 | + descname = _ "Aspen (Old)", |
1158 | + editor_category = "trees_deciduous", |
1159 | + size = "small", |
1160 | + attributes = { "tree" }, |
1161 | + terrain_affinity = terrain_affinity, |
1162 | + programs = { |
1163 | + program = { |
1164 | + "animate=idle 1050000", |
1165 | + "transform=deadtree2 15", |
1166 | + "seed=aspen_summer_sapling", |
1167 | + }, |
1168 | + fall = { |
1169 | + "animate=falling 1200", |
1170 | + "transform=fallentree", |
1171 | + }, |
1172 | + }, |
1173 | + animations = { |
1174 | + idle = { |
1175 | + pictures = path.list_directory(dirname .. "old/", "idle_\\d+.png"), |
1176 | + hotspot = { 23, 58 }, |
1177 | + fps = 10, |
1178 | + sound_effect = { |
1179 | + directory = "sound/animals", |
1180 | + name = "bird1", |
1181 | + }, |
1182 | + }, |
1183 | + falling = { |
1184 | + pictures = path.list_directory(dirname .. "old/", "f_tree_\\d+.png"), |
1185 | + hotspot = { 20, 59 }, |
1186 | + fps = 10, |
1187 | + }, |
1188 | + }, |
1189 | +} |
1190 | |
1191 | === renamed directory 'world/immovables/trees/aspen_summer_mature' => 'world/immovables/trees/aspen/mature' |
1192 | === renamed directory 'world/immovables/trees/aspen_summer_old' => 'world/immovables/trees/aspen/old' |
1193 | === renamed directory 'world/immovables/trees/aspen_summer_pole' => 'world/immovables/trees/aspen/pole' |
1194 | === renamed directory 'world/immovables/trees/aspen_summer_sapling' => 'world/immovables/trees/aspen/sapling' |
1195 | === removed file 'world/immovables/trees/aspen_summer_mature/init.lua' |
1196 | --- world/immovables/trees/aspen_summer_mature/init.lua 2014-05-03 08:40:59 +0000 |
1197 | +++ world/immovables/trees/aspen_summer_mature/init.lua 1970-01-01 00:00:00 +0000 |
1198 | @@ -1,26 +0,0 @@ |
1199 | -dirname = path.dirname(__file__) |
1200 | - |
1201 | -world:new_immovable_type{ |
1202 | - name = "aspen_summer_mature", |
1203 | - descname = _ "Aspen (Mature)", |
1204 | - editor_category = "trees_deciduous", |
1205 | - size = "small", |
1206 | - attributes = {}, |
1207 | - programs = { |
1208 | - program = { |
1209 | - "animate=idle 20000", |
1210 | - "remove=30", |
1211 | - "seed=aspen_summer_sapling", |
1212 | - "animate=idle 20000", |
1213 | - "remove=20", |
1214 | - "grow=aspen_summer_old", |
1215 | - }, |
1216 | - }, |
1217 | - animations = { |
1218 | - idle = { |
1219 | - pictures = path.list_directory(dirname, "idle_\\d+.png"), |
1220 | - hotspot = { 18, 47 }, |
1221 | - fps = 8, |
1222 | - }, |
1223 | - }, |
1224 | -} |
1225 | |
1226 | === removed file 'world/immovables/trees/aspen_summer_old/init.lua' |
1227 | --- world/immovables/trees/aspen_summer_old/init.lua 2014-05-03 08:40:59 +0000 |
1228 | +++ world/immovables/trees/aspen_summer_old/init.lua 1970-01-01 00:00:00 +0000 |
1229 | @@ -1,36 +0,0 @@ |
1230 | -dirname = path.dirname(__file__) |
1231 | - |
1232 | -world:new_immovable_type{ |
1233 | - name = "aspen_summer_old", |
1234 | - descname = _ "Aspen (Old)", |
1235 | - editor_category = "trees_deciduous", |
1236 | - size = "small", |
1237 | - attributes = { "tree" }, |
1238 | - programs = { |
1239 | - program = { |
1240 | - "animate=idle 1050000", |
1241 | - "transform=deadtree2 15", |
1242 | - "seed=aspen_summer_sapling", |
1243 | - }, |
1244 | - fall = { |
1245 | - "animate=falling 1200", |
1246 | - "transform=fallentree", |
1247 | - }, |
1248 | - }, |
1249 | - animations = { |
1250 | - idle = { |
1251 | - pictures = path.list_directory(dirname, "idle_\\d+.png"), |
1252 | - hotspot = { 23, 58 }, |
1253 | - fps = 10, |
1254 | - sound_effect = { |
1255 | - directory = "sound/animals", |
1256 | - name = "bird1", |
1257 | - }, |
1258 | - }, |
1259 | - falling = { |
1260 | - pictures = path.list_directory(dirname, "f_tree_\\d+.png"), |
1261 | - hotspot = { 20, 59 }, |
1262 | - fps = 10, |
1263 | - }, |
1264 | - }, |
1265 | -} |
1266 | |
1267 | === removed file 'world/immovables/trees/aspen_summer_pole/init.lua' |
1268 | --- world/immovables/trees/aspen_summer_pole/init.lua 2014-05-03 08:40:59 +0000 |
1269 | +++ world/immovables/trees/aspen_summer_pole/init.lua 1970-01-01 00:00:00 +0000 |
1270 | @@ -1,23 +0,0 @@ |
1271 | -dirname = path.dirname(__file__) |
1272 | - |
1273 | -world:new_immovable_type{ |
1274 | - name = "aspen_summer_pole", |
1275 | - descname = _ "Aspen (Pole)", |
1276 | - editor_category = "trees_deciduous", |
1277 | - size = "small", |
1278 | - attributes = {}, |
1279 | - programs = { |
1280 | - program = { |
1281 | - "animate=idle 38000", |
1282 | - "remove=47", |
1283 | - "grow=aspen_summer_mature", |
1284 | - }, |
1285 | - }, |
1286 | - animations = { |
1287 | - idle = { |
1288 | - pictures = path.list_directory(dirname, "idle_\\d+.png"), |
1289 | - hotspot = { 12, 28 }, |
1290 | - fps = 8, |
1291 | - }, |
1292 | - }, |
1293 | -} |
1294 | |
1295 | === removed file 'world/immovables/trees/aspen_summer_sapling/init.lua' |
1296 | --- world/immovables/trees/aspen_summer_sapling/init.lua 2014-05-03 08:40:59 +0000 |
1297 | +++ world/immovables/trees/aspen_summer_sapling/init.lua 1970-01-01 00:00:00 +0000 |
1298 | @@ -1,23 +0,0 @@ |
1299 | -dirname = path.dirname(__file__) |
1300 | - |
1301 | -world:new_immovable_type{ |
1302 | - name = "aspen_summer_sapling", |
1303 | - descname = _ "Aspen (Sapling)", |
1304 | - editor_category = "trees_deciduous", |
1305 | - size = "small", |
1306 | - attributes = { "seed" }, |
1307 | - programs = { |
1308 | - program = { |
1309 | - "animate=idle 38000", |
1310 | - "remove=50", |
1311 | - "grow=aspen_summer_pole", |
1312 | - }, |
1313 | - }, |
1314 | - animations = { |
1315 | - idle = { |
1316 | - pictures = path.list_directory(dirname, "idle_\\d+.png"), |
1317 | - hotspot = { 5, 12 }, |
1318 | - fps = 8, |
1319 | - }, |
1320 | - }, |
1321 | -} |
1322 | |
1323 | === added directory 'world/immovables/trees/beech' |
1324 | === added file 'world/immovables/trees/beech/init.lua' |
1325 | --- world/immovables/trees/beech/init.lua 1970-01-01 00:00:00 +0000 |
1326 | +++ world/immovables/trees/beech/init.lua 2014-07-06 08:25:52 +0000 |
1327 | @@ -0,0 +1,107 @@ |
1328 | +dirname = path.dirname(__file__) |
1329 | + |
1330 | +terrain_affinity = { |
1331 | + preferred_temperature = 288, |
1332 | + preferred_humidity = 0.65, |
1333 | + preferred_fertility = 0.5, |
1334 | + pickiness = 0.6, |
1335 | +} |
1336 | + |
1337 | +world:new_immovable_type{ |
1338 | + name = "beech_summer_sapling", |
1339 | + descname = _ "Beech (Sapling)", |
1340 | + editor_category = "trees_deciduous", |
1341 | + size = "small", |
1342 | + attributes = { "tree_sapling" }, |
1343 | + terrain_affinity = terrain_affinity, |
1344 | + programs = { |
1345 | + program = { |
1346 | + "animate=idle 55000", |
1347 | + "remove=35", |
1348 | + "grow=beech_summer_pole", |
1349 | + }, |
1350 | + }, |
1351 | + animations = { |
1352 | + idle = { |
1353 | + pictures = path.list_directory(dirname .. "sapling/", "idle_\\d+.png"), |
1354 | + hotspot = { 5, 12 }, |
1355 | + fps = 8, |
1356 | + }, |
1357 | + }, |
1358 | +} |
1359 | + |
1360 | +world:new_immovable_type{ |
1361 | + name = "beech_summer_pole", |
1362 | + descname = _ "Beech (Pole)", |
1363 | + editor_category = "trees_deciduous", |
1364 | + size = "small", |
1365 | + attributes = {}, |
1366 | + terrain_affinity = terrain_affinity, |
1367 | + programs = { |
1368 | + program = { |
1369 | + "animate=idle 65000", |
1370 | + "remove=24", |
1371 | + "grow=beech_summer_mature", |
1372 | + }, |
1373 | + }, |
1374 | + animations = { |
1375 | + idle = { |
1376 | + pictures = path.list_directory(dirname .. "pole/", "idle_\\d+.png"), |
1377 | + hotspot = { 12, 28 }, |
1378 | + fps = 8, |
1379 | + }, |
1380 | + }, |
1381 | +} |
1382 | + |
1383 | +world:new_immovable_type{ |
1384 | + name = "beech_summer_mature", |
1385 | + descname = _ "Beech (Mature)", |
1386 | + editor_category = "trees_deciduous", |
1387 | + size = "small", |
1388 | + attributes = {}, |
1389 | + terrain_affinity = terrain_affinity, |
1390 | + programs = { |
1391 | + program = { |
1392 | + "animate=idle 72000", |
1393 | + "remove=19", |
1394 | + "grow=beech_summer_old", |
1395 | + }, |
1396 | + }, |
1397 | + animations = { |
1398 | + idle = { |
1399 | + pictures = path.list_directory(dirname .. "mature/", "idle_\\d+.png"), |
1400 | + hotspot = { 18, 48 }, |
1401 | + fps = 8, |
1402 | + }, |
1403 | + }, |
1404 | +} |
1405 | + |
1406 | +world:new_immovable_type{ |
1407 | + name = "beech_summer_old", |
1408 | + descname = _ "Beech (Old)", |
1409 | + editor_category = "trees_deciduous", |
1410 | + size = "small", |
1411 | + attributes = { "tree" }, |
1412 | + terrain_affinity = terrain_affinity, |
1413 | + programs = { |
1414 | + program = { |
1415 | + "animate=idle 1525000", |
1416 | + "transform=deadtree2 20", |
1417 | + "seed=beech_summer_sapling", |
1418 | + }, |
1419 | + fall = { |
1420 | + "remove=", |
1421 | + }, |
1422 | + }, |
1423 | + animations = { |
1424 | + idle = { |
1425 | + pictures = path.list_directory(dirname .. "old/", "idle_\\d+.png"), |
1426 | + hotspot = { 24, 60 }, |
1427 | + fps = 10, |
1428 | + sound_effect = { |
1429 | + directory = "sound/animals", |
1430 | + name = "bird6", |
1431 | + }, |
1432 | + }, |
1433 | + }, |
1434 | +} |
1435 | |
1436 | === renamed directory 'world/immovables/trees/beech_summer_mature' => 'world/immovables/trees/beech/mature' |
1437 | === renamed directory 'world/immovables/trees/beech_summer_old' => 'world/immovables/trees/beech/old' |
1438 | === renamed directory 'world/immovables/trees/beech_summer_pole' => 'world/immovables/trees/beech/pole' |
1439 | === renamed directory 'world/immovables/trees/beech_summer_sapling' => 'world/immovables/trees/beech/sapling' |
1440 | === removed file 'world/immovables/trees/beech_summer_mature/init.lua' |
1441 | --- world/immovables/trees/beech_summer_mature/init.lua 2014-05-03 08:40:59 +0000 |
1442 | +++ world/immovables/trees/beech_summer_mature/init.lua 1970-01-01 00:00:00 +0000 |
1443 | @@ -1,23 +0,0 @@ |
1444 | -dirname = path.dirname(__file__) |
1445 | - |
1446 | -world:new_immovable_type{ |
1447 | - name = "beech_summer_mature", |
1448 | - descname = _ "Beech (Mature)", |
1449 | - editor_category = "trees_deciduous", |
1450 | - size = "small", |
1451 | - attributes = {}, |
1452 | - programs = { |
1453 | - program = { |
1454 | - "animate=idle 72000", |
1455 | - "remove=19", |
1456 | - "grow=beech_summer_old", |
1457 | - }, |
1458 | - }, |
1459 | - animations = { |
1460 | - idle = { |
1461 | - pictures = path.list_directory(dirname, "idle_\\d+.png"), |
1462 | - hotspot = { 18, 48 }, |
1463 | - fps = 8, |
1464 | - }, |
1465 | - }, |
1466 | -} |
1467 | |
1468 | === removed file 'world/immovables/trees/beech_summer_old/init.lua' |
1469 | --- world/immovables/trees/beech_summer_old/init.lua 2014-05-03 08:40:59 +0000 |
1470 | +++ world/immovables/trees/beech_summer_old/init.lua 1970-01-01 00:00:00 +0000 |
1471 | @@ -1,30 +0,0 @@ |
1472 | -dirname = path.dirname(__file__) |
1473 | - |
1474 | -world:new_immovable_type{ |
1475 | - name = "beech_summer_old", |
1476 | - descname = _ "Beech (Old)", |
1477 | - editor_category = "trees_deciduous", |
1478 | - size = "small", |
1479 | - attributes = { "tree" }, |
1480 | - programs = { |
1481 | - program = { |
1482 | - "animate=idle 1525000", |
1483 | - "transform=deadtree2 20", |
1484 | - "seed=beech_summer_sapling", |
1485 | - }, |
1486 | - fall = { |
1487 | - "remove=", |
1488 | - }, |
1489 | - }, |
1490 | - animations = { |
1491 | - idle = { |
1492 | - pictures = path.list_directory(dirname, "idle_\\d+.png"), |
1493 | - hotspot = { 24, 60 }, |
1494 | - fps = 10, |
1495 | - sound_effect = { |
1496 | - directory = "sound/animals", |
1497 | - name = "bird6", |
1498 | - }, |
1499 | - }, |
1500 | - }, |
1501 | -} |
1502 | |
1503 | === removed file 'world/immovables/trees/beech_summer_pole/init.lua' |
1504 | --- world/immovables/trees/beech_summer_pole/init.lua 2014-05-03 08:40:59 +0000 |
1505 | +++ world/immovables/trees/beech_summer_pole/init.lua 1970-01-01 00:00:00 +0000 |
1506 | @@ -1,23 +0,0 @@ |
1507 | -dirname = path.dirname(__file__) |
1508 | - |
1509 | -world:new_immovable_type{ |
1510 | - name = "beech_summer_pole", |
1511 | - descname = _ "Beech (Pole)", |
1512 | - editor_category = "trees_deciduous", |
1513 | - size = "small", |
1514 | - attributes = {}, |
1515 | - programs = { |
1516 | - program = { |
1517 | - "animate=idle 65000", |
1518 | - "remove=24", |
1519 | - "grow=beech_summer_mature", |
1520 | - }, |
1521 | - }, |
1522 | - animations = { |
1523 | - idle = { |
1524 | - pictures = path.list_directory(dirname, "idle_\\d+.png"), |
1525 | - hotspot = { 12, 28 }, |
1526 | - fps = 8, |
1527 | - }, |
1528 | - }, |
1529 | -} |
1530 | |
1531 | === removed file 'world/immovables/trees/beech_summer_sapling/init.lua' |
1532 | --- world/immovables/trees/beech_summer_sapling/init.lua 2014-05-03 08:40:59 +0000 |
1533 | +++ world/immovables/trees/beech_summer_sapling/init.lua 1970-01-01 00:00:00 +0000 |
1534 | @@ -1,23 +0,0 @@ |
1535 | -dirname = path.dirname(__file__) |
1536 | - |
1537 | -world:new_immovable_type{ |
1538 | - name = "beech_summer_sapling", |
1539 | - descname = _ "Beech (Sapling)", |
1540 | - editor_category = "trees_deciduous", |
1541 | - size = "small", |
1542 | - attributes = { "seed" }, |
1543 | - programs = { |
1544 | - program = { |
1545 | - "animate=idle 55000", |
1546 | - "remove=35", |
1547 | - "grow=beech_summer_pole", |
1548 | - }, |
1549 | - }, |
1550 | - animations = { |
1551 | - idle = { |
1552 | - pictures = path.list_directory(dirname, "idle_\\d+.png"), |
1553 | - hotspot = { 5, 12 }, |
1554 | - fps = 8, |
1555 | - }, |
1556 | - }, |
1557 | -} |
1558 | |
1559 | === added directory 'world/immovables/trees/birch' |
1560 | === added file 'world/immovables/trees/birch/init.lua' |
1561 | --- world/immovables/trees/birch/init.lua 1970-01-01 00:00:00 +0000 |
1562 | +++ world/immovables/trees/birch/init.lua 2014-07-06 08:25:52 +0000 |
1563 | @@ -0,0 +1,110 @@ |
1564 | +dirname = path.dirname(__file__) |
1565 | + |
1566 | +terrain_affinity = { |
1567 | + preferred_temperature = 298, |
1568 | + preferred_humidity = 0.6, |
1569 | + preferred_fertility = 0.75, |
1570 | + pickiness = 0.2, |
1571 | +} |
1572 | + |
1573 | +world:new_immovable_type{ |
1574 | + name = "birch_summer_sapling", |
1575 | + descname = _ "Birch (Sapling)", |
1576 | + editor_category = "trees_deciduous", |
1577 | + size = "small", |
1578 | + attributes = { "tree_sapling" }, |
1579 | + terrain_affinity = terrain_affinity, |
1580 | + programs = { |
1581 | + program = { |
1582 | + "animate=idle 42000", |
1583 | + "remove=32", |
1584 | + "grow=birch_summer_pole", |
1585 | + }, |
1586 | + }, |
1587 | + animations = { |
1588 | + idle = { |
1589 | + pictures = path.list_directory(dirname .. "sapling/", "idle_\\d+.png"), |
1590 | + hotspot = { 5, 12 }, |
1591 | + fps = 8, |
1592 | + }, |
1593 | + }, |
1594 | +} |
1595 | + |
1596 | +world:new_immovable_type{ |
1597 | + name = "birch_summer_pole", |
1598 | + descname = _ "Birch (Pole)", |
1599 | + editor_category = "trees_deciduous", |
1600 | + size = "small", |
1601 | + attributes = {}, |
1602 | + terrain_affinity = terrain_affinity, |
1603 | + programs = { |
1604 | + program = { |
1605 | + "animate=idle 40000", |
1606 | + "remove=25", |
1607 | + "grow=birch_summer_mature", |
1608 | + }, |
1609 | + }, |
1610 | + animations = { |
1611 | + idle = { |
1612 | + pictures = path.list_directory(dirname .. "pole/", "idle_\\d+.png"), |
1613 | + hotspot = { 12, 28 }, |
1614 | + fps = 8, |
1615 | + }, |
1616 | + }, |
1617 | +} |
1618 | + |
1619 | +world:new_immovable_type{ |
1620 | + name = "birch_summer_mature", |
1621 | + descname = _ "Birch (Mature)", |
1622 | + editor_category = "trees_deciduous", |
1623 | + size = "small", |
1624 | + attributes = {}, |
1625 | + terrain_affinity = terrain_affinity, |
1626 | + programs = { |
1627 | + program = { |
1628 | + "animate=idle 25000", |
1629 | + "remove=10", |
1630 | + "seed=birch_summer_sapling", |
1631 | + "animate=idle 30000", |
1632 | + "remove=10", |
1633 | + "grow=birch_summer_old", |
1634 | + }, |
1635 | + }, |
1636 | + animations = { |
1637 | + idle = { |
1638 | + pictures = path.list_directory(dirname .. "mature/", "idle_\\d+.png"), |
1639 | + hotspot = { 18, 47 }, |
1640 | + fps = 8, |
1641 | + }, |
1642 | + }, |
1643 | +} |
1644 | + |
1645 | +world:new_immovable_type{ |
1646 | + name = "birch_summer_old", |
1647 | + descname = _ "Birch (Old)", |
1648 | + editor_category = "trees_deciduous", |
1649 | + size = "small", |
1650 | + attributes = { "tree" }, |
1651 | + terrain_affinity = terrain_affinity, |
1652 | + programs = { |
1653 | + program = { |
1654 | + "animate=idle 800000", |
1655 | + "transform=deadtree2 27", |
1656 | + "seed=birch_summer_sapling", |
1657 | + }, |
1658 | + fall = { |
1659 | + "remove=", |
1660 | + }, |
1661 | + }, |
1662 | + animations = { |
1663 | + idle = { |
1664 | + pictures = path.list_directory(dirname .. "old/", "idle_\\d+.png"), |
1665 | + hotspot = { 23, 58 }, |
1666 | + fps = 10, |
1667 | + sound_effect = { |
1668 | + directory = "sound/animals", |
1669 | + name = "bird5", |
1670 | + }, |
1671 | + }, |
1672 | + }, |
1673 | +} |
1674 | |
1675 | === renamed directory 'world/immovables/trees/birch_summer_mature' => 'world/immovables/trees/birch/mature' |
1676 | === renamed directory 'world/immovables/trees/birch_summer_old' => 'world/immovables/trees/birch/old' |
1677 | === renamed directory 'world/immovables/trees/birch_summer_pole' => 'world/immovables/trees/birch/pole' |
1678 | === renamed directory 'world/immovables/trees/birch_summer_sapling' => 'world/immovables/trees/birch/sapling' |
1679 | === removed file 'world/immovables/trees/birch_summer_mature/init.lua' |
1680 | --- world/immovables/trees/birch_summer_mature/init.lua 2014-05-03 08:40:59 +0000 |
1681 | +++ world/immovables/trees/birch_summer_mature/init.lua 1970-01-01 00:00:00 +0000 |
1682 | @@ -1,26 +0,0 @@ |
1683 | -dirname = path.dirname(__file__) |
1684 | - |
1685 | -world:new_immovable_type{ |
1686 | - name = "birch_summer_mature", |
1687 | - descname = _ "Birch (Mature)", |
1688 | - editor_category = "trees_deciduous", |
1689 | - size = "small", |
1690 | - attributes = {}, |
1691 | - programs = { |
1692 | - program = { |
1693 | - "animate=idle 25000", |
1694 | - "remove=10", |
1695 | - "seed=birch_summer_sapling", |
1696 | - "animate=idle 30000", |
1697 | - "remove=10", |
1698 | - "grow=birch_summer_old", |
1699 | - }, |
1700 | - }, |
1701 | - animations = { |
1702 | - idle = { |
1703 | - pictures = path.list_directory(dirname, "idle_\\d+.png"), |
1704 | - hotspot = { 18, 47 }, |
1705 | - fps = 8, |
1706 | - }, |
1707 | - }, |
1708 | -} |
1709 | |
1710 | === removed file 'world/immovables/trees/birch_summer_old/init.lua' |
1711 | --- world/immovables/trees/birch_summer_old/init.lua 2014-05-03 08:40:59 +0000 |
1712 | +++ world/immovables/trees/birch_summer_old/init.lua 1970-01-01 00:00:00 +0000 |
1713 | @@ -1,30 +0,0 @@ |
1714 | -dirname = path.dirname(__file__) |
1715 | - |
1716 | -world:new_immovable_type{ |
1717 | - name = "birch_summer_old", |
1718 | - descname = _ "Birch (Old)", |
1719 | - editor_category = "trees_deciduous", |
1720 | - size = "small", |
1721 | - attributes = { "tree" }, |
1722 | - programs = { |
1723 | - program = { |
1724 | - "animate=idle 800000", |
1725 | - "transform=deadtree2 27", |
1726 | - "seed=birch_summer_sapling", |
1727 | - }, |
1728 | - fall = { |
1729 | - "remove=", |
1730 | - }, |
1731 | - }, |
1732 | - animations = { |
1733 | - idle = { |
1734 | - pictures = path.list_directory(dirname, "idle_\\d+.png"), |
1735 | - hotspot = { 23, 58 }, |
1736 | - fps = 10, |
1737 | - sound_effect = { |
1738 | - directory = "sound/animals", |
1739 | - name = "bird5", |
1740 | - }, |
1741 | - }, |
1742 | - }, |
1743 | -} |
1744 | |
1745 | === removed file 'world/immovables/trees/birch_summer_pole/init.lua' |
1746 | --- world/immovables/trees/birch_summer_pole/init.lua 2014-05-03 08:40:59 +0000 |
1747 | +++ world/immovables/trees/birch_summer_pole/init.lua 1970-01-01 00:00:00 +0000 |
1748 | @@ -1,23 +0,0 @@ |
1749 | -dirname = path.dirname(__file__) |
1750 | - |
1751 | -world:new_immovable_type{ |
1752 | - name = "birch_summer_pole", |
1753 | - descname = _ "Birch (Pole)", |
1754 | - editor_category = "trees_deciduous", |
1755 | - size = "small", |
1756 | - attributes = {}, |
1757 | - programs = { |
1758 | - program = { |
1759 | - "animate=idle 40000", |
1760 | - "remove=25", |
1761 | - "grow=birch_summer_mature", |
1762 | - }, |
1763 | - }, |
1764 | - animations = { |
1765 | - idle = { |
1766 | - pictures = path.list_directory(dirname, "idle_\\d+.png"), |
1767 | - hotspot = { 12, 28 }, |
1768 | - fps = 8, |
1769 | - }, |
1770 | - }, |
1771 | -} |
1772 | |
1773 | === removed file 'world/immovables/trees/birch_summer_sapling/init.lua' |
1774 | --- world/immovables/trees/birch_summer_sapling/init.lua 2014-05-03 08:40:59 +0000 |
1775 | +++ world/immovables/trees/birch_summer_sapling/init.lua 1970-01-01 00:00:00 +0000 |
1776 | @@ -1,23 +0,0 @@ |
1777 | -dirname = path.dirname(__file__) |
1778 | - |
1779 | -world:new_immovable_type{ |
1780 | - name = "birch_summer_sapling", |
1781 | - descname = _ "Birch (Sapling)", |
1782 | - editor_category = "trees_deciduous", |
1783 | - size = "small", |
1784 | - attributes = { "seed" }, |
1785 | - programs = { |
1786 | - program = { |
1787 | - "animate=idle 42000", |
1788 | - "remove=32", |
1789 | - "grow=birch_summer_pole", |
1790 | - }, |
1791 | - }, |
1792 | - animations = { |
1793 | - idle = { |
1794 | - pictures = path.list_directory(dirname, "idle_\\d+.png"), |
1795 | - hotspot = { 5, 12 }, |
1796 | - fps = 8, |
1797 | - }, |
1798 | - }, |
1799 | -} |
1800 | |
1801 | === added directory 'world/immovables/trees/cirrus' |
1802 | === added file 'world/immovables/trees/cirrus/init.lua' |
1803 | --- world/immovables/trees/cirrus/init.lua 1970-01-01 00:00:00 +0000 |
1804 | +++ world/immovables/trees/cirrus/init.lua 2014-07-06 08:25:52 +0000 |
1805 | @@ -0,0 +1,103 @@ |
1806 | +dirname = path.dirname(__file__) |
1807 | + |
1808 | +terrain_affinity = { |
1809 | + preferred_temperature = 308, |
1810 | + preferred_humidity = 0.22, |
1811 | + preferred_fertility = 0.8, |
1812 | + pickiness = 0.5, |
1813 | +} |
1814 | + |
1815 | +world:new_immovable_type{ |
1816 | + name = "cirrus_wasteland_sapling", |
1817 | + descname = _ " Cirrus Tree (Sapling)", |
1818 | + editor_category = "trees_wasteland", |
1819 | + size = "small", |
1820 | + attributes = { "tree_sapling" }, |
1821 | + terrain_affinity = terrain_affinity, |
1822 | + programs = { |
1823 | + program = { |
1824 | + "animate=idle 61000", |
1825 | + "remove=44", |
1826 | + "grow=cirrus_wasteland_pole", |
1827 | + }, |
1828 | + }, |
1829 | + animations = { |
1830 | + idle = { |
1831 | + pictures = path.list_directory(dirname .. "sapling/", "idle_\\d+.png"), |
1832 | + hotspot = { 5, 12 }, |
1833 | + fps = 8, |
1834 | + }, |
1835 | + }, |
1836 | +} |
1837 | + |
1838 | +world:new_immovable_type{ |
1839 | + name = "cirrus_wasteland_pole", |
1840 | + descname = _ "Cirrus Tree (Pole)", |
1841 | + editor_category = "trees_wasteland", |
1842 | + size = "small", |
1843 | + attributes = {}, |
1844 | + terrain_affinity = terrain_affinity, |
1845 | + programs = { |
1846 | + program = { |
1847 | + "animate=idle 59000", |
1848 | + "remove=34", |
1849 | + "grow=cirrus_wasteland_mature", |
1850 | + }, |
1851 | + }, |
1852 | + animations = { |
1853 | + idle = { |
1854 | + pictures = path.list_directory(dirname .. "pole/", "idle_\\d+.png"), |
1855 | + hotspot = { 12, 28 }, |
1856 | + fps = 8, |
1857 | + }, |
1858 | + }, |
1859 | +} |
1860 | + |
1861 | +world:new_immovable_type{ |
1862 | + name = "cirrus_wasteland_mature", |
1863 | + descname = _ "Cirrus Tree (Mature)", |
1864 | + editor_category = "trees_wasteland", |
1865 | + size = "small", |
1866 | + attributes = {}, |
1867 | + terrain_affinity = terrain_affinity, |
1868 | + programs = { |
1869 | + program = { |
1870 | + "animate=idle 55000", |
1871 | + "remove=24", |
1872 | + "grow=cirrus_wasteland_old", |
1873 | + }, |
1874 | + }, |
1875 | + animations = { |
1876 | + idle = { |
1877 | + pictures = path.list_directory(dirname .. "mature/", "idle_\\d+.png"), |
1878 | + hotspot = { 18, 48 }, |
1879 | + fps = 8, |
1880 | + }, |
1881 | + }, |
1882 | +} |
1883 | + |
1884 | +world:new_immovable_type{ |
1885 | + name = "cirrus_wasteland_old", |
1886 | + descname = _ "Cirrus Tree (Old)", |
1887 | + editor_category = "trees_wasteland", |
1888 | + size = "small", |
1889 | + attributes = { "tree" }, |
1890 | + terrain_affinity = terrain_affinity, |
1891 | + programs = { |
1892 | + program = { |
1893 | + "animate=idle 1455000", |
1894 | + "transform=deadtree3 34", |
1895 | + "seed=cirrus_wasteland_sapling", |
1896 | + }, |
1897 | + fall = { |
1898 | + "remove=", |
1899 | + }, |
1900 | + }, |
1901 | + animations = { |
1902 | + idle = { |
1903 | + pictures = path.list_directory(dirname .. "old/", "idle_\\d+.png"), |
1904 | + hotspot = { 24, 60 }, |
1905 | + fps = 10, |
1906 | + }, |
1907 | + }, |
1908 | +} |
1909 | |
1910 | === renamed directory 'world/immovables/trees/cirrus_wasteland_mature' => 'world/immovables/trees/cirrus/mature' |
1911 | === renamed directory 'world/immovables/trees/cirrus_wasteland_old' => 'world/immovables/trees/cirrus/old' |
1912 | === renamed directory 'world/immovables/trees/cirrus_wasteland_pole' => 'world/immovables/trees/cirrus/pole' |
1913 | === renamed directory 'world/immovables/trees/cirrus_wasteland_sapling' => 'world/immovables/trees/cirrus/sapling' |
1914 | === removed file 'world/immovables/trees/cirrus_wasteland_mature/init.lua' |
1915 | --- world/immovables/trees/cirrus_wasteland_mature/init.lua 2014-06-14 14:33:44 +0000 |
1916 | +++ world/immovables/trees/cirrus_wasteland_mature/init.lua 1970-01-01 00:00:00 +0000 |
1917 | @@ -1,23 +0,0 @@ |
1918 | -dirname = path.dirname(__file__) |
1919 | - |
1920 | -world:new_immovable_type{ |
1921 | - name = "cirrus_wasteland_mature", |
1922 | - descname = _ "Cirrus Tree (Mature)", |
1923 | - editor_category = "trees_wasteland", |
1924 | - size = "small", |
1925 | - attributes = {}, |
1926 | - programs = { |
1927 | - program = { |
1928 | - "animate=idle 55000", |
1929 | - "remove=24", |
1930 | - "grow=cirrus_wasteland_old", |
1931 | - }, |
1932 | - }, |
1933 | - animations = { |
1934 | - idle = { |
1935 | - pictures = path.list_directory(dirname, "idle_\\d+.png"), |
1936 | - hotspot = { 18, 48 }, |
1937 | - fps = 8, |
1938 | - }, |
1939 | - }, |
1940 | -} |
1941 | |
1942 | === removed file 'world/immovables/trees/cirrus_wasteland_old/init.lua' |
1943 | --- world/immovables/trees/cirrus_wasteland_old/init.lua 2014-06-14 14:33:44 +0000 |
1944 | +++ world/immovables/trees/cirrus_wasteland_old/init.lua 1970-01-01 00:00:00 +0000 |
1945 | @@ -1,26 +0,0 @@ |
1946 | -dirname = path.dirname(__file__) |
1947 | - |
1948 | -world:new_immovable_type{ |
1949 | - name = "cirrus_wasteland_old", |
1950 | - descname = _ "Cirrus Tree (Old)", |
1951 | - editor_category = "trees_wasteland", |
1952 | - size = "small", |
1953 | - attributes = { "tree" }, |
1954 | - programs = { |
1955 | - program = { |
1956 | - "animate=idle 1455000", |
1957 | - "transform=deadtree3 34", |
1958 | - "seed=cirrus_wasteland_sapling", |
1959 | - }, |
1960 | - fall = { |
1961 | - "remove=", |
1962 | - }, |
1963 | - }, |
1964 | - animations = { |
1965 | - idle = { |
1966 | - pictures = path.list_directory(dirname, "idle_\\d+.png"), |
1967 | - hotspot = { 24, 60 }, |
1968 | - fps = 10, |
1969 | - }, |
1970 | - }, |
1971 | -} |
1972 | |
1973 | === removed file 'world/immovables/trees/cirrus_wasteland_pole/init.lua' |
1974 | --- world/immovables/trees/cirrus_wasteland_pole/init.lua 2014-06-14 14:33:44 +0000 |
1975 | +++ world/immovables/trees/cirrus_wasteland_pole/init.lua 1970-01-01 00:00:00 +0000 |
1976 | @@ -1,23 +0,0 @@ |
1977 | -dirname = path.dirname(__file__) |
1978 | - |
1979 | -world:new_immovable_type{ |
1980 | - name = "cirrus_wasteland_pole", |
1981 | - descname = _ "Cirrus Tree (Pole)", |
1982 | - editor_category = "trees_wasteland", |
1983 | - size = "small", |
1984 | - attributes = {}, |
1985 | - programs = { |
1986 | - program = { |
1987 | - "animate=idle 59000", |
1988 | - "remove=34", |
1989 | - "grow=cirrus_wasteland_mature", |
1990 | - }, |
1991 | - }, |
1992 | - animations = { |
1993 | - idle = { |
1994 | - pictures = path.list_directory(dirname, "idle_\\d+.png"), |
1995 | - hotspot = { 12, 28 }, |
1996 | - fps = 8, |
1997 | - }, |
1998 | - }, |
1999 | -} |
2000 | |
2001 | === removed file 'world/immovables/trees/cirrus_wasteland_sapling/init.lua' |
2002 | --- world/immovables/trees/cirrus_wasteland_sapling/init.lua 2014-06-14 14:33:44 +0000 |
2003 | +++ world/immovables/trees/cirrus_wasteland_sapling/init.lua 1970-01-01 00:00:00 +0000 |
2004 | @@ -1,23 +0,0 @@ |
2005 | -dirname = path.dirname(__file__) |
2006 | - |
2007 | -world:new_immovable_type{ |
2008 | - name = "cirrus_wasteland_sapling", |
2009 | - descname = _ " Cirrus Tree (Sapling)", |
2010 | - editor_category = "trees_wasteland", |
2011 | - size = "small", |
2012 | - attributes = { "seed" }, |
2013 | - programs = { |
2014 | - program = { |
2015 | - "animate=idle 61000", |
2016 | - "remove=44", |
2017 | - "grow=cirrus_wasteland_pole", |
2018 | - }, |
2019 | - }, |
2020 | - animations = { |
2021 | - idle = { |
2022 | - pictures = path.list_directory(dirname, "idle_\\d+.png"), |
2023 | - hotspot = { 5, 12 }, |
2024 | - fps = 8, |
2025 | - }, |
2026 | - }, |
2027 | -} |
2028 | |
2029 | === added directory 'world/immovables/trees/larch' |
2030 | === added file 'world/immovables/trees/larch/init.lua' |
2031 | --- world/immovables/trees/larch/init.lua 1970-01-01 00:00:00 +0000 |
2032 | +++ world/immovables/trees/larch/init.lua 2014-07-06 08:25:52 +0000 |
2033 | @@ -0,0 +1,107 @@ |
2034 | +dirname = path.dirname(__file__) |
2035 | + |
2036 | +terrain_affinity = { |
2037 | + preferred_temperature = 283, |
2038 | + preferred_humidity = 0.6, |
2039 | + preferred_fertility = 0.5, |
2040 | + pickiness = 0, |
2041 | +} |
2042 | + |
2043 | +world:new_immovable_type{ |
2044 | + name = "larch_summer_sapling", |
2045 | + descname = _ "Larch (Sapling)", |
2046 | + editor_category = "trees_coniferous", |
2047 | + size = "small", |
2048 | + attributes = { "tree_sapling" }, |
2049 | + terrain_affinity = terrain_affinity, |
2050 | + programs = { |
2051 | + program = { |
2052 | + "animate=idle 60000", |
2053 | + "remove=44", |
2054 | + "grow=larch_summer_pole", |
2055 | + }, |
2056 | + }, |
2057 | + animations = { |
2058 | + idle = { |
2059 | + pictures = path.list_directory(dirname .. "sapling/", "idle_\\d+.png"), |
2060 | + hotspot = { 4, 12 }, |
2061 | + fps = 8, |
2062 | + }, |
2063 | + }, |
2064 | +} |
2065 | + |
2066 | +world:new_immovable_type{ |
2067 | + name = "larch_summer_pole", |
2068 | + descname = _ "Larch (Pole)", |
2069 | + editor_category = "trees_coniferous", |
2070 | + size = "small", |
2071 | + attributes = {}, |
2072 | + terrain_affinity = terrain_affinity, |
2073 | + programs = { |
2074 | + program = { |
2075 | + "animate=idle 60000", |
2076 | + "remove=34", |
2077 | + "grow=larch_summer_mature", |
2078 | + }, |
2079 | + }, |
2080 | + animations = { |
2081 | + idle = { |
2082 | + pictures = path.list_directory(dirname .. "pole/", "idle_\\d+.png"), |
2083 | + hotspot = { 9, 28 }, |
2084 | + fps = 8, |
2085 | + }, |
2086 | + }, |
2087 | +} |
2088 | + |
2089 | +world:new_immovable_type{ |
2090 | + name = "larch_summer_mature", |
2091 | + descname = _ "Larch (Mature)", |
2092 | + editor_category = "trees_coniferous", |
2093 | + size = "small", |
2094 | + attributes = {}, |
2095 | + terrain_affinity = terrain_affinity, |
2096 | + programs = { |
2097 | + program = { |
2098 | + "animate=idle 55000", |
2099 | + "remove=24", |
2100 | + "grow=larch_summer_old", |
2101 | + }, |
2102 | + }, |
2103 | + animations = { |
2104 | + idle = { |
2105 | + pictures = path.list_directory(dirname .. "mature/", "idle_\\d+.png"), |
2106 | + hotspot = { 12, 48 }, |
2107 | + fps = 8, |
2108 | + }, |
2109 | + }, |
2110 | +} |
2111 | + |
2112 | +world:new_immovable_type{ |
2113 | + name = "larch_summer_old", |
2114 | + descname = _ "Larch (Old)", |
2115 | + editor_category = "trees_coniferous", |
2116 | + size = "small", |
2117 | + attributes = { "tree" }, |
2118 | + terrain_affinity = terrain_affinity, |
2119 | + programs = { |
2120 | + program = { |
2121 | + "animate=idle 1455000", |
2122 | + "transform=deadtree3 23", |
2123 | + "seed=larch_summer_sapling", |
2124 | + }, |
2125 | + fall = { |
2126 | + "remove=", |
2127 | + }, |
2128 | + }, |
2129 | + animations = { |
2130 | + idle = { |
2131 | + pictures = path.list_directory(dirname .. "old/", "idle_\\d+.png"), |
2132 | + hotspot = { 15, 59 }, |
2133 | + fps = 10, |
2134 | + sound_effect = { |
2135 | + directory = "sound/animals", |
2136 | + name = "bird6", |
2137 | + }, |
2138 | + }, |
2139 | + }, |
2140 | +} |
2141 | |
2142 | === renamed directory 'world/immovables/trees/larch_summer_mature' => 'world/immovables/trees/larch/mature' |
2143 | === renamed directory 'world/immovables/trees/larch_summer_old' => 'world/immovables/trees/larch/old' |
2144 | === renamed directory 'world/immovables/trees/larch_summer_pole' => 'world/immovables/trees/larch/pole' |
2145 | === renamed directory 'world/immovables/trees/larch_summer_sapling' => 'world/immovables/trees/larch/sapling' |
2146 | === removed file 'world/immovables/trees/larch_summer_mature/init.lua' |
2147 | --- world/immovables/trees/larch_summer_mature/init.lua 2014-05-03 08:40:59 +0000 |
2148 | +++ world/immovables/trees/larch_summer_mature/init.lua 1970-01-01 00:00:00 +0000 |
2149 | @@ -1,23 +0,0 @@ |
2150 | -dirname = path.dirname(__file__) |
2151 | - |
2152 | -world:new_immovable_type{ |
2153 | - name = "larch_summer_mature", |
2154 | - descname = _ "Larch (Mature)", |
2155 | - editor_category = "trees_coniferous", |
2156 | - size = "small", |
2157 | - attributes = {}, |
2158 | - programs = { |
2159 | - program = { |
2160 | - "animate=idle 55000", |
2161 | - "remove=24", |
2162 | - "grow=larch_summer_old", |
2163 | - }, |
2164 | - }, |
2165 | - animations = { |
2166 | - idle = { |
2167 | - pictures = path.list_directory(dirname, "idle_\\d+.png"), |
2168 | - hotspot = { 12, 48 }, |
2169 | - fps = 8, |
2170 | - }, |
2171 | - }, |
2172 | -} |
2173 | |
2174 | === removed file 'world/immovables/trees/larch_summer_old/init.lua' |
2175 | --- world/immovables/trees/larch_summer_old/init.lua 2014-05-03 08:40:59 +0000 |
2176 | +++ world/immovables/trees/larch_summer_old/init.lua 1970-01-01 00:00:00 +0000 |
2177 | @@ -1,30 +0,0 @@ |
2178 | -dirname = path.dirname(__file__) |
2179 | - |
2180 | -world:new_immovable_type{ |
2181 | - name = "larch_summer_old", |
2182 | - descname = _ "Larch (Old)", |
2183 | - editor_category = "trees_coniferous", |
2184 | - size = "small", |
2185 | - attributes = { "tree" }, |
2186 | - programs = { |
2187 | - program = { |
2188 | - "animate=idle 1455000", |
2189 | - "transform=deadtree3 23", |
2190 | - "seed=larch_summer_sapling", |
2191 | - }, |
2192 | - fall = { |
2193 | - "remove=", |
2194 | - }, |
2195 | - }, |
2196 | - animations = { |
2197 | - idle = { |
2198 | - pictures = path.list_directory(dirname, "idle_\\d+.png"), |
2199 | - hotspot = { 15, 59 }, |
2200 | - fps = 10, |
2201 | - sound_effect = { |
2202 | - directory = "sound/animals", |
2203 | - name = "bird6", |
2204 | - }, |
2205 | - }, |
2206 | - }, |
2207 | -} |
2208 | |
2209 | === removed file 'world/immovables/trees/larch_summer_pole/init.lua' |
2210 | --- world/immovables/trees/larch_summer_pole/init.lua 2014-05-03 08:40:59 +0000 |
2211 | +++ world/immovables/trees/larch_summer_pole/init.lua 1970-01-01 00:00:00 +0000 |
2212 | @@ -1,23 +0,0 @@ |
2213 | -dirname = path.dirname(__file__) |
2214 | - |
2215 | -world:new_immovable_type{ |
2216 | - name = "larch_summer_pole", |
2217 | - descname = _ "Larch (Pole)", |
2218 | - editor_category = "trees_coniferous", |
2219 | - size = "small", |
2220 | - attributes = {}, |
2221 | - programs = { |
2222 | - program = { |
2223 | - "animate=idle 60000", |
2224 | - "remove=34", |
2225 | - "grow=larch_summer_mature", |
2226 | - }, |
2227 | - }, |
2228 | - animations = { |
2229 | - idle = { |
2230 | - pictures = path.list_directory(dirname, "idle_\\d+.png"), |
2231 | - hotspot = { 9, 28 }, |
2232 | - fps = 8, |
2233 | - }, |
2234 | - }, |
2235 | -} |
2236 | |
2237 | === removed file 'world/immovables/trees/larch_summer_sapling/init.lua' |
2238 | --- world/immovables/trees/larch_summer_sapling/init.lua 2014-05-03 08:40:59 +0000 |
2239 | +++ world/immovables/trees/larch_summer_sapling/init.lua 1970-01-01 00:00:00 +0000 |
2240 | @@ -1,23 +0,0 @@ |
2241 | -dirname = path.dirname(__file__) |
2242 | - |
2243 | -world:new_immovable_type{ |
2244 | - name = "larch_summer_sapling", |
2245 | - descname = _ "Larch (Sapling)", |
2246 | - editor_category = "trees_coniferous", |
2247 | - size = "small", |
2248 | - attributes = { "seed" }, |
2249 | - programs = { |
2250 | - program = { |
2251 | - "animate=idle 60000", |
2252 | - "remove=44", |
2253 | - "grow=larch_summer_pole", |
2254 | - }, |
2255 | - }, |
2256 | - animations = { |
2257 | - idle = { |
2258 | - pictures = path.list_directory(dirname, "idle_\\d+.png"), |
2259 | - hotspot = { 4, 12 }, |
2260 | - fps = 8, |
2261 | - }, |
2262 | - }, |
2263 | -} |
2264 | |
2265 | === added directory 'world/immovables/trees/liana' |
2266 | === added file 'world/immovables/trees/liana/init.lua' |
2267 | --- world/immovables/trees/liana/init.lua 1970-01-01 00:00:00 +0000 |
2268 | +++ world/immovables/trees/liana/init.lua 2014-07-06 08:25:52 +0000 |
2269 | @@ -0,0 +1,106 @@ |
2270 | +dirname = path.dirname(__file__) |
2271 | + |
2272 | +terrain_affinity = { |
2273 | + preferred_temperature = 308, |
2274 | + preferred_humidity = 0.24, |
2275 | + preferred_fertility = 0.8, |
2276 | + pickiness = 0.5, |
2277 | +} |
2278 | + |
2279 | +world:new_immovable_type{ |
2280 | + name = "liana_wasteland_sapling", |
2281 | + descname = _ "Liana Tree (Sapling)", |
2282 | + editor_category = "trees_wasteland", |
2283 | + size = "small", |
2284 | + attributes = { "tree_sapling" }, |
2285 | + terrain_affinity = terrain_affinity, |
2286 | + programs = { |
2287 | + program = { |
2288 | + "animate=idle 60000", |
2289 | + "remove=40", |
2290 | + "grow=liana_wasteland_pole", |
2291 | + }, |
2292 | + }, |
2293 | + animations = { |
2294 | + idle = { |
2295 | + pictures = path.list_directory(dirname .. "sapling/", "idle_\\d+.png"), |
2296 | + hotspot = { 5, 12 }, |
2297 | + fps = 8, |
2298 | + }, |
2299 | + }, |
2300 | +} |
2301 | + |
2302 | +world:new_immovable_type{ |
2303 | + name = "liana_wasteland_pole", |
2304 | + descname = _ "Liana Tree (Pole)", |
2305 | + editor_category = "trees_wasteland", |
2306 | + size = "small", |
2307 | + attributes = {}, |
2308 | + terrain_affinity = terrain_affinity, |
2309 | + programs = { |
2310 | + program = { |
2311 | + "animate=idle 55000", |
2312 | + "remove=30", |
2313 | + "grow=liana_wasteland_mature", |
2314 | + }, |
2315 | + }, |
2316 | + animations = { |
2317 | + idle = { |
2318 | + pictures = path.list_directory(dirname .. "pole/", "idle_\\d+.png"), |
2319 | + hotspot = { 12, 28 }, |
2320 | + fps = 8, |
2321 | + }, |
2322 | + }, |
2323 | +} |
2324 | + |
2325 | +world:new_immovable_type{ |
2326 | + name = "liana_wasteland_mature", |
2327 | + descname = _ "Liana Tree (Mature)", |
2328 | + editor_category = "trees_wasteland", |
2329 | + size = "small", |
2330 | + attributes = {}, |
2331 | + terrain_affinity = terrain_affinity, |
2332 | + programs = { |
2333 | + program = { |
2334 | + "animate=idle 55000", |
2335 | + "remove=10", |
2336 | + "seed=liana_wasteland_sapling", |
2337 | + "animate=idle 30000", |
2338 | + "remove=10", |
2339 | + "grow=liana_wasteland_old", |
2340 | + }, |
2341 | + }, |
2342 | + animations = { |
2343 | + idle = { |
2344 | + pictures = path.list_directory(dirname .. "mature/", "idle_\\d+.png"), |
2345 | + hotspot = { 18, 48 }, |
2346 | + fps = 8, |
2347 | + }, |
2348 | + }, |
2349 | +} |
2350 | + |
2351 | +world:new_immovable_type{ |
2352 | + name = "liana_wasteland_old", |
2353 | + descname = _ "Liana Tree (Old)", |
2354 | + editor_category = "trees_wasteland", |
2355 | + size = "small", |
2356 | + attributes = { "tree" }, |
2357 | + terrain_affinity = terrain_affinity, |
2358 | + programs = { |
2359 | + program = { |
2360 | + "animate=idle 1455000", |
2361 | + "transform=deadtree4 48", |
2362 | + "seed=liana_wasteland_sapling", |
2363 | + }, |
2364 | + fall = { |
2365 | + "remove=", |
2366 | + }, |
2367 | + }, |
2368 | + animations = { |
2369 | + idle = { |
2370 | + pictures = path.list_directory(dirname .. "old/", "idle_\\d+.png"), |
2371 | + hotspot = { 24, 60 }, |
2372 | + fps = 10, |
2373 | + }, |
2374 | + }, |
2375 | +} |
2376 | |
2377 | === renamed directory 'world/immovables/trees/liana_wasteland_mature' => 'world/immovables/trees/liana/mature' |
2378 | === renamed directory 'world/immovables/trees/liana_wasteland_old' => 'world/immovables/trees/liana/old' |
2379 | === renamed directory 'world/immovables/trees/liana_wasteland_pole' => 'world/immovables/trees/liana/pole' |
2380 | === renamed directory 'world/immovables/trees/liana_wasteland_sapling' => 'world/immovables/trees/liana/sapling' |
2381 | === removed file 'world/immovables/trees/liana_wasteland_mature/init.lua' |
2382 | --- world/immovables/trees/liana_wasteland_mature/init.lua 2014-06-14 14:33:44 +0000 |
2383 | +++ world/immovables/trees/liana_wasteland_mature/init.lua 1970-01-01 00:00:00 +0000 |
2384 | @@ -1,26 +0,0 @@ |
2385 | -dirname = path.dirname(__file__) |
2386 | - |
2387 | -world:new_immovable_type{ |
2388 | - name = "liana_wasteland_mature", |
2389 | - descname = _ "Liana Tree (Mature)", |
2390 | - editor_category = "trees_wasteland", |
2391 | - size = "small", |
2392 | - attributes = {}, |
2393 | - programs = { |
2394 | - program = { |
2395 | - "animate=idle 55000", |
2396 | - "remove=10", |
2397 | - "seed=liana_wasteland_sapling", |
2398 | - "animate=idle 30000", |
2399 | - "remove=10", |
2400 | - "grow=liana_wasteland_old", |
2401 | - }, |
2402 | - }, |
2403 | - animations = { |
2404 | - idle = { |
2405 | - pictures = path.list_directory(dirname, "idle_\\d+.png"), |
2406 | - hotspot = { 18, 48 }, |
2407 | - fps = 8, |
2408 | - }, |
2409 | - }, |
2410 | -} |
2411 | |
2412 | === removed file 'world/immovables/trees/liana_wasteland_old/init.lua' |
2413 | --- world/immovables/trees/liana_wasteland_old/init.lua 2014-06-14 14:33:44 +0000 |
2414 | +++ world/immovables/trees/liana_wasteland_old/init.lua 1970-01-01 00:00:00 +0000 |
2415 | @@ -1,26 +0,0 @@ |
2416 | -dirname = path.dirname(__file__) |
2417 | - |
2418 | -world:new_immovable_type{ |
2419 | - name = "liana_wasteland_old", |
2420 | - descname = _ "Liana Tree (Old)", |
2421 | - editor_category = "trees_wasteland", |
2422 | - size = "small", |
2423 | - attributes = { "tree" }, |
2424 | - programs = { |
2425 | - program = { |
2426 | - "animate=idle 1455000", |
2427 | - "transform=deadtree4 48", |
2428 | - "seed=liana_wasteland_sapling", |
2429 | - }, |
2430 | - fall = { |
2431 | - "remove=", |
2432 | - }, |
2433 | - }, |
2434 | - animations = { |
2435 | - idle = { |
2436 | - pictures = path.list_directory(dirname, "idle_\\d+.png"), |
2437 | - hotspot = { 24, 60 }, |
2438 | - fps = 10, |
2439 | - }, |
2440 | - }, |
2441 | -} |
2442 | |
2443 | === removed file 'world/immovables/trees/liana_wasteland_pole/init.lua' |
2444 | --- world/immovables/trees/liana_wasteland_pole/init.lua 2014-06-14 14:33:44 +0000 |
2445 | +++ world/immovables/trees/liana_wasteland_pole/init.lua 1970-01-01 00:00:00 +0000 |
2446 | @@ -1,23 +0,0 @@ |
2447 | -dirname = path.dirname(__file__) |
2448 | - |
2449 | -world:new_immovable_type{ |
2450 | - name = "liana_wasteland_pole", |
2451 | - descname = _ "Liana Tree (Pole)", |
2452 | - editor_category = "trees_wasteland", |
2453 | - size = "small", |
2454 | - attributes = {}, |
2455 | - programs = { |
2456 | - program = { |
2457 | - "animate=idle 55000", |
2458 | - "remove=30", |
2459 | - "grow=liana_wasteland_mature", |
2460 | - }, |
2461 | - }, |
2462 | - animations = { |
2463 | - idle = { |
2464 | - pictures = path.list_directory(dirname, "idle_\\d+.png"), |
2465 | - hotspot = { 12, 28 }, |
2466 | - fps = 8, |
2467 | - }, |
2468 | - }, |
2469 | -} |
2470 | |
2471 | === removed file 'world/immovables/trees/liana_wasteland_sapling/init.lua' |
2472 | --- world/immovables/trees/liana_wasteland_sapling/init.lua 2014-06-14 14:33:44 +0000 |
2473 | +++ world/immovables/trees/liana_wasteland_sapling/init.lua 1970-01-01 00:00:00 +0000 |
2474 | @@ -1,23 +0,0 @@ |
2475 | -dirname = path.dirname(__file__) |
2476 | - |
2477 | -world:new_immovable_type{ |
2478 | - name = "liana_wasteland_sapling", |
2479 | - descname = _ "Liana Tree (Sapling)", |
2480 | - editor_category = "trees_wasteland", |
2481 | - size = "small", |
2482 | - attributes = { "seed" }, |
2483 | - programs = { |
2484 | - program = { |
2485 | - "animate=idle 60000", |
2486 | - "remove=40", |
2487 | - "grow=liana_wasteland_pole", |
2488 | - }, |
2489 | - }, |
2490 | - animations = { |
2491 | - idle = { |
2492 | - pictures = path.list_directory(dirname, "idle_\\d+.png"), |
2493 | - hotspot = { 5, 12 }, |
2494 | - fps = 8, |
2495 | - }, |
2496 | - }, |
2497 | -} |
2498 | |
2499 | === added directory 'world/immovables/trees/maple' |
2500 | === added file 'world/immovables/trees/maple/init.lua' |
2501 | --- world/immovables/trees/maple/init.lua 1970-01-01 00:00:00 +0000 |
2502 | +++ world/immovables/trees/maple/init.lua 2014-07-06 08:25:52 +0000 |
2503 | @@ -0,0 +1,107 @@ |
2504 | +dirname = path.dirname(__file__) |
2505 | + |
2506 | +terrain_affinity = { |
2507 | + preferred_temperature = 293, |
2508 | + preferred_humidity = 0.6, |
2509 | + preferred_fertility = 0.45, |
2510 | + pickiness = 0.5, |
2511 | +} |
2512 | + |
2513 | +world:new_immovable_type{ |
2514 | + name = "maple_winter_sapling", |
2515 | + descname = _ "Maple (Sapling)", |
2516 | + editor_category = "trees_deciduous", |
2517 | + size = "small", |
2518 | + attributes = { "tree_sapling" }, |
2519 | + terrain_affinity = terrain_affinity, |
2520 | + programs = { |
2521 | + program = { |
2522 | + "animate=idle 57500", |
2523 | + "remove=21", |
2524 | + "grow=maple_winter_pole", |
2525 | + }, |
2526 | + }, |
2527 | + animations = { |
2528 | + idle = { |
2529 | + pictures = path.list_directory(dirname .. "sapling/", "idle_\\d+.png"), |
2530 | + hotspot = { 5, 12 }, |
2531 | + fps = 8, |
2532 | + }, |
2533 | + }, |
2534 | +} |
2535 | + |
2536 | +world:new_immovable_type{ |
2537 | + name = "maple_winter_pole", |
2538 | + descname = _ "Maple (Pole)", |
2539 | + editor_category = "trees_deciduous", |
2540 | + size = "small", |
2541 | + attributes = {}, |
2542 | + terrain_affinity = terrain_affinity, |
2543 | + programs = { |
2544 | + program = { |
2545 | + "animate=idle 52500", |
2546 | + "remove=19", |
2547 | + "grow=maple_winter_mature", |
2548 | + }, |
2549 | + }, |
2550 | + animations = { |
2551 | + idle = { |
2552 | + pictures = path.list_directory(dirname .. "pole/", "idle_\\d+.png"), |
2553 | + hotspot = { 12, 28 }, |
2554 | + fps = 8, |
2555 | + }, |
2556 | + }, |
2557 | +} |
2558 | + |
2559 | +world:new_immovable_type{ |
2560 | + name = "maple_winter_mature", |
2561 | + descname = _ "Maple (Mature)", |
2562 | + editor_category = "trees_deciduous", |
2563 | + size = "small", |
2564 | + attributes = {}, |
2565 | + terrain_affinity = terrain_affinity, |
2566 | + programs = { |
2567 | + program = { |
2568 | + "animate=idle 50000", |
2569 | + "remove=18", |
2570 | + "grow=maple_winter_old", |
2571 | + }, |
2572 | + }, |
2573 | + animations = { |
2574 | + idle = { |
2575 | + pictures = path.list_directory(dirname .. "mature/", "idle_\\d+.png"), |
2576 | + hotspot = { 18, 48 }, |
2577 | + fps = 8, |
2578 | + }, |
2579 | + }, |
2580 | +} |
2581 | + |
2582 | +world:new_immovable_type{ |
2583 | + name = "maple_winter_old", |
2584 | + descname = _ "Maple (Old)", |
2585 | + editor_category = "trees_deciduous", |
2586 | + size = "small", |
2587 | + attributes = { "tree" }, |
2588 | + terrain_affinity = terrain_affinity, |
2589 | + programs = { |
2590 | + program = { |
2591 | + "animate=idle 1550000", |
2592 | + "transform=deadtree4 39", |
2593 | + "seed=maple_winter_sapling", |
2594 | + }, |
2595 | + fall = { |
2596 | + "remove=", |
2597 | + }, |
2598 | + }, |
2599 | + animations = { |
2600 | + idle = { |
2601 | + pictures = path.list_directory(dirname .. "old/", "idle_\\d+.png"), |
2602 | + hotspot = { 23, 59 }, |
2603 | + fps = 10, |
2604 | + sound_effect = { |
2605 | + directory = "sound/animals", |
2606 | + name = "bird4", |
2607 | + }, |
2608 | + }, |
2609 | + }, |
2610 | +} |
2611 | |
2612 | === renamed directory 'world/immovables/trees/maple_winter_mature' => 'world/immovables/trees/maple/mature' |
2613 | === renamed directory 'world/immovables/trees/maple_winter_old' => 'world/immovables/trees/maple/old' |
2614 | === renamed directory 'world/immovables/trees/maple_winter_pole' => 'world/immovables/trees/maple/pole' |
2615 | === renamed directory 'world/immovables/trees/maple_winter_sapling' => 'world/immovables/trees/maple/sapling' |
2616 | === removed file 'world/immovables/trees/maple_winter_mature/init.lua' |
2617 | --- world/immovables/trees/maple_winter_mature/init.lua 2014-05-03 08:40:59 +0000 |
2618 | +++ world/immovables/trees/maple_winter_mature/init.lua 1970-01-01 00:00:00 +0000 |
2619 | @@ -1,23 +0,0 @@ |
2620 | -dirname = path.dirname(__file__) |
2621 | - |
2622 | -world:new_immovable_type{ |
2623 | - name = "maple_winter_mature", |
2624 | - descname = _ "Maple (Mature)", |
2625 | - editor_category = "trees_deciduous", |
2626 | - size = "small", |
2627 | - attributes = {}, |
2628 | - programs = { |
2629 | - program = { |
2630 | - "animate=idle 50000", |
2631 | - "remove=18", |
2632 | - "grow=maple_winter_old", |
2633 | - }, |
2634 | - }, |
2635 | - animations = { |
2636 | - idle = { |
2637 | - pictures = path.list_directory(dirname, "idle_\\d+.png"), |
2638 | - hotspot = { 18, 48 }, |
2639 | - fps = 8, |
2640 | - }, |
2641 | - }, |
2642 | -} |
2643 | |
2644 | === removed file 'world/immovables/trees/maple_winter_old/init.lua' |
2645 | --- world/immovables/trees/maple_winter_old/init.lua 2014-05-03 08:40:59 +0000 |
2646 | +++ world/immovables/trees/maple_winter_old/init.lua 1970-01-01 00:00:00 +0000 |
2647 | @@ -1,30 +0,0 @@ |
2648 | -dirname = path.dirname(__file__) |
2649 | - |
2650 | -world:new_immovable_type{ |
2651 | - name = "maple_winter_old", |
2652 | - descname = _ "Maple (Old)", |
2653 | - editor_category = "trees_deciduous", |
2654 | - size = "small", |
2655 | - attributes = { "tree" }, |
2656 | - programs = { |
2657 | - program = { |
2658 | - "animate=idle 1550000", |
2659 | - "transform=deadtree4 39", |
2660 | - "seed=maple_winter_sapling", |
2661 | - }, |
2662 | - fall = { |
2663 | - "remove=", |
2664 | - }, |
2665 | - }, |
2666 | - animations = { |
2667 | - idle = { |
2668 | - pictures = path.list_directory(dirname, "idle_\\d+.png"), |
2669 | - hotspot = { 23, 59 }, |
2670 | - fps = 10, |
2671 | - sound_effect = { |
2672 | - directory = "sound/animals", |
2673 | - name = "bird4", |
2674 | - }, |
2675 | - }, |
2676 | - }, |
2677 | -} |
2678 | |
2679 | === removed file 'world/immovables/trees/maple_winter_pole/init.lua' |
2680 | --- world/immovables/trees/maple_winter_pole/init.lua 2014-05-03 08:40:59 +0000 |
2681 | +++ world/immovables/trees/maple_winter_pole/init.lua 1970-01-01 00:00:00 +0000 |
2682 | @@ -1,23 +0,0 @@ |
2683 | -dirname = path.dirname(__file__) |
2684 | - |
2685 | -world:new_immovable_type{ |
2686 | - name = "maple_winter_pole", |
2687 | - descname = _ "Maple (Pole)", |
2688 | - editor_category = "trees_deciduous", |
2689 | - size = "small", |
2690 | - attributes = {}, |
2691 | - programs = { |
2692 | - program = { |
2693 | - "animate=idle 52500", |
2694 | - "remove=19", |
2695 | - "grow=maple_winter_mature", |
2696 | - }, |
2697 | - }, |
2698 | - animations = { |
2699 | - idle = { |
2700 | - pictures = path.list_directory(dirname, "idle_\\d+.png"), |
2701 | - hotspot = { 12, 28 }, |
2702 | - fps = 8, |
2703 | - }, |
2704 | - }, |
2705 | -} |
2706 | |
2707 | === removed file 'world/immovables/trees/maple_winter_sapling/init.lua' |
2708 | --- world/immovables/trees/maple_winter_sapling/init.lua 2014-05-03 08:40:59 +0000 |
2709 | +++ world/immovables/trees/maple_winter_sapling/init.lua 1970-01-01 00:00:00 +0000 |
2710 | @@ -1,23 +0,0 @@ |
2711 | -dirname = path.dirname(__file__) |
2712 | - |
2713 | -world:new_immovable_type{ |
2714 | - name = "maple_winter_sapling", |
2715 | - descname = _ "Maple (Sapling)", |
2716 | - editor_category = "trees_deciduous", |
2717 | - size = "small", |
2718 | - attributes = { "seed" }, |
2719 | - programs = { |
2720 | - program = { |
2721 | - "animate=idle 57500", |
2722 | - "remove=21", |
2723 | - "grow=maple_winter_pole", |
2724 | - }, |
2725 | - }, |
2726 | - animations = { |
2727 | - idle = { |
2728 | - pictures = path.list_directory(dirname, "idle_\\d+.png"), |
2729 | - hotspot = { 5, 12 }, |
2730 | - fps = 8, |
2731 | - }, |
2732 | - }, |
2733 | -} |
2734 | |
2735 | === added directory 'world/immovables/trees/mushroom_dark' |
2736 | === added file 'world/immovables/trees/mushroom_dark/init.lua' |
2737 | --- world/immovables/trees/mushroom_dark/init.lua 1970-01-01 00:00:00 +0000 |
2738 | +++ world/immovables/trees/mushroom_dark/init.lua 2014-07-06 08:25:52 +0000 |
2739 | @@ -0,0 +1,103 @@ |
2740 | +dirname = path.dirname(__file__) |
2741 | + |
2742 | +terrain_affinity = { |
2743 | + preferred_temperature = 313, |
2744 | + preferred_humidity = 0.25, |
2745 | + preferred_fertility = 0.9, |
2746 | + pickiness = 0.65, |
2747 | +} |
2748 | + |
2749 | +world:new_immovable_type{ |
2750 | + name = "mushroom_dark_wasteland_sapling", |
2751 | + descname = _ "Dark Mushroom Tree (Sapling)", |
2752 | + editor_category = "trees_wasteland", |
2753 | + size = "small", |
2754 | + attributes = { "tree_sapling" }, |
2755 | + terrain_affinity = terrain_affinity, |
2756 | + programs = { |
2757 | + program = { |
2758 | + "animate=idle 72500", |
2759 | + "remove=80", |
2760 | + "grow=mushroom_dark_wasteland_pole", |
2761 | + }, |
2762 | + }, |
2763 | + animations = { |
2764 | + idle = { |
2765 | + pictures = path.list_directory(dirname .. "sapling/", "idle_\\d+.png"), |
2766 | + hotspot = { 5, 12 }, |
2767 | + fps = 8, |
2768 | + }, |
2769 | + }, |
2770 | +} |
2771 | + |
2772 | +world:new_immovable_type{ |
2773 | + name = "mushroom_dark_wasteland_pole", |
2774 | + descname = _ "Dark Mushroom Tree (Pole)", |
2775 | + editor_category = "trees_wasteland", |
2776 | + size = "small", |
2777 | + attributes = {}, |
2778 | + terrain_affinity = terrain_affinity, |
2779 | + programs = { |
2780 | + program = { |
2781 | + "animate=idle 72500", |
2782 | + "remove=70", |
2783 | + "grow=mushroom_dark_wasteland_mature", |
2784 | + }, |
2785 | + }, |
2786 | + animations = { |
2787 | + idle = { |
2788 | + pictures = path.list_directory(dirname .. "pole/", "idle_\\d+.png"), |
2789 | + hotspot = { 12, 28 }, |
2790 | + fps = 8, |
2791 | + }, |
2792 | + }, |
2793 | +} |
2794 | + |
2795 | +world:new_immovable_type{ |
2796 | + name = "mushroom_dark_wasteland_mature", |
2797 | + descname = _ "Dark Mushroom Tree (Mature)", |
2798 | + editor_category = "trees_wasteland", |
2799 | + size = "small", |
2800 | + attributes = {}, |
2801 | + terrain_affinity = terrain_affinity, |
2802 | + programs = { |
2803 | + program = { |
2804 | + "animate=idle 75000", |
2805 | + "remove=40", |
2806 | + "grow=mushroom_dark_wasteland_old", |
2807 | + }, |
2808 | + }, |
2809 | + animations = { |
2810 | + idle = { |
2811 | + pictures = path.list_directory(dirname .. "mature/", "idle_\\d+.png"), |
2812 | + hotspot = { 18, 48 }, |
2813 | + fps = 8, |
2814 | + }, |
2815 | + }, |
2816 | +} |
2817 | + |
2818 | +world:new_immovable_type{ |
2819 | + name = "mushroom_dark_wasteland_old", |
2820 | + descname = _ "Dark Mushroom Tree (Old)", |
2821 | + editor_category = "trees_wasteland", |
2822 | + size = "small", |
2823 | + attributes = { "tree" }, |
2824 | + terrain_affinity = terrain_affinity, |
2825 | + programs = { |
2826 | + program = { |
2827 | + "animate=idle 1050000", |
2828 | + "transform=deadtree2 25", |
2829 | + "seed=mushroom_dark_wasteland_sapling", |
2830 | + }, |
2831 | + fall = { |
2832 | + "remove=", |
2833 | + }, |
2834 | + }, |
2835 | + animations = { |
2836 | + idle = { |
2837 | + pictures = path.list_directory(dirname .. "old/", "idle_\\d+.png"), |
2838 | + hotspot = { 24, 60 }, |
2839 | + fps = 15, |
2840 | + }, |
2841 | + }, |
2842 | +} |
2843 | |
2844 | === renamed directory 'world/immovables/trees/mushroom_dark_wasteland_mature' => 'world/immovables/trees/mushroom_dark/mature' |
2845 | === renamed directory 'world/immovables/trees/mushroom_dark_wasteland_old' => 'world/immovables/trees/mushroom_dark/old' |
2846 | === renamed directory 'world/immovables/trees/mushroom_dark_wasteland_pole' => 'world/immovables/trees/mushroom_dark/pole' |
2847 | === renamed directory 'world/immovables/trees/mushroom_dark_wasteland_sapling' => 'world/immovables/trees/mushroom_dark/sapling' |
2848 | === removed file 'world/immovables/trees/mushroom_dark_wasteland_mature/init.lua' |
2849 | --- world/immovables/trees/mushroom_dark_wasteland_mature/init.lua 2014-06-14 14:33:44 +0000 |
2850 | +++ world/immovables/trees/mushroom_dark_wasteland_mature/init.lua 1970-01-01 00:00:00 +0000 |
2851 | @@ -1,23 +0,0 @@ |
2852 | -dirname = path.dirname(__file__) |
2853 | - |
2854 | -world:new_immovable_type{ |
2855 | - name = "mushroom_dark_wasteland_mature", |
2856 | - descname = _ "Dark Mushroom Tree (Mature)", |
2857 | - editor_category = "trees_wasteland", |
2858 | - size = "small", |
2859 | - attributes = {}, |
2860 | - programs = { |
2861 | - program = { |
2862 | - "animate=idle 75000", |
2863 | - "remove=40", |
2864 | - "grow=mushroom_dark_wasteland_old", |
2865 | - }, |
2866 | - }, |
2867 | - animations = { |
2868 | - idle = { |
2869 | - pictures = path.list_directory(dirname, "idle_\\d+.png"), |
2870 | - hotspot = { 18, 48 }, |
2871 | - fps = 8, |
2872 | - }, |
2873 | - }, |
2874 | -} |
2875 | |
2876 | === removed file 'world/immovables/trees/mushroom_dark_wasteland_old/init.lua' |
2877 | --- world/immovables/trees/mushroom_dark_wasteland_old/init.lua 2014-06-14 14:33:44 +0000 |
2878 | +++ world/immovables/trees/mushroom_dark_wasteland_old/init.lua 1970-01-01 00:00:00 +0000 |
2879 | @@ -1,26 +0,0 @@ |
2880 | -dirname = path.dirname(__file__) |
2881 | - |
2882 | -world:new_immovable_type{ |
2883 | - name = "mushroom_dark_wasteland_old", |
2884 | - descname = _ "Dark Mushroom Tree (Old)", |
2885 | - editor_category = "trees_wasteland", |
2886 | - size = "small", |
2887 | - attributes = { "tree" }, |
2888 | - programs = { |
2889 | - program = { |
2890 | - "animate=idle 1050000", |
2891 | - "transform=deadtree2 25", |
2892 | - "seed=mushroom_dark_wasteland_sapling", |
2893 | - }, |
2894 | - fall = { |
2895 | - "remove=", |
2896 | - }, |
2897 | - }, |
2898 | - animations = { |
2899 | - idle = { |
2900 | - pictures = path.list_directory(dirname, "idle_\\d+.png"), |
2901 | - hotspot = { 24, 60 }, |
2902 | - fps = 15, |
2903 | - }, |
2904 | - }, |
2905 | -} |
2906 | |
2907 | === removed file 'world/immovables/trees/mushroom_dark_wasteland_pole/init.lua' |
2908 | --- world/immovables/trees/mushroom_dark_wasteland_pole/init.lua 2014-06-14 14:33:44 +0000 |
2909 | +++ world/immovables/trees/mushroom_dark_wasteland_pole/init.lua 1970-01-01 00:00:00 +0000 |
2910 | @@ -1,23 +0,0 @@ |
2911 | -dirname = path.dirname(__file__) |
2912 | - |
2913 | -world:new_immovable_type{ |
2914 | - name = "mushroom_dark_wasteland_pole", |
2915 | - descname = _ "Dark Mushroom Tree (Pole)", |
2916 | - editor_category = "trees_wasteland", |
2917 | - size = "small", |
2918 | - attributes = {}, |
2919 | - programs = { |
2920 | - program = { |
2921 | - "animate=idle 72500", |
2922 | - "remove=70", |
2923 | - "grow=mushroom_dark_wasteland_mature", |
2924 | - }, |
2925 | - }, |
2926 | - animations = { |
2927 | - idle = { |
2928 | - pictures = path.list_directory(dirname, "idle_\\d+.png"), |
2929 | - hotspot = { 12, 28 }, |
2930 | - fps = 8, |
2931 | - }, |
2932 | - }, |
2933 | -} |
2934 | |
2935 | === removed file 'world/immovables/trees/mushroom_dark_wasteland_sapling/init.lua' |
2936 | --- world/immovables/trees/mushroom_dark_wasteland_sapling/init.lua 2014-06-14 14:33:44 +0000 |
2937 | +++ world/immovables/trees/mushroom_dark_wasteland_sapling/init.lua 1970-01-01 00:00:00 +0000 |
2938 | @@ -1,23 +0,0 @@ |
2939 | -dirname = path.dirname(__file__) |
2940 | - |
2941 | -world:new_immovable_type{ |
2942 | - name = "mushroom_dark_wasteland_sapling", |
2943 | - descname = _ "Dark Mushroom Tree (Sapling)", |
2944 | - editor_category = "trees_wasteland", |
2945 | - size = "small", |
2946 | - attributes = { "seed" }, |
2947 | - programs = { |
2948 | - program = { |
2949 | - "animate=idle 72500", |
2950 | - "remove=80", |
2951 | - "grow=mushroom_dark_wasteland_pole", |
2952 | - }, |
2953 | - }, |
2954 | - animations = { |
2955 | - idle = { |
2956 | - pictures = path.list_directory(dirname, "idle_\\d+.png"), |
2957 | - hotspot = { 5, 12 }, |
2958 | - fps = 8, |
2959 | - }, |
2960 | - }, |
2961 | -} |
2962 | |
2963 | === added directory 'world/immovables/trees/mushroom_green' |
2964 | === added file 'world/immovables/trees/mushroom_green/init.lua' |
2965 | --- world/immovables/trees/mushroom_green/init.lua 1970-01-01 00:00:00 +0000 |
2966 | +++ world/immovables/trees/mushroom_green/init.lua 2014-07-06 08:25:52 +0000 |
2967 | @@ -0,0 +1,103 @@ |
2968 | +dirname = path.dirname(__file__) |
2969 | + |
2970 | +terrain_affinity = { |
2971 | + preferred_temperature = 310.5, |
2972 | + preferred_humidity = 0.225, |
2973 | + preferred_fertility = 0.85, |
2974 | + pickiness = 0.65, |
2975 | +} |
2976 | + |
2977 | +world:new_immovable_type{ |
2978 | + name = "mushroom_green_wasteland_sapling", |
2979 | + descname = _ "Green Mushroom Tree (Sapling)", |
2980 | + editor_category = "trees_wasteland", |
2981 | + size = "small", |
2982 | + attributes = { "tree_sapling" }, |
2983 | + terrain_affinity = terrain_affinity, |
2984 | + programs = { |
2985 | + program = { |
2986 | + "animate=idle 55000", |
2987 | + "remove=35", |
2988 | + "grow=mushroom_green_wasteland_pole", |
2989 | + }, |
2990 | + }, |
2991 | + animations = { |
2992 | + idle = { |
2993 | + pictures = path.list_directory(dirname .. "sapling/", "idle_\\d+.png"), |
2994 | + hotspot = { 5, 12 }, |
2995 | + fps = 8, |
2996 | + }, |
2997 | + }, |
2998 | +} |
2999 | + |
3000 | +world:new_immovable_type{ |
3001 | + name = "mushroom_green_wasteland_pole", |
3002 | + descname = _ "Green Mushroom Tree (Pole)", |
3003 | + editor_category = "trees_wasteland", |
3004 | + size = "small", |
3005 | + attributes = {}, |
3006 | + terrain_affinity = terrain_affinity, |
3007 | + programs = { |
3008 | + program = { |
3009 | + "animate=idle 65000", |
3010 | + "remove=24", |
3011 | + "grow=mushroom_green_wasteland_mature", |
3012 | + }, |
3013 | + }, |
3014 | + animations = { |
3015 | + idle = { |
3016 | + pictures = path.list_directory(dirname .. "pole/", "idle_\\d+.png"), |
3017 | + hotspot = { 12, 28 }, |
3018 | + fps = 8, |
3019 | + }, |
3020 | + }, |
3021 | +} |
3022 | + |
3023 | +world:new_immovable_type{ |
3024 | + name = "mushroom_green_wasteland_mature", |
3025 | + descname = _ "Green Mushroom Tree (Mature)", |
3026 | + editor_category = "trees_wasteland", |
3027 | + size = "small", |
3028 | + attributes = {}, |
3029 | + terrain_affinity = terrain_affinity, |
3030 | + programs = { |
3031 | + program = { |
3032 | + "animate=idle 72000", |
3033 | + "remove=19", |
3034 | + "grow=mushroom_green_wasteland_old", |
3035 | + }, |
3036 | + }, |
3037 | + animations = { |
3038 | + idle = { |
3039 | + pictures = path.list_directory(dirname .. "mature/", "idle_\\d+.png"), |
3040 | + hotspot = { 18, 48 }, |
3041 | + fps = 8, |
3042 | + }, |
3043 | + }, |
3044 | +} |
3045 | + |
3046 | +world:new_immovable_type{ |
3047 | + name = "mushroom_green_wasteland_old", |
3048 | + descname = _ "Green Mushroom Tree (Old)", |
3049 | + editor_category = "trees_wasteland", |
3050 | + size = "small", |
3051 | + attributes = { "tree" }, |
3052 | + terrain_affinity = terrain_affinity, |
3053 | + programs = { |
3054 | + program = { |
3055 | + "animate=idle 1535000", |
3056 | + "transform=deadtree2 33", |
3057 | + "seed=mushroom_green_wasteland_sapling", |
3058 | + }, |
3059 | + fall = { |
3060 | + "remove=", |
3061 | + }, |
3062 | + }, |
3063 | + animations = { |
3064 | + idle = { |
3065 | + pictures = path.list_directory(dirname .. "old/", "idle_\\d+.png"), |
3066 | + hotspot = { 24, 60 }, |
3067 | + fps = 10, |
3068 | + }, |
3069 | + }, |
3070 | +} |
3071 | |
3072 | === renamed directory 'world/immovables/trees/mushroom_green_wasteland_mature' => 'world/immovables/trees/mushroom_green/mature' |
3073 | === renamed directory 'world/immovables/trees/mushroom_green_wasteland_old' => 'world/immovables/trees/mushroom_green/old' |
3074 | === renamed directory 'world/immovables/trees/mushroom_green_wasteland_pole' => 'world/immovables/trees/mushroom_green/pole' |
3075 | === renamed directory 'world/immovables/trees/mushroom_green_wasteland_sapling' => 'world/immovables/trees/mushroom_green/sapling' |
3076 | === removed file 'world/immovables/trees/mushroom_green_wasteland_mature/init.lua' |
3077 | --- world/immovables/trees/mushroom_green_wasteland_mature/init.lua 2014-06-14 14:33:44 +0000 |
3078 | +++ world/immovables/trees/mushroom_green_wasteland_mature/init.lua 1970-01-01 00:00:00 +0000 |
3079 | @@ -1,23 +0,0 @@ |
3080 | -dirname = path.dirname(__file__) |
3081 | - |
3082 | -world:new_immovable_type{ |
3083 | - name = "mushroom_green_wasteland_mature", |
3084 | - descname = _ "Green Mushroom Tree (Mature)", |
3085 | - editor_category = "trees_wasteland", |
3086 | - size = "small", |
3087 | - attributes = {}, |
3088 | - programs = { |
3089 | - program = { |
3090 | - "animate=idle 72000", |
3091 | - "remove=19", |
3092 | - "grow=mushroom_green_wasteland_old", |
3093 | - }, |
3094 | - }, |
3095 | - animations = { |
3096 | - idle = { |
3097 | - pictures = path.list_directory(dirname, "idle_\\d+.png"), |
3098 | - hotspot = { 18, 48 }, |
3099 | - fps = 8, |
3100 | - }, |
3101 | - }, |
3102 | -} |
3103 | |
3104 | === removed file 'world/immovables/trees/mushroom_green_wasteland_old/init.lua' |
3105 | --- world/immovables/trees/mushroom_green_wasteland_old/init.lua 2014-06-14 14:33:44 +0000 |
3106 | +++ world/immovables/trees/mushroom_green_wasteland_old/init.lua 1970-01-01 00:00:00 +0000 |
3107 | @@ -1,26 +0,0 @@ |
3108 | -dirname = path.dirname(__file__) |
3109 | - |
3110 | -world:new_immovable_type{ |
3111 | - name = "mushroom_green_wasteland_old", |
3112 | - descname = _ "Green Mushroom Tree (Old)", |
3113 | - editor_category = "trees_wasteland", |
3114 | - size = "small", |
3115 | - attributes = { "tree" }, |
3116 | - programs = { |
3117 | - program = { |
3118 | - "animate=idle 1535000", |
3119 | - "transform=deadtree2 33", |
3120 | - "seed=mushroom_green_wasteland_sapling", |
3121 | - }, |
3122 | - fall = { |
3123 | - "remove=", |
3124 | - }, |
3125 | - }, |
3126 | - animations = { |
3127 | - idle = { |
3128 | - pictures = path.list_directory(dirname, "idle_\\d+.png"), |
3129 | - hotspot = { 24, 60 }, |
3130 | - fps = 10, |
3131 | - }, |
3132 | - }, |
3133 | -} |
3134 | |
3135 | === removed file 'world/immovables/trees/mushroom_green_wasteland_pole/init.lua' |
3136 | --- world/immovables/trees/mushroom_green_wasteland_pole/init.lua 2014-06-14 14:33:44 +0000 |
3137 | +++ world/immovables/trees/mushroom_green_wasteland_pole/init.lua 1970-01-01 00:00:00 +0000 |
3138 | @@ -1,23 +0,0 @@ |
3139 | -dirname = path.dirname(__file__) |
3140 | - |
3141 | -world:new_immovable_type{ |
3142 | - name = "mushroom_green_wasteland_pole", |
3143 | - descname = _ "Green Mushroom Tree (Pole)", |
3144 | - editor_category = "trees_wasteland", |
3145 | - size = "small", |
3146 | - attributes = {}, |
3147 | - programs = { |
3148 | - program = { |
3149 | - "animate=idle 65000", |
3150 | - "remove=24", |
3151 | - "grow=mushroom_green_wasteland_mature", |
3152 | - }, |
3153 | - }, |
3154 | - animations = { |
3155 | - idle = { |
3156 | - pictures = path.list_directory(dirname, "idle_\\d+.png"), |
3157 | - hotspot = { 12, 28 }, |
3158 | - fps = 8, |
3159 | - }, |
3160 | - }, |
3161 | -} |
3162 | |
3163 | === removed file 'world/immovables/trees/mushroom_green_wasteland_sapling/init.lua' |
3164 | --- world/immovables/trees/mushroom_green_wasteland_sapling/init.lua 2014-06-14 14:33:44 +0000 |
3165 | +++ world/immovables/trees/mushroom_green_wasteland_sapling/init.lua 1970-01-01 00:00:00 +0000 |
3166 | @@ -1,23 +0,0 @@ |
3167 | -dirname = path.dirname(__file__) |
3168 | - |
3169 | -world:new_immovable_type{ |
3170 | - name = "mushroom_green_wasteland_sapling", |
3171 | - descname = _ "Green Mushroom Tree (Sapling)", |
3172 | - editor_category = "trees_wasteland", |
3173 | - size = "small", |
3174 | - attributes = { "seed" }, |
3175 | - programs = { |
3176 | - program = { |
3177 | - "animate=idle 55000", |
3178 | - "remove=35", |
3179 | - "grow=mushroom_green_wasteland_pole", |
3180 | - }, |
3181 | - }, |
3182 | - animations = { |
3183 | - idle = { |
3184 | - pictures = path.list_directory(dirname, "idle_\\d+.png"), |
3185 | - hotspot = { 5, 12 }, |
3186 | - fps = 8, |
3187 | - }, |
3188 | - }, |
3189 | -} |
3190 | |
3191 | === added directory 'world/immovables/trees/mushroom_red' |
3192 | === added file 'world/immovables/trees/mushroom_red/init.lua' |
3193 | --- world/immovables/trees/mushroom_red/init.lua 1970-01-01 00:00:00 +0000 |
3194 | +++ world/immovables/trees/mushroom_red/init.lua 2014-07-06 08:25:52 +0000 |
3195 | @@ -0,0 +1,106 @@ |
3196 | +dirname = path.dirname(__file__) |
3197 | + |
3198 | +terrain_affinity = { |
3199 | + preferred_temperature = 308, |
3200 | + preferred_humidity = 0.2, |
3201 | + preferred_fertility = 0.8, |
3202 | + pickiness = 0.65, |
3203 | +} |
3204 | + |
3205 | +world:new_immovable_type{ |
3206 | + name = "mushroom_red_wasteland_sapling", |
3207 | + descname = _ "Red Mushroom Tree (Sapling)", |
3208 | + editor_category = "trees_wasteland", |
3209 | + size = "small", |
3210 | + attributes = { "tree_sapling" }, |
3211 | + terrain_affinity = terrain_affinity, |
3212 | + programs = { |
3213 | + program = { |
3214 | + "animate=idle 42000", |
3215 | + "remove=32", |
3216 | + "grow=mushroom_red_wasteland_pole", |
3217 | + }, |
3218 | + }, |
3219 | + animations = { |
3220 | + idle = { |
3221 | + pictures = path.list_directory(dirname .. "sapling/", "idle_\\d+.png"), |
3222 | + hotspot = { 5, 12 }, |
3223 | + fps = 8, |
3224 | + }, |
3225 | + }, |
3226 | +} |
3227 | + |
3228 | +world:new_immovable_type{ |
3229 | + name = "mushroom_red_wasteland_pole", |
3230 | + descname = _ "Red Mushroom Tree (Pole)", |
3231 | + editor_category = "trees_wasteland", |
3232 | + size = "small", |
3233 | + attributes = {}, |
3234 | + terrain_affinity = terrain_affinity, |
3235 | + programs = { |
3236 | + program = { |
3237 | + "animate=idle 40000", |
3238 | + "remove=25", |
3239 | + "grow=mushroom_red_wasteland_mature", |
3240 | + }, |
3241 | + }, |
3242 | + animations = { |
3243 | + idle = { |
3244 | + pictures = path.list_directory(dirname .. "pole/", "idle_\\d+.png"), |
3245 | + hotspot = { 12, 28 }, |
3246 | + fps = 8, |
3247 | + }, |
3248 | + }, |
3249 | +} |
3250 | + |
3251 | +world:new_immovable_type{ |
3252 | + name = "mushroom_red_wasteland_mature", |
3253 | + descname = _ "Red Mushroom Tree (Mature)", |
3254 | + editor_category = "trees_wasteland", |
3255 | + size = "small", |
3256 | + attributes = {}, |
3257 | + terrain_affinity = terrain_affinity, |
3258 | + programs = { |
3259 | + program = { |
3260 | + "animate=idle 27000", |
3261 | + "remove=10", |
3262 | + "seed=mushroom_red_wasteland_sapling", |
3263 | + "animate=idle 29000", |
3264 | + "remove=10", |
3265 | + "grow=mushroom_red_wasteland_old", |
3266 | + }, |
3267 | + }, |
3268 | + animations = { |
3269 | + idle = { |
3270 | + pictures = path.list_directory(dirname .. "mature/", "idle_\\d+.png"), |
3271 | + hotspot = { 18, 48 }, |
3272 | + fps = 8, |
3273 | + }, |
3274 | + }, |
3275 | +} |
3276 | + |
3277 | +world:new_immovable_type{ |
3278 | + name = "mushroom_red_wasteland_old", |
3279 | + descname = _ "Red Mushroom Tree (Old)", |
3280 | + editor_category = "trees_wasteland", |
3281 | + size = "small", |
3282 | + attributes = { "tree" }, |
3283 | + terrain_affinity = terrain_affinity, |
3284 | + programs = { |
3285 | + program = { |
3286 | + "animate=idle 800000", |
3287 | + "transform=deadtree2 50", |
3288 | + "seed=mushroom_red_wasteland_sapling", |
3289 | + }, |
3290 | + fall = { |
3291 | + "remove=", |
3292 | + }, |
3293 | + }, |
3294 | + animations = { |
3295 | + idle = { |
3296 | + pictures = path.list_directory(dirname .. "old/", "idle_\\d+.png"), |
3297 | + hotspot = { 24, 60 }, |
3298 | + fps = 10, |
3299 | + }, |
3300 | + }, |
3301 | +} |
3302 | |
3303 | === renamed directory 'world/immovables/trees/mushroom_red_wasteland_mature' => 'world/immovables/trees/mushroom_red/mature' |
3304 | === renamed directory 'world/immovables/trees/mushroom_red_wasteland_old' => 'world/immovables/trees/mushroom_red/old' |
3305 | === renamed directory 'world/immovables/trees/mushroom_red_wasteland_pole' => 'world/immovables/trees/mushroom_red/pole' |
3306 | === renamed directory 'world/immovables/trees/mushroom_red_wasteland_sapling' => 'world/immovables/trees/mushroom_red/sapling' |
3307 | === removed file 'world/immovables/trees/mushroom_red_wasteland_mature/init.lua' |
3308 | --- world/immovables/trees/mushroom_red_wasteland_mature/init.lua 2014-06-14 14:33:44 +0000 |
3309 | +++ world/immovables/trees/mushroom_red_wasteland_mature/init.lua 1970-01-01 00:00:00 +0000 |
3310 | @@ -1,26 +0,0 @@ |
3311 | -dirname = path.dirname(__file__) |
3312 | - |
3313 | -world:new_immovable_type{ |
3314 | - name = "mushroom_red_wasteland_mature", |
3315 | - descname = _ "Red Mushroom Tree (Mature)", |
3316 | - editor_category = "trees_wasteland", |
3317 | - size = "small", |
3318 | - attributes = {}, |
3319 | - programs = { |
3320 | - program = { |
3321 | - "animate=idle 27000", |
3322 | - "remove=10", |
3323 | - "seed=mushroom_red_wasteland_sapling", |
3324 | - "animate=idle 29000", |
3325 | - "remove=10", |
3326 | - "grow=mushroom_red_wasteland_old", |
3327 | - }, |
3328 | - }, |
3329 | - animations = { |
3330 | - idle = { |
3331 | - pictures = path.list_directory(dirname, "idle_\\d+.png"), |
3332 | - hotspot = { 18, 48 }, |
3333 | - fps = 8, |
3334 | - }, |
3335 | - }, |
3336 | -} |
3337 | |
3338 | === removed file 'world/immovables/trees/mushroom_red_wasteland_old/init.lua' |
3339 | --- world/immovables/trees/mushroom_red_wasteland_old/init.lua 2014-06-14 14:33:44 +0000 |
3340 | +++ world/immovables/trees/mushroom_red_wasteland_old/init.lua 1970-01-01 00:00:00 +0000 |
3341 | @@ -1,26 +0,0 @@ |
3342 | -dirname = path.dirname(__file__) |
3343 | - |
3344 | -world:new_immovable_type{ |
3345 | - name = "mushroom_red_wasteland_old", |
3346 | - descname = _ "Red Mushroom Tree (Old)", |
3347 | - editor_category = "trees_wasteland", |
3348 | - size = "small", |
3349 | - attributes = { "tree" }, |
3350 | - programs = { |
3351 | - program = { |
3352 | - "animate=idle 800000", |
3353 | - "transform=deadtree2 50", |
3354 | - "seed=mushroom_red_wasteland_sapling", |
3355 | - }, |
3356 | - fall = { |
3357 | - "remove=", |
3358 | - }, |
3359 | - }, |
3360 | - animations = { |
3361 | - idle = { |
3362 | - pictures = path.list_directory(dirname, "idle_\\d+.png"), |
3363 | - hotspot = { 24, 60 }, |
3364 | - fps = 10, |
3365 | - }, |
3366 | - }, |
3367 | -} |
3368 | |
3369 | === removed file 'world/immovables/trees/mushroom_red_wasteland_pole/init.lua' |
3370 | --- world/immovables/trees/mushroom_red_wasteland_pole/init.lua 2014-06-14 14:33:44 +0000 |
3371 | +++ world/immovables/trees/mushroom_red_wasteland_pole/init.lua 1970-01-01 00:00:00 +0000 |
3372 | @@ -1,23 +0,0 @@ |
3373 | -dirname = path.dirname(__file__) |
3374 | - |
3375 | -world:new_immovable_type{ |
3376 | - name = "mushroom_red_wasteland_pole", |
3377 | - descname = _ "Red Mushroom Tree (Pole)", |
3378 | - editor_category = "trees_wasteland", |
3379 | - size = "small", |
3380 | - attributes = {}, |
3381 | - programs = { |
3382 | - program = { |
3383 | - "animate=idle 40000", |
3384 | - "remove=25", |
3385 | - "grow=mushroom_red_wasteland_mature", |
3386 | - }, |
3387 | - }, |
3388 | - animations = { |
3389 | - idle = { |
3390 | - pictures = path.list_directory(dirname, "idle_\\d+.png"), |
3391 | - hotspot = { 12, 28 }, |
3392 | - fps = 8, |
3393 | - }, |
3394 | - }, |
3395 | -} |
3396 | |
3397 | === removed file 'world/immovables/trees/mushroom_red_wasteland_sapling/init.lua' |
3398 | --- world/immovables/trees/mushroom_red_wasteland_sapling/init.lua 2014-06-14 14:33:44 +0000 |
3399 | +++ world/immovables/trees/mushroom_red_wasteland_sapling/init.lua 1970-01-01 00:00:00 +0000 |
3400 | @@ -1,23 +0,0 @@ |
3401 | -dirname = path.dirname(__file__) |
3402 | - |
3403 | -world:new_immovable_type{ |
3404 | - name = "mushroom_red_wasteland_sapling", |
3405 | - descname = _ "Red Mushroom Tree (Sapling)", |
3406 | - editor_category = "trees_wasteland", |
3407 | - size = "small", |
3408 | - attributes = { "seed" }, |
3409 | - programs = { |
3410 | - program = { |
3411 | - "animate=idle 42000", |
3412 | - "remove=32", |
3413 | - "grow=mushroom_red_wasteland_pole", |
3414 | - }, |
3415 | - }, |
3416 | - animations = { |
3417 | - idle = { |
3418 | - pictures = path.list_directory(dirname, "idle_\\d+.png"), |
3419 | - hotspot = { 5, 12 }, |
3420 | - fps = 8, |
3421 | - }, |
3422 | - }, |
3423 | -} |
3424 | |
3425 | === added directory 'world/immovables/trees/oak' |
3426 | === added file 'world/immovables/trees/oak/init.lua' |
3427 | --- world/immovables/trees/oak/init.lua 1970-01-01 00:00:00 +0000 |
3428 | +++ world/immovables/trees/oak/init.lua 2014-07-06 08:25:52 +0000 |
3429 | @@ -0,0 +1,113 @@ |
3430 | +dirname = path.dirname(__file__) |
3431 | + |
3432 | +terrain_affinity = { |
3433 | + preferred_temperature = 293, |
3434 | + preferred_humidity = 0.8, |
3435 | + preferred_fertility = 0.75, |
3436 | + pickiness = 0.7, |
3437 | +} |
3438 | + |
3439 | +world:new_immovable_type{ |
3440 | + name = "oak_summer_sapling", |
3441 | + descname = _ "Oak (Sapling)", |
3442 | + editor_category = "trees_deciduous", |
3443 | + size = "small", |
3444 | + attributes = { "tree_sapling" }, |
3445 | + terrain_affinity = terrain_affinity, |
3446 | + programs = { |
3447 | + program = { |
3448 | + "animate=idle 72500", |
3449 | + "remove=80", |
3450 | + "grow=oak_summer_pole", |
3451 | + }, |
3452 | + }, |
3453 | + animations = { |
3454 | + idle = { |
3455 | + pictures = path.list_directory(dirname .. "sapling/", "idle_\\d+.png"), |
3456 | + hotspot = { 5, 12 }, |
3457 | + fps = 8, |
3458 | + }, |
3459 | + }, |
3460 | +} |
3461 | + |
3462 | +world:new_immovable_type{ |
3463 | + name = "oak_summer_pole", |
3464 | + descname = _ "Oak (Pole)", |
3465 | + editor_category = "trees_deciduous", |
3466 | + size = "small", |
3467 | + attributes = {}, |
3468 | + terrain_affinity = terrain_affinity, |
3469 | + programs = { |
3470 | + program = { |
3471 | + "animate=idle 72500", |
3472 | + "remove=70", |
3473 | + "grow=oak_summer_mature", |
3474 | + }, |
3475 | + }, |
3476 | + animations = { |
3477 | + idle = { |
3478 | + pictures = path.list_directory(dirname .. "pole/", "idle_\\d+.png"), |
3479 | + hotspot = { 12, 28 }, |
3480 | + fps = 8, |
3481 | + }, |
3482 | + }, |
3483 | +} |
3484 | + |
3485 | +world:new_immovable_type{ |
3486 | + name = "oak_summer_mature", |
3487 | + descname = _ "Oak (Mature)", |
3488 | + editor_category = "trees_deciduous", |
3489 | + size = "small", |
3490 | + attributes = {}, |
3491 | + terrain_affinity = terrain_affinity, |
3492 | + programs = { |
3493 | + program = { |
3494 | + "animate=idle 75000", |
3495 | + "remove=40", |
3496 | + "grow=oak_summer_old", |
3497 | + }, |
3498 | + }, |
3499 | + animations = { |
3500 | + idle = { |
3501 | + pictures = path.list_directory(dirname .. "mature/", "idle_\\d+.png"), |
3502 | + hotspot = { 18, 48 }, |
3503 | + fps = 8, |
3504 | + }, |
3505 | + }, |
3506 | +} |
3507 | + |
3508 | +world:new_immovable_type{ |
3509 | + name = "oak_summer_old", |
3510 | + descname = _ "Oak (Old)", |
3511 | + editor_category = "trees_deciduous", |
3512 | + size = "small", |
3513 | + attributes = { "tree" }, |
3514 | + terrain_affinity = terrain_affinity, |
3515 | + programs = { |
3516 | + program = { |
3517 | + "animate=idle 2250000", |
3518 | + "transform=deadtree2 12", |
3519 | + "seed=oak_summer_sapling", |
3520 | + }, |
3521 | + fall = { |
3522 | + "animate=falling 1200", |
3523 | + "transform=fallentree", |
3524 | + }, |
3525 | + }, |
3526 | + animations = { |
3527 | + idle = { |
3528 | + pictures = path.list_directory(dirname .. "old/", "idle_\\d+.png"), |
3529 | + hotspot = { 24, 60 }, |
3530 | + fps = 10, |
3531 | + sound_effect = { |
3532 | + directory = "sound/animals", |
3533 | + name = "bird2", |
3534 | + }, |
3535 | + }, |
3536 | + falling = { |
3537 | + pictures = path.list_directory(dirname .. "old/", "f_tree_\\d+.png"), |
3538 | + hotspot = { 10, 60 }, |
3539 | + fps = 10, |
3540 | + }, |
3541 | + }, |
3542 | +} |
3543 | |
3544 | === renamed directory 'world/immovables/trees/oak_summer_mature' => 'world/immovables/trees/oak/mature' |
3545 | === renamed directory 'world/immovables/trees/oak_summer_old' => 'world/immovables/trees/oak/old' |
3546 | === renamed directory 'world/immovables/trees/oak_summer_pole' => 'world/immovables/trees/oak/pole' |
3547 | === renamed directory 'world/immovables/trees/oak_summer_sapling' => 'world/immovables/trees/oak/sapling' |
3548 | === removed file 'world/immovables/trees/oak_summer_mature/init.lua' |
3549 | --- world/immovables/trees/oak_summer_mature/init.lua 2014-05-03 08:40:59 +0000 |
3550 | +++ world/immovables/trees/oak_summer_mature/init.lua 1970-01-01 00:00:00 +0000 |
3551 | @@ -1,23 +0,0 @@ |
3552 | -dirname = path.dirname(__file__) |
3553 | - |
3554 | -world:new_immovable_type{ |
3555 | - name = "oak_summer_mature", |
3556 | - descname = _ "Oak (Mature)", |
3557 | - editor_category = "trees_deciduous", |
3558 | - size = "small", |
3559 | - attributes = {}, |
3560 | - programs = { |
3561 | - program = { |
3562 | - "animate=idle 75000", |
3563 | - "remove=40", |
3564 | - "grow=oak_summer_old", |
3565 | - }, |
3566 | - }, |
3567 | - animations = { |
3568 | - idle = { |
3569 | - pictures = path.list_directory(dirname, "idle_\\d+.png"), |
3570 | - hotspot = { 18, 48 }, |
3571 | - fps = 8, |
3572 | - }, |
3573 | - }, |
3574 | -} |
3575 | |
3576 | === removed file 'world/immovables/trees/oak_summer_old/init.lua' |
3577 | --- world/immovables/trees/oak_summer_old/init.lua 2014-05-03 08:40:59 +0000 |
3578 | +++ world/immovables/trees/oak_summer_old/init.lua 1970-01-01 00:00:00 +0000 |
3579 | @@ -1,36 +0,0 @@ |
3580 | -dirname = path.dirname(__file__) |
3581 | - |
3582 | -world:new_immovable_type{ |
3583 | - name = "oak_summer_old", |
3584 | - descname = _ "Oak (Old)", |
3585 | - editor_category = "trees_deciduous", |
3586 | - size = "small", |
3587 | - attributes = { "tree" }, |
3588 | - programs = { |
3589 | - program = { |
3590 | - "animate=idle 2250000", |
3591 | - "transform=deadtree2 12", |
3592 | - "seed=oak_summer_sapling", |
3593 | - }, |
3594 | - fall = { |
3595 | - "animate=falling 1200", |
3596 | - "transform=fallentree", |
3597 | - }, |
3598 | - }, |
3599 | - animations = { |
3600 | - idle = { |
3601 | - pictures = path.list_directory(dirname, "idle_\\d+.png"), |
3602 | - hotspot = { 24, 60 }, |
3603 | - fps = 10, |
3604 | - sound_effect = { |
3605 | - directory = "sound/animals", |
3606 | - name = "bird2", |
3607 | - }, |
3608 | - }, |
3609 | - falling = { |
3610 | - pictures = path.list_directory(dirname, "f_tree_\\d+.png"), |
3611 | - hotspot = { 10, 60 }, |
3612 | - fps = 10, |
3613 | - }, |
3614 | - }, |
3615 | -} |
3616 | |
3617 | === removed file 'world/immovables/trees/oak_summer_pole/init.lua' |
3618 | --- world/immovables/trees/oak_summer_pole/init.lua 2014-05-03 08:40:59 +0000 |
3619 | +++ world/immovables/trees/oak_summer_pole/init.lua 1970-01-01 00:00:00 +0000 |
3620 | @@ -1,23 +0,0 @@ |
3621 | -dirname = path.dirname(__file__) |
3622 | - |
3623 | -world:new_immovable_type{ |
3624 | - name = "oak_summer_pole", |
3625 | - descname = _ "Oak (Pole)", |
3626 | - editor_category = "trees_deciduous", |
3627 | - size = "small", |
3628 | - attributes = {}, |
3629 | - programs = { |
3630 | - program = { |
3631 | - "animate=idle 72500", |
3632 | - "remove=70", |
3633 | - "grow=oak_summer_mature", |
3634 | - }, |
3635 | - }, |
3636 | - animations = { |
3637 | - idle = { |
3638 | - pictures = path.list_directory(dirname, "idle_\\d+.png"), |
3639 | - hotspot = { 12, 28 }, |
3640 | - fps = 8, |
3641 | - }, |
3642 | - }, |
3643 | -} |
3644 | |
3645 | === removed file 'world/immovables/trees/oak_summer_sapling/init.lua' |
3646 | --- world/immovables/trees/oak_summer_sapling/init.lua 2014-05-03 08:40:59 +0000 |
3647 | +++ world/immovables/trees/oak_summer_sapling/init.lua 1970-01-01 00:00:00 +0000 |
3648 | @@ -1,23 +0,0 @@ |
3649 | -dirname = path.dirname(__file__) |
3650 | - |
3651 | -world:new_immovable_type{ |
3652 | - name = "oak_summer_sapling", |
3653 | - descname = _ "Oak (Sapling)", |
3654 | - editor_category = "trees_deciduous", |
3655 | - size = "small", |
3656 | - attributes = { "seed" }, |
3657 | - programs = { |
3658 | - program = { |
3659 | - "animate=idle 72500", |
3660 | - "remove=80", |
3661 | - "grow=oak_summer_pole", |
3662 | - }, |
3663 | - }, |
3664 | - animations = { |
3665 | - idle = { |
3666 | - pictures = path.list_directory(dirname, "idle_\\d+.png"), |
3667 | - hotspot = { 5, 12 }, |
3668 | - fps = 8, |
3669 | - }, |
3670 | - }, |
3671 | -} |
3672 | |
3673 | === added directory 'world/immovables/trees/palm_borassus' |
3674 | === added file 'world/immovables/trees/palm_borassus/init.lua' |
3675 | --- world/immovables/trees/palm_borassus/init.lua 1970-01-01 00:00:00 +0000 |
3676 | +++ world/immovables/trees/palm_borassus/init.lua 2014-07-06 08:25:52 +0000 |
3677 | @@ -0,0 +1,107 @@ |
3678 | +dirname = path.dirname(__file__) |
3679 | + |
3680 | +terrain_affinity = { |
3681 | + preferred_temperature = 318, |
3682 | + preferred_humidity = 0.5, |
3683 | + preferred_fertility = 0.7, |
3684 | + pickiness = 0.8, |
3685 | +} |
3686 | + |
3687 | +world:new_immovable_type{ |
3688 | + name = "palm_borassus_desert_sapling", |
3689 | + descname = _ "Borassus Palm (Sapling)", |
3690 | + editor_category = "trees_palm", |
3691 | + size = "small", |
3692 | + attributes = { "tree_sapling" }, |
3693 | + terrain_affinity = terrain_affinity, |
3694 | + programs = { |
3695 | + program = { |
3696 | + "animate=idle 70000", |
3697 | + "remove=80", |
3698 | + "grow=palm_borassus_desert_pole", |
3699 | + }, |
3700 | + }, |
3701 | + animations = { |
3702 | + idle = { |
3703 | + pictures = path.list_directory(dirname .. "sapling/", "idle_\\d+.png"), |
3704 | + hotspot = { 5, 12 }, |
3705 | + fps = 8, |
3706 | + }, |
3707 | + }, |
3708 | +} |
3709 | + |
3710 | +world:new_immovable_type{ |
3711 | + name = "palm_borassus_desert_pole", |
3712 | + descname = _ "Borassus Palm (Pole)", |
3713 | + editor_category = "trees_palm", |
3714 | + size = "small", |
3715 | + attributes = {}, |
3716 | + terrain_affinity = terrain_affinity, |
3717 | + programs = { |
3718 | + program = { |
3719 | + "animate=idle 70000", |
3720 | + "remove=70", |
3721 | + "grow=palm_borassus_desert_mature", |
3722 | + }, |
3723 | + }, |
3724 | + animations = { |
3725 | + idle = { |
3726 | + pictures = path.list_directory(dirname .. "pole/", "idle_\\d+.png"), |
3727 | + hotspot = { 12, 28 }, |
3728 | + fps = 8, |
3729 | + }, |
3730 | + }, |
3731 | +} |
3732 | + |
3733 | +world:new_immovable_type{ |
3734 | + name = "palm_borassus_desert_mature", |
3735 | + descname = _ "Borassus Palm (Mature)", |
3736 | + editor_category = "trees_palm", |
3737 | + size = "small", |
3738 | + attributes = {}, |
3739 | + terrain_affinity = terrain_affinity, |
3740 | + programs = { |
3741 | + program = { |
3742 | + "animate=idle 65000", |
3743 | + "remove=40", |
3744 | + "grow=palm_borassus_desert_old", |
3745 | + }, |
3746 | + }, |
3747 | + animations = { |
3748 | + idle = { |
3749 | + pictures = path.list_directory(dirname .. "mature/", "idle_\\d+.png"), |
3750 | + hotspot = { 18, 48 }, |
3751 | + fps = 8, |
3752 | + }, |
3753 | + }, |
3754 | +} |
3755 | + |
3756 | +world:new_immovable_type{ |
3757 | + name = "palm_borassus_desert_old", |
3758 | + descname = _ "Borassus Palm (Old)", |
3759 | + editor_category = "trees_palm", |
3760 | + size = "small", |
3761 | + attributes = { "tree" }, |
3762 | + terrain_affinity = terrain_affinity, |
3763 | + programs = { |
3764 | + program = { |
3765 | + "animate=idle 2000000", |
3766 | + "transform=deadtree5 25", |
3767 | + "seed=palm_borassus_desert_sapling", |
3768 | + }, |
3769 | + fall = { |
3770 | + "remove=", |
3771 | + }, |
3772 | + }, |
3773 | + animations = { |
3774 | + idle = { |
3775 | + pictures = path.list_directory(dirname .. "old/", "idle_\\d+.png"), |
3776 | + hotspot = { 24, 60 }, |
3777 | + fps = 10, |
3778 | + sound_effect = { |
3779 | + directory = "sound/animals", |
3780 | + name = "bird2", |
3781 | + }, |
3782 | + }, |
3783 | + }, |
3784 | +} |
3785 | |
3786 | === renamed directory 'world/immovables/trees/palm_borassus_desert_mature' => 'world/immovables/trees/palm_borassus/mature' |
3787 | === renamed directory 'world/immovables/trees/palm_borassus_desert_old' => 'world/immovables/trees/palm_borassus/old' |
3788 | === renamed directory 'world/immovables/trees/palm_borassus_desert_pole' => 'world/immovables/trees/palm_borassus/pole' |
3789 | === renamed directory 'world/immovables/trees/palm_borassus_desert_sapling' => 'world/immovables/trees/palm_borassus/sapling' |
3790 | === removed file 'world/immovables/trees/palm_borassus_desert_mature/init.lua' |
3791 | --- world/immovables/trees/palm_borassus_desert_mature/init.lua 2014-05-03 08:40:59 +0000 |
3792 | +++ world/immovables/trees/palm_borassus_desert_mature/init.lua 1970-01-01 00:00:00 +0000 |
3793 | @@ -1,23 +0,0 @@ |
3794 | -dirname = path.dirname(__file__) |
3795 | - |
3796 | -world:new_immovable_type{ |
3797 | - name = "palm_borassus_desert_mature", |
3798 | - descname = _ "Borassus Palm (Mature)", |
3799 | - editor_category = "trees_palm", |
3800 | - size = "small", |
3801 | - attributes = {}, |
3802 | - programs = { |
3803 | - program = { |
3804 | - "animate=idle 65000", |
3805 | - "remove=40", |
3806 | - "grow=palm_borassus_desert_old", |
3807 | - }, |
3808 | - }, |
3809 | - animations = { |
3810 | - idle = { |
3811 | - pictures = path.list_directory(dirname, "idle_\\d+.png"), |
3812 | - hotspot = { 18, 48 }, |
3813 | - fps = 8, |
3814 | - }, |
3815 | - }, |
3816 | -} |
3817 | |
3818 | === removed file 'world/immovables/trees/palm_borassus_desert_old/init.lua' |
3819 | --- world/immovables/trees/palm_borassus_desert_old/init.lua 2014-05-03 08:40:59 +0000 |
3820 | +++ world/immovables/trees/palm_borassus_desert_old/init.lua 1970-01-01 00:00:00 +0000 |
3821 | @@ -1,30 +0,0 @@ |
3822 | -dirname = path.dirname(__file__) |
3823 | - |
3824 | -world:new_immovable_type{ |
3825 | - name = "palm_borassus_desert_old", |
3826 | - descname = _ "Borassus Palm (Old)", |
3827 | - editor_category = "trees_palm", |
3828 | - size = "small", |
3829 | - attributes = { "tree" }, |
3830 | - programs = { |
3831 | - program = { |
3832 | - "animate=idle 2000000", |
3833 | - "transform=deadtree5 25", |
3834 | - "seed=palm_borassus_desert_sapling", |
3835 | - }, |
3836 | - fall = { |
3837 | - "remove=", |
3838 | - }, |
3839 | - }, |
3840 | - animations = { |
3841 | - idle = { |
3842 | - pictures = path.list_directory(dirname, "idle_\\d+.png"), |
3843 | - hotspot = { 24, 60 }, |
3844 | - fps = 10, |
3845 | - sound_effect = { |
3846 | - directory = "sound/animals", |
3847 | - name = "bird2", |
3848 | - }, |
3849 | - }, |
3850 | - }, |
3851 | -} |
3852 | |
3853 | === removed file 'world/immovables/trees/palm_borassus_desert_pole/init.lua' |
3854 | --- world/immovables/trees/palm_borassus_desert_pole/init.lua 2014-05-03 08:40:59 +0000 |
3855 | +++ world/immovables/trees/palm_borassus_desert_pole/init.lua 1970-01-01 00:00:00 +0000 |
3856 | @@ -1,23 +0,0 @@ |
3857 | -dirname = path.dirname(__file__) |
3858 | - |
3859 | -world:new_immovable_type{ |
3860 | - name = "palm_borassus_desert_pole", |
3861 | - descname = _ "Borassus Palm (Pole)", |
3862 | - editor_category = "trees_palm", |
3863 | - size = "small", |
3864 | - attributes = {}, |
3865 | - programs = { |
3866 | - program = { |
3867 | - "animate=idle 70000", |
3868 | - "remove=70", |
3869 | - "grow=palm_borassus_desert_mature", |
3870 | - }, |
3871 | - }, |
3872 | - animations = { |
3873 | - idle = { |
3874 | - pictures = path.list_directory(dirname, "idle_\\d+.png"), |
3875 | - hotspot = { 12, 28 }, |
3876 | - fps = 8, |
3877 | - }, |
3878 | - }, |
3879 | -} |
3880 | |
3881 | === removed file 'world/immovables/trees/palm_borassus_desert_sapling/init.lua' |
3882 | --- world/immovables/trees/palm_borassus_desert_sapling/init.lua 2014-05-03 08:40:59 +0000 |
3883 | +++ world/immovables/trees/palm_borassus_desert_sapling/init.lua 1970-01-01 00:00:00 +0000 |
3884 | @@ -1,23 +0,0 @@ |
3885 | -dirname = path.dirname(__file__) |
3886 | - |
3887 | -world:new_immovable_type{ |
3888 | - name = "palm_borassus_desert_sapling", |
3889 | - descname = _ "Borassus Palm (Sapling)", |
3890 | - editor_category = "trees_palm", |
3891 | - size = "small", |
3892 | - attributes = { "seed" }, |
3893 | - programs = { |
3894 | - program = { |
3895 | - "animate=idle 70000", |
3896 | - "remove=80", |
3897 | - "grow=palm_borassus_desert_pole", |
3898 | - }, |
3899 | - }, |
3900 | - animations = { |
3901 | - idle = { |
3902 | - pictures = path.list_directory(dirname, "idle_\\d+.png"), |
3903 | - hotspot = { 5, 12 }, |
3904 | - fps = 8, |
3905 | - }, |
3906 | - }, |
3907 | -} |
3908 | |
3909 | === added directory 'world/immovables/trees/palm_coconut' |
3910 | === added file 'world/immovables/trees/palm_coconut/init.lua' |
3911 | --- world/immovables/trees/palm_coconut/init.lua 1970-01-01 00:00:00 +0000 |
3912 | +++ world/immovables/trees/palm_coconut/init.lua 2014-07-06 08:25:52 +0000 |
3913 | @@ -0,0 +1,107 @@ |
3914 | +dirname = path.dirname(__file__) |
3915 | + |
3916 | +terrain_affinity = { |
3917 | + preferred_temperature = 313, |
3918 | + preferred_humidity = 0.2, |
3919 | + preferred_fertility = 0.1, |
3920 | + pickiness = 0.8, |
3921 | +} |
3922 | + |
3923 | +world:new_immovable_type{ |
3924 | + name = "palm_coconut_desert_sapling", |
3925 | + descname = _ "Coconut Palm (Sapling)", |
3926 | + editor_category = "trees_palm", |
3927 | + size = "small", |
3928 | + attributes = { "tree_sapling" }, |
3929 | + terrain_affinity = terrain_affinity, |
3930 | + programs = { |
3931 | + program = { |
3932 | + "animate=idle 55000", |
3933 | + "remove=42", |
3934 | + "grow=palm_coconut_desert_pole", |
3935 | + }, |
3936 | + }, |
3937 | + animations = { |
3938 | + idle = { |
3939 | + pictures = path.list_directory(dirname .. "sapling/", "idle_\\d+.png"), |
3940 | + hotspot = { 5, 12 }, |
3941 | + fps = 8, |
3942 | + }, |
3943 | + }, |
3944 | +} |
3945 | + |
3946 | +world:new_immovable_type{ |
3947 | + name = "palm_coconut_desert_pole", |
3948 | + descname = _ "Coconut Palm (Pole)", |
3949 | + editor_category = "trees_palm", |
3950 | + size = "small", |
3951 | + attributes = {}, |
3952 | + terrain_affinity = terrain_affinity, |
3953 | + programs = { |
3954 | + program = { |
3955 | + "animate=idle 55000", |
3956 | + "remove=33", |
3957 | + "grow=palm_coconut_desert_mature", |
3958 | + }, |
3959 | + }, |
3960 | + animations = { |
3961 | + idle = { |
3962 | + pictures = path.list_directory(dirname .. "pole/", "idle_\\d+.png"), |
3963 | + hotspot = { 12, 28 }, |
3964 | + fps = 8, |
3965 | + }, |
3966 | + }, |
3967 | +} |
3968 | + |
3969 | +world:new_immovable_type{ |
3970 | + name = "palm_coconut_desert_mature", |
3971 | + descname = _ "Coconut Palm (Mature)", |
3972 | + editor_category = "trees_palm", |
3973 | + size = "small", |
3974 | + attributes = {}, |
3975 | + terrain_affinity = terrain_affinity, |
3976 | + programs = { |
3977 | + program = { |
3978 | + "animate=idle 60000", |
3979 | + "remove=23", |
3980 | + "grow=palm_coconut_desert_old", |
3981 | + }, |
3982 | + }, |
3983 | + animations = { |
3984 | + idle = { |
3985 | + pictures = path.list_directory(dirname .. "mature/", "idle_\\d+.png"), |
3986 | + hotspot = { 18, 48 }, |
3987 | + fps = 8, |
3988 | + }, |
3989 | + }, |
3990 | +} |
3991 | + |
3992 | +world:new_immovable_type{ |
3993 | + name = "palm_coconut_desert_old", |
3994 | + descname = _ "Coconut Palm (Old)", |
3995 | + editor_category = "trees_palm", |
3996 | + size = "small", |
3997 | + attributes = { "tree" }, |
3998 | + terrain_affinity = terrain_affinity, |
3999 | + programs = { |
4000 | + program = { |
4001 | + "animate=idle 1550000", |
4002 | + "transform=deadtree6 36", |
4003 | + "seed=palm_coconut_desert_sapling", |
4004 | + }, |
4005 | + fall = { |
4006 | + "remove=", |
4007 | + }, |
4008 | + }, |
4009 | + animations = { |
4010 | + idle = { |
4011 | + pictures = path.list_directory(dirname .. "old/", "idle_\\d+.png"), |
4012 | + hotspot = { 24, 59 }, |
4013 | + fps = 10, |
4014 | + sound_effect = { |
4015 | + directory = "sound/animals", |
4016 | + name = "bird3", |
4017 | + }, |
4018 | + }, |
4019 | + }, |
4020 | +} |
4021 | |
4022 | === renamed directory 'world/immovables/trees/palm_coconut_desert_mature' => 'world/immovables/trees/palm_coconut/mature' |
4023 | === renamed directory 'world/immovables/trees/palm_coconut_desert_old' => 'world/immovables/trees/palm_coconut/old' |
4024 | === renamed directory 'world/immovables/trees/palm_coconut_desert_pole' => 'world/immovables/trees/palm_coconut/pole' |
4025 | === renamed directory 'world/immovables/trees/palm_coconut_desert_sapling' => 'world/immovables/trees/palm_coconut/sapling' |
4026 | === removed file 'world/immovables/trees/palm_coconut_desert_mature/init.lua' |
4027 | --- world/immovables/trees/palm_coconut_desert_mature/init.lua 2014-05-03 08:40:59 +0000 |
4028 | +++ world/immovables/trees/palm_coconut_desert_mature/init.lua 1970-01-01 00:00:00 +0000 |
4029 | @@ -1,23 +0,0 @@ |
4030 | -dirname = path.dirname(__file__) |
4031 | - |
4032 | -world:new_immovable_type{ |
4033 | - name = "palm_coconut_desert_mature", |
4034 | - descname = _ "Coconut Palm (Mature)", |
4035 | - editor_category = "trees_palm", |
4036 | - size = "small", |
4037 | - attributes = {}, |
4038 | - programs = { |
4039 | - program = { |
4040 | - "animate=idle 60000", |
4041 | - "remove=23", |
4042 | - "grow=palm_coconut_desert_old", |
4043 | - }, |
4044 | - }, |
4045 | - animations = { |
4046 | - idle = { |
4047 | - pictures = path.list_directory(dirname, "idle_\\d+.png"), |
4048 | - hotspot = { 18, 48 }, |
4049 | - fps = 8, |
4050 | - }, |
4051 | - }, |
4052 | -} |
4053 | |
4054 | === removed file 'world/immovables/trees/palm_coconut_desert_old/init.lua' |
4055 | --- world/immovables/trees/palm_coconut_desert_old/init.lua 2014-05-03 08:40:59 +0000 |
4056 | +++ world/immovables/trees/palm_coconut_desert_old/init.lua 1970-01-01 00:00:00 +0000 |
4057 | @@ -1,30 +0,0 @@ |
4058 | -dirname = path.dirname(__file__) |
4059 | - |
4060 | -world:new_immovable_type{ |
4061 | - name = "palm_coconut_desert_old", |
4062 | - descname = _ "Coconut Palm (Old)", |
4063 | - editor_category = "trees_palm", |
4064 | - size = "small", |
4065 | - attributes = { "tree" }, |
4066 | - programs = { |
4067 | - program = { |
4068 | - "animate=idle 1550000", |
4069 | - "transform=deadtree6 36", |
4070 | - "seed=palm_coconut_desert_sapling", |
4071 | - }, |
4072 | - fall = { |
4073 | - "remove=", |
4074 | - }, |
4075 | - }, |
4076 | - animations = { |
4077 | - idle = { |
4078 | - pictures = path.list_directory(dirname, "idle_\\d+.png"), |
4079 | - hotspot = { 24, 59 }, |
4080 | - fps = 10, |
4081 | - sound_effect = { |
4082 | - directory = "sound/animals", |
4083 | - name = "bird3", |
4084 | - }, |
4085 | - }, |
4086 | - }, |
4087 | -} |
4088 | |
4089 | === removed file 'world/immovables/trees/palm_coconut_desert_pole/init.lua' |
4090 | --- world/immovables/trees/palm_coconut_desert_pole/init.lua 2014-05-03 08:40:59 +0000 |
4091 | +++ world/immovables/trees/palm_coconut_desert_pole/init.lua 1970-01-01 00:00:00 +0000 |
4092 | @@ -1,23 +0,0 @@ |
4093 | -dirname = path.dirname(__file__) |
4094 | - |
4095 | -world:new_immovable_type{ |
4096 | - name = "palm_coconut_desert_pole", |
4097 | - descname = _ "Coconut Palm (Pole)", |
4098 | - editor_category = "trees_palm", |
4099 | - size = "small", |
4100 | - attributes = {}, |
4101 | - programs = { |
4102 | - program = { |
4103 | - "animate=idle 55000", |
4104 | - "remove=33", |
4105 | - "grow=palm_coconut_desert_mature", |
4106 | - }, |
4107 | - }, |
4108 | - animations = { |
4109 | - idle = { |
4110 | - pictures = path.list_directory(dirname, "idle_\\d+.png"), |
4111 | - hotspot = { 12, 28 }, |
4112 | - fps = 8, |
4113 | - }, |
4114 | - }, |
4115 | -} |
4116 | |
4117 | === removed file 'world/immovables/trees/palm_coconut_desert_sapling/init.lua' |
4118 | --- world/immovables/trees/palm_coconut_desert_sapling/init.lua 2014-05-03 08:40:59 +0000 |
4119 | +++ world/immovables/trees/palm_coconut_desert_sapling/init.lua 1970-01-01 00:00:00 +0000 |
4120 | @@ -1,23 +0,0 @@ |
4121 | -dirname = path.dirname(__file__) |
4122 | - |
4123 | -world:new_immovable_type{ |
4124 | - name = "palm_coconut_desert_sapling", |
4125 | - descname = _ "Coconut Palm (Sapling)", |
4126 | - editor_category = "trees_palm", |
4127 | - size = "small", |
4128 | - attributes = { "seed" }, |
4129 | - programs = { |
4130 | - program = { |
4131 | - "animate=idle 55000", |
4132 | - "remove=42", |
4133 | - "grow=palm_coconut_desert_pole", |
4134 | - }, |
4135 | - }, |
4136 | - animations = { |
4137 | - idle = { |
4138 | - pictures = path.list_directory(dirname, "idle_\\d+.png"), |
4139 | - hotspot = { 5, 12 }, |
4140 | - fps = 8, |
4141 | - }, |
4142 | - }, |
4143 | -} |
4144 | |
4145 | === added directory 'world/immovables/trees/palm_date' |
4146 | === added file 'world/immovables/trees/palm_date/init.lua' |
4147 | --- world/immovables/trees/palm_date/init.lua 1970-01-01 00:00:00 +0000 |
4148 | +++ world/immovables/trees/palm_date/init.lua 2014-07-06 08:25:52 +0000 |
4149 | @@ -0,0 +1,110 @@ |
4150 | +dirname = path.dirname(__file__) |
4151 | + |
4152 | +terrain_affinity = { |
4153 | + preferred_temperature = 318, |
4154 | + preferred_humidity = 0.3, |
4155 | + preferred_fertility = 0.3, |
4156 | + pickiness = 0.8, |
4157 | +} |
4158 | + |
4159 | +world:new_immovable_type{ |
4160 | + name = "palm_date_desert_sapling", |
4161 | + descname = _ "Date Palm (Sapling)", |
4162 | + editor_category = "trees_palm", |
4163 | + size = "small", |
4164 | + attributes = { "tree_sapling" }, |
4165 | + terrain_affinity = terrain_affinity, |
4166 | + programs = { |
4167 | + program = { |
4168 | + "animate=idle 38000", |
4169 | + "remove=50", |
4170 | + "grow=palm_date_desert_pole", |
4171 | + }, |
4172 | + }, |
4173 | + animations = { |
4174 | + idle = { |
4175 | + pictures = path.list_directory(dirname .. "sapling/", "idle_\\d+.png"), |
4176 | + hotspot = { 5, 12 }, |
4177 | + fps = 8, |
4178 | + }, |
4179 | + }, |
4180 | +} |
4181 | + |
4182 | +world:new_immovable_type{ |
4183 | + name = "palm_date_desert_pole", |
4184 | + descname = _ "Date Palm (Pole)", |
4185 | + editor_category = "trees_palm", |
4186 | + size = "small", |
4187 | + attributes = {}, |
4188 | + terrain_affinity = terrain_affinity, |
4189 | + programs = { |
4190 | + program = { |
4191 | + "animate=idle 38000", |
4192 | + "remove=47", |
4193 | + "grow=palm_date_desert_mature", |
4194 | + }, |
4195 | + }, |
4196 | + animations = { |
4197 | + idle = { |
4198 | + pictures = path.list_directory(dirname .. "pole/", "idle_\\d+.png"), |
4199 | + hotspot = { 12, 28 }, |
4200 | + fps = 8, |
4201 | + }, |
4202 | + }, |
4203 | +} |
4204 | + |
4205 | +world:new_immovable_type{ |
4206 | + name = "palm_date_desert_mature", |
4207 | + descname = _ "Date Palm (Mature)", |
4208 | + editor_category = "trees_palm", |
4209 | + size = "small", |
4210 | + attributes = {}, |
4211 | + terrain_affinity = terrain_affinity, |
4212 | + programs = { |
4213 | + program = { |
4214 | + "animate=idle 20000", |
4215 | + "remove=30", |
4216 | + "seed=palm_date_desert_sapling", |
4217 | + "animate=idle 20000", |
4218 | + "remove=20", |
4219 | + "grow=palm_date_desert_old", |
4220 | + }, |
4221 | + }, |
4222 | + animations = { |
4223 | + idle = { |
4224 | + pictures = path.list_directory(dirname .. "mature/", "idle_\\d+.png"), |
4225 | + hotspot = { 18, 48 }, |
4226 | + fps = 8, |
4227 | + }, |
4228 | + }, |
4229 | +} |
4230 | + |
4231 | +world:new_immovable_type{ |
4232 | + name = "palm_date_desert_old", |
4233 | + descname = _ "Date Palm (Old)", |
4234 | + editor_category = "trees_palm", |
4235 | + size = "small", |
4236 | + attributes = { "tree" }, |
4237 | + terrain_affinity = terrain_affinity, |
4238 | + programs = { |
4239 | + program = { |
4240 | + "animate=idle 1050000", |
4241 | + "transform=deadtree5 32", |
4242 | + "seed=palm_date_desert_sapling", |
4243 | + }, |
4244 | + fall = { |
4245 | + "remove=", |
4246 | + }, |
4247 | + }, |
4248 | + animations = { |
4249 | + idle = { |
4250 | + pictures = path.list_directory(dirname .. "old/", "idle_\\d+.png"), |
4251 | + hotspot = { 24, 60 }, |
4252 | + fps = 10, |
4253 | + sound_effect = { |
4254 | + directory = "sound/animals", |
4255 | + name = "bird1", |
4256 | + }, |
4257 | + }, |
4258 | + }, |
4259 | +} |
4260 | |
4261 | === renamed directory 'world/immovables/trees/palm_date_desert_mature' => 'world/immovables/trees/palm_date/mature' |
4262 | === renamed directory 'world/immovables/trees/palm_date_desert_old' => 'world/immovables/trees/palm_date/old' |
4263 | === renamed directory 'world/immovables/trees/palm_date_desert_pole' => 'world/immovables/trees/palm_date/pole' |
4264 | === renamed directory 'world/immovables/trees/palm_date_desert_sapling' => 'world/immovables/trees/palm_date/sapling' |
4265 | === removed file 'world/immovables/trees/palm_date_desert_mature/init.lua' |
4266 | --- world/immovables/trees/palm_date_desert_mature/init.lua 2014-05-03 08:40:59 +0000 |
4267 | +++ world/immovables/trees/palm_date_desert_mature/init.lua 1970-01-01 00:00:00 +0000 |
4268 | @@ -1,26 +0,0 @@ |
4269 | -dirname = path.dirname(__file__) |
4270 | - |
4271 | -world:new_immovable_type{ |
4272 | - name = "palm_date_desert_mature", |
4273 | - descname = _ "Date Palm (Mature)", |
4274 | - editor_category = "trees_palm", |
4275 | - size = "small", |
4276 | - attributes = {}, |
4277 | - programs = { |
4278 | - program = { |
4279 | - "animate=idle 20000", |
4280 | - "remove=30", |
4281 | - "seed=palm_date_desert_sapling", |
4282 | - "animate=idle 20000", |
4283 | - "remove=20", |
4284 | - "grow=palm_date_desert_old", |
4285 | - }, |
4286 | - }, |
4287 | - animations = { |
4288 | - idle = { |
4289 | - pictures = path.list_directory(dirname, "idle_\\d+.png"), |
4290 | - hotspot = { 18, 48 }, |
4291 | - fps = 8, |
4292 | - }, |
4293 | - }, |
4294 | -} |
4295 | |
4296 | === removed file 'world/immovables/trees/palm_date_desert_old/init.lua' |
4297 | --- world/immovables/trees/palm_date_desert_old/init.lua 2014-05-03 08:40:59 +0000 |
4298 | +++ world/immovables/trees/palm_date_desert_old/init.lua 1970-01-01 00:00:00 +0000 |
4299 | @@ -1,30 +0,0 @@ |
4300 | -dirname = path.dirname(__file__) |
4301 | - |
4302 | -world:new_immovable_type{ |
4303 | - name = "palm_date_desert_old", |
4304 | - descname = _ "Date Palm (Old)", |
4305 | - editor_category = "trees_palm", |
4306 | - size = "small", |
4307 | - attributes = { "tree" }, |
4308 | - programs = { |
4309 | - program = { |
4310 | - "animate=idle 1050000", |
4311 | - "transform=deadtree5 32", |
4312 | - "seed=palm_date_desert_sapling", |
4313 | - }, |
4314 | - fall = { |
4315 | - "remove=", |
4316 | - }, |
4317 | - }, |
4318 | - animations = { |
4319 | - idle = { |
4320 | - pictures = path.list_directory(dirname, "idle_\\d+.png"), |
4321 | - hotspot = { 24, 60 }, |
4322 | - fps = 10, |
4323 | - sound_effect = { |
4324 | - directory = "sound/animals", |
4325 | - name = "bird1", |
4326 | - }, |
4327 | - }, |
4328 | - }, |
4329 | -} |
4330 | |
4331 | === removed file 'world/immovables/trees/palm_date_desert_pole/init.lua' |
4332 | --- world/immovables/trees/palm_date_desert_pole/init.lua 2014-05-03 08:40:59 +0000 |
4333 | +++ world/immovables/trees/palm_date_desert_pole/init.lua 1970-01-01 00:00:00 +0000 |
4334 | @@ -1,23 +0,0 @@ |
4335 | -dirname = path.dirname(__file__) |
4336 | - |
4337 | -world:new_immovable_type{ |
4338 | - name = "palm_date_desert_pole", |
4339 | - descname = _ "Date Palm (Pole)", |
4340 | - editor_category = "trees_palm", |
4341 | - size = "small", |
4342 | - attributes = {}, |
4343 | - programs = { |
4344 | - program = { |
4345 | - "animate=idle 38000", |
4346 | - "remove=47", |
4347 | - "grow=palm_date_desert_mature", |
4348 | - }, |
4349 | - }, |
4350 | - animations = { |
4351 | - idle = { |
4352 | - pictures = path.list_directory(dirname, "idle_\\d+.png"), |
4353 | - hotspot = { 12, 28 }, |
4354 | - fps = 8, |
4355 | - }, |
4356 | - }, |
4357 | -} |
4358 | |
4359 | === removed file 'world/immovables/trees/palm_date_desert_sapling/init.lua' |
4360 | --- world/immovables/trees/palm_date_desert_sapling/init.lua 2014-05-03 08:40:59 +0000 |
4361 | +++ world/immovables/trees/palm_date_desert_sapling/init.lua 1970-01-01 00:00:00 +0000 |
4362 | @@ -1,23 +0,0 @@ |
4363 | -dirname = path.dirname(__file__) |
4364 | - |
4365 | -world:new_immovable_type{ |
4366 | - name = "palm_date_desert_sapling", |
4367 | - descname = _ "Date Palm (Sapling)", |
4368 | - editor_category = "trees_palm", |
4369 | - size = "small", |
4370 | - attributes = { "seed" }, |
4371 | - programs = { |
4372 | - program = { |
4373 | - "animate=idle 38000", |
4374 | - "remove=50", |
4375 | - "grow=palm_date_desert_pole", |
4376 | - }, |
4377 | - }, |
4378 | - animations = { |
4379 | - idle = { |
4380 | - pictures = path.list_directory(dirname, "idle_\\d+.png"), |
4381 | - hotspot = { 5, 12 }, |
4382 | - fps = 8, |
4383 | - }, |
4384 | - }, |
4385 | -} |
4386 | |
4387 | === added directory 'world/immovables/trees/palm_oil' |
4388 | === added file 'world/immovables/trees/palm_oil/init.lua' |
4389 | --- world/immovables/trees/palm_oil/init.lua 1970-01-01 00:00:00 +0000 |
4390 | +++ world/immovables/trees/palm_oil/init.lua 2014-07-06 08:25:52 +0000 |
4391 | @@ -0,0 +1,111 @@ |
4392 | +dirname = path.dirname(__file__) |
4393 | + |
4394 | +terrain_affinity = { |
4395 | + preferred_temperature = 308, |
4396 | + preferred_humidity = 0.6, |
4397 | + preferred_fertility = 0.65, |
4398 | + pickiness = 0.8, |
4399 | +} |
4400 | + |
4401 | +world:new_immovable_type{ |
4402 | + name = "palm_oil_desert_sapling", |
4403 | + descname = _ "Oil Palm (Sapling)", |
4404 | + editor_category = "trees_palm", |
4405 | + size = "small", |
4406 | + attributes = { "tree_sapling" }, |
4407 | + terrain_affinity = terrain_affinity, |
4408 | + programs = { |
4409 | + program = { |
4410 | + "animate=idle 42000", |
4411 | + "remove=32", |
4412 | + "grow=palm_oil_desert_pole", |
4413 | + }, |
4414 | + }, |
4415 | + animations = { |
4416 | + idle = { |
4417 | + pictures = path.list_directory(dirname .. "sapling/", "idle_\\d+.png"), |
4418 | + hotspot = { 5, 12 }, |
4419 | + fps = 8, |
4420 | + }, |
4421 | + }, |
4422 | +} |
4423 | + |
4424 | +world:new_immovable_type{ |
4425 | + name = "palm_oil_desert_pole", |
4426 | + descname = _ "Oil Palm (Pole)", |
4427 | + editor_category = "trees_palm", |
4428 | + size = "small", |
4429 | + attributes = {}, |
4430 | + terrain_affinity = terrain_affinity, |
4431 | + programs = { |
4432 | + program = { |
4433 | + "animate=idle 40000", |
4434 | + "remove=25", |
4435 | + "grow=palm_oil_desert_mature", |
4436 | + }, |
4437 | + }, |
4438 | + animations = { |
4439 | + idle = { |
4440 | + pictures = path.list_directory(dirname .. "pole/", "idle_\\d+.png"), |
4441 | + hotspot = { 12, 28 }, |
4442 | + fps = 8, |
4443 | + }, |
4444 | + }, |
4445 | +} |
4446 | + |
4447 | +world:new_immovable_type{ |
4448 | + name = "palm_oil_desert_mature", |
4449 | + descname = _ "Oil Palm (Mature)", |
4450 | + editor_category = "trees_palm", |
4451 | + size = "small", |
4452 | + attributes = {}, |
4453 | + terrain_affinity = terrain_affinity, |
4454 | + programs = { |
4455 | + program = { |
4456 | + "animate=idle 25000", |
4457 | + "remove=10", |
4458 | + "seed=palm_oil_desert_sapling", |
4459 | + "animate=idle 30000", |
4460 | + "remove=10", |
4461 | + "grow=palm_oil_desert_old", |
4462 | + |
4463 | + }, |
4464 | + }, |
4465 | + animations = { |
4466 | + idle = { |
4467 | + pictures = path.list_directory(dirname .. "mature/", "idle_\\d+.png"), |
4468 | + hotspot = { 18, 48 }, |
4469 | + fps = 8, |
4470 | + }, |
4471 | + }, |
4472 | +} |
4473 | + |
4474 | +world:new_immovable_type{ |
4475 | + name = "palm_oil_desert_old", |
4476 | + descname = _ "Oil Palm (Old)", |
4477 | + editor_category = "trees_palm", |
4478 | + size = "small", |
4479 | + attributes = { "tree" }, |
4480 | + terrain_affinity = terrain_affinity, |
4481 | + programs = { |
4482 | + program = { |
4483 | + "animate=idle 800000", |
4484 | + "transform=deadtree5 50", |
4485 | + "seed=palm_oil_desert_sapling", |
4486 | + }, |
4487 | + fall = { |
4488 | + "remove=", |
4489 | + }, |
4490 | + }, |
4491 | + animations = { |
4492 | + idle = { |
4493 | + pictures = path.list_directory(dirname .. "old/", "idle_\\d+.png"), |
4494 | + hotspot = { 24, 60 }, |
4495 | + fps = 10, |
4496 | + sound_effect = { |
4497 | + directory = "sound/animals", |
4498 | + name = "bird5", |
4499 | + }, |
4500 | + }, |
4501 | + }, |
4502 | +} |
4503 | |
4504 | === renamed directory 'world/immovables/trees/palm_oil_desert_mature' => 'world/immovables/trees/palm_oil/mature' |
4505 | === renamed directory 'world/immovables/trees/palm_oil_desert_old' => 'world/immovables/trees/palm_oil/old' |
4506 | === renamed directory 'world/immovables/trees/palm_oil_desert_pole' => 'world/immovables/trees/palm_oil/pole' |
4507 | === renamed directory 'world/immovables/trees/palm_oil_desert_sapling' => 'world/immovables/trees/palm_oil/sapling' |
4508 | === removed file 'world/immovables/trees/palm_oil_desert_mature/init.lua' |
4509 | --- world/immovables/trees/palm_oil_desert_mature/init.lua 2014-05-03 08:40:59 +0000 |
4510 | +++ world/immovables/trees/palm_oil_desert_mature/init.lua 1970-01-01 00:00:00 +0000 |
4511 | @@ -1,27 +0,0 @@ |
4512 | -dirname = path.dirname(__file__) |
4513 | - |
4514 | -world:new_immovable_type{ |
4515 | - name = "palm_oil_desert_mature", |
4516 | - descname = _ "Oil Palm (Mature)", |
4517 | - editor_category = "trees_palm", |
4518 | - size = "small", |
4519 | - attributes = {}, |
4520 | - programs = { |
4521 | - program = { |
4522 | - "animate=idle 25000", |
4523 | - "remove=10", |
4524 | - "seed=palm_oil_desert_sapling", |
4525 | - "animate=idle 30000", |
4526 | - "remove=10", |
4527 | - "grow=palm_oil_desert_old", |
4528 | - |
4529 | - }, |
4530 | - }, |
4531 | - animations = { |
4532 | - idle = { |
4533 | - pictures = path.list_directory(dirname, "idle_\\d+.png"), |
4534 | - hotspot = { 18, 48 }, |
4535 | - fps = 8, |
4536 | - }, |
4537 | - }, |
4538 | -} |
4539 | |
4540 | === removed file 'world/immovables/trees/palm_oil_desert_old/init.lua' |
4541 | --- world/immovables/trees/palm_oil_desert_old/init.lua 2014-05-03 08:40:59 +0000 |
4542 | +++ world/immovables/trees/palm_oil_desert_old/init.lua 1970-01-01 00:00:00 +0000 |
4543 | @@ -1,30 +0,0 @@ |
4544 | -dirname = path.dirname(__file__) |
4545 | - |
4546 | -world:new_immovable_type{ |
4547 | - name = "palm_oil_desert_old", |
4548 | - descname = _ "Oil Palm (Old)", |
4549 | - editor_category = "trees_palm", |
4550 | - size = "small", |
4551 | - attributes = { "tree" }, |
4552 | - programs = { |
4553 | - program = { |
4554 | - "animate=idle 800000", |
4555 | - "transform=deadtree5 50", |
4556 | - "seed=palm_oil_desert_sapling", |
4557 | - }, |
4558 | - fall = { |
4559 | - "remove=", |
4560 | - }, |
4561 | - }, |
4562 | - animations = { |
4563 | - idle = { |
4564 | - pictures = path.list_directory(dirname, "idle_\\d+.png"), |
4565 | - hotspot = { 24, 60 }, |
4566 | - fps = 10, |
4567 | - sound_effect = { |
4568 | - directory = "sound/animals", |
4569 | - name = "bird5", |
4570 | - }, |
4571 | - }, |
4572 | - }, |
4573 | -} |
4574 | |
4575 | === removed file 'world/immovables/trees/palm_oil_desert_pole/init.lua' |
4576 | --- world/immovables/trees/palm_oil_desert_pole/init.lua 2014-05-03 08:40:59 +0000 |
4577 | +++ world/immovables/trees/palm_oil_desert_pole/init.lua 1970-01-01 00:00:00 +0000 |
4578 | @@ -1,23 +0,0 @@ |
4579 | -dirname = path.dirname(__file__) |
4580 | - |
4581 | -world:new_immovable_type{ |
4582 | - name = "palm_oil_desert_pole", |
4583 | - descname = _ "Oil Palm (Pole)", |
4584 | - editor_category = "trees_palm", |
4585 | - size = "small", |
4586 | - attributes = {}, |
4587 | - programs = { |
4588 | - program = { |
4589 | - "animate=idle 40000", |
4590 | - "remove=25", |
4591 | - "grow=palm_oil_desert_mature", |
4592 | - }, |
4593 | - }, |
4594 | - animations = { |
4595 | - idle = { |
4596 | - pictures = path.list_directory(dirname, "idle_\\d+.png"), |
4597 | - hotspot = { 12, 28 }, |
4598 | - fps = 8, |
4599 | - }, |
4600 | - }, |
4601 | -} |
4602 | |
4603 | === removed file 'world/immovables/trees/palm_oil_desert_sapling/init.lua' |
4604 | --- world/immovables/trees/palm_oil_desert_sapling/init.lua 2014-05-03 08:40:59 +0000 |
4605 | +++ world/immovables/trees/palm_oil_desert_sapling/init.lua 1970-01-01 00:00:00 +0000 |
4606 | @@ -1,23 +0,0 @@ |
4607 | -dirname = path.dirname(__file__) |
4608 | - |
4609 | -world:new_immovable_type{ |
4610 | - name = "palm_oil_desert_sapling", |
4611 | - descname = _ "Oil Palm (Sapling)", |
4612 | - editor_category = "trees_palm", |
4613 | - size = "small", |
4614 | - attributes = { "seed" }, |
4615 | - programs = { |
4616 | - program = { |
4617 | - "animate=idle 42000", |
4618 | - "remove=32", |
4619 | - "grow=palm_oil_desert_pole", |
4620 | - }, |
4621 | - }, |
4622 | - animations = { |
4623 | - idle = { |
4624 | - pictures = path.list_directory(dirname, "idle_\\d+.png"), |
4625 | - hotspot = { 5, 12 }, |
4626 | - fps = 8, |
4627 | - }, |
4628 | - }, |
4629 | -} |
4630 | |
4631 | === added directory 'world/immovables/trees/palm_roystonea' |
4632 | === added file 'world/immovables/trees/palm_roystonea/init.lua' |
4633 | --- world/immovables/trees/palm_roystonea/init.lua 1970-01-01 00:00:00 +0000 |
4634 | +++ world/immovables/trees/palm_roystonea/init.lua 2014-07-06 08:25:52 +0000 |
4635 | @@ -0,0 +1,107 @@ |
4636 | +dirname = path.dirname(__file__) |
4637 | + |
4638 | +terrain_affinity = { |
4639 | + preferred_temperature = 313, |
4640 | + preferred_humidity = 0.6, |
4641 | + preferred_fertility = 0.55, |
4642 | + pickiness = 0.7, |
4643 | +} |
4644 | + |
4645 | +world:new_immovable_type{ |
4646 | + name = "palm_roystonea_desert_sapling", |
4647 | + descname = _ "Roystonea regia Palm (Sapling)", |
4648 | + editor_category = "trees_palm", |
4649 | + size = "small", |
4650 | + attributes = { "tree_sapling" }, |
4651 | + terrain_affinity = terrain_affinity, |
4652 | + programs = { |
4653 | + program = { |
4654 | + "animate=idle 57500", |
4655 | + "remove=21", |
4656 | + "grow=palm_roystonea_desert_pole", |
4657 | + }, |
4658 | + }, |
4659 | + animations = { |
4660 | + idle = { |
4661 | + pictures = path.list_directory(dirname .. "sapling/", "idle_\\d+.png"), |
4662 | + hotspot = { 5, 12 }, |
4663 | + fps = 8, |
4664 | + }, |
4665 | + }, |
4666 | +} |
4667 | + |
4668 | +world:new_immovable_type{ |
4669 | + name = "palm_roystonea_desert_pole", |
4670 | + descname = _ "Roystonea regia Palm (Pole)", |
4671 | + editor_category = "trees_palm", |
4672 | + size = "small", |
4673 | + attributes = {}, |
4674 | + terrain_affinity = terrain_affinity, |
4675 | + programs = { |
4676 | + program = { |
4677 | + "animate=idle 52500", |
4678 | + "remove=19", |
4679 | + "grow=palm_roystonea_desert_mature", |
4680 | + }, |
4681 | + }, |
4682 | + animations = { |
4683 | + idle = { |
4684 | + pictures = path.list_directory(dirname .. "pole/", "idle_\\d+.png"), |
4685 | + hotspot = { 12, 28 }, |
4686 | + fps = 8, |
4687 | + }, |
4688 | + }, |
4689 | +} |
4690 | + |
4691 | +world:new_immovable_type{ |
4692 | + name = "palm_roystonea_desert_mature", |
4693 | + descname = _ "Roystonea regia Palm (Mature)", |
4694 | + editor_category = "trees_palm", |
4695 | + size = "small", |
4696 | + attributes = {}, |
4697 | + terrain_affinity = terrain_affinity, |
4698 | + programs = { |
4699 | + program = { |
4700 | + "animate=idle 50000", |
4701 | + "remove=18", |
4702 | + "grow=palm_roystonea_desert_old", |
4703 | + }, |
4704 | + }, |
4705 | + animations = { |
4706 | + idle = { |
4707 | + pictures = path.list_directory(dirname .. "mature/", "idle_\\d+.png"), |
4708 | + hotspot = { 18, 48 }, |
4709 | + fps = 8, |
4710 | + }, |
4711 | + }, |
4712 | +} |
4713 | + |
4714 | +world:new_immovable_type{ |
4715 | + name = "palm_roystonea_desert_old", |
4716 | + descname = _ "Roystonea regia Palm (Old)", |
4717 | + editor_category = "trees_palm", |
4718 | + size = "small", |
4719 | + attributes = { "tree" }, |
4720 | + terrain_affinity = terrain_affinity, |
4721 | + programs = { |
4722 | + program = { |
4723 | + "animate=idle 1550000", |
4724 | + "transform=deadtree4 39", |
4725 | + "seed=palm_roystonea_desert_sapling", |
4726 | + }, |
4727 | + fall = { |
4728 | + "remove=", |
4729 | + }, |
4730 | + }, |
4731 | + animations = { |
4732 | + idle = { |
4733 | + pictures = path.list_directory(dirname .. "old/", "idle_\\d+.png"), |
4734 | + hotspot = { 24, 60 }, |
4735 | + fps = 10, |
4736 | + sound_effect = { |
4737 | + directory = "sound/animals", |
4738 | + name = "bird4", |
4739 | + }, |
4740 | + }, |
4741 | + }, |
4742 | +} |
4743 | |
4744 | === renamed directory 'world/immovables/trees/palm_roystonea_desert_mature' => 'world/immovables/trees/palm_roystonea/mature' |
4745 | === renamed directory 'world/immovables/trees/palm_roystonea_desert_old' => 'world/immovables/trees/palm_roystonea/old' |
4746 | === renamed directory 'world/immovables/trees/palm_roystonea_desert_pole' => 'world/immovables/trees/palm_roystonea/pole' |
4747 | === renamed directory 'world/immovables/trees/palm_roystonea_desert_sapling' => 'world/immovables/trees/palm_roystonea/sapling' |
4748 | === removed file 'world/immovables/trees/palm_roystonea_desert_mature/init.lua' |
4749 | --- world/immovables/trees/palm_roystonea_desert_mature/init.lua 2014-05-03 08:40:59 +0000 |
4750 | +++ world/immovables/trees/palm_roystonea_desert_mature/init.lua 1970-01-01 00:00:00 +0000 |
4751 | @@ -1,23 +0,0 @@ |
4752 | -dirname = path.dirname(__file__) |
4753 | - |
4754 | -world:new_immovable_type{ |
4755 | - name = "palm_roystonea_desert_mature", |
4756 | - descname = _ "Roystonea regia Palm (Mature)", |
4757 | - editor_category = "trees_palm", |
4758 | - size = "small", |
4759 | - attributes = {}, |
4760 | - programs = { |
4761 | - program = { |
4762 | - "animate=idle 50000", |
4763 | - "remove=18", |
4764 | - "grow=palm_roystonea_desert_old", |
4765 | - }, |
4766 | - }, |
4767 | - animations = { |
4768 | - idle = { |
4769 | - pictures = path.list_directory(dirname, "idle_\\d+.png"), |
4770 | - hotspot = { 18, 48 }, |
4771 | - fps = 8, |
4772 | - }, |
4773 | - }, |
4774 | -} |
4775 | |
4776 | === removed file 'world/immovables/trees/palm_roystonea_desert_old/init.lua' |
4777 | --- world/immovables/trees/palm_roystonea_desert_old/init.lua 2014-05-03 08:40:59 +0000 |
4778 | +++ world/immovables/trees/palm_roystonea_desert_old/init.lua 1970-01-01 00:00:00 +0000 |
4779 | @@ -1,30 +0,0 @@ |
4780 | -dirname = path.dirname(__file__) |
4781 | - |
4782 | -world:new_immovable_type{ |
4783 | - name = "palm_roystonea_desert_old", |
4784 | - descname = _ "Roystonea regia Palm (Old)", |
4785 | - editor_category = "trees_palm", |
4786 | - size = "small", |
4787 | - attributes = { "tree" }, |
4788 | - programs = { |
4789 | - program = { |
4790 | - "animate=idle 1550000", |
4791 | - "transform=deadtree4 39", |
4792 | - "seed=palm_roystonea_desert_sapling", |
4793 | - }, |
4794 | - fall = { |
4795 | - "remove=", |
4796 | - }, |
4797 | - }, |
4798 | - animations = { |
4799 | - idle = { |
4800 | - pictures = path.list_directory(dirname, "idle_\\d+.png"), |
4801 | - hotspot = { 24, 60 }, |
4802 | - fps = 10, |
4803 | - sound_effect = { |
4804 | - directory = "sound/animals", |
4805 | - name = "bird4", |
4806 | - }, |
4807 | - }, |
4808 | - }, |
4809 | -} |
4810 | |
4811 | === removed file 'world/immovables/trees/palm_roystonea_desert_pole/init.lua' |
4812 | --- world/immovables/trees/palm_roystonea_desert_pole/init.lua 2014-05-03 08:40:59 +0000 |
4813 | +++ world/immovables/trees/palm_roystonea_desert_pole/init.lua 1970-01-01 00:00:00 +0000 |
4814 | @@ -1,23 +0,0 @@ |
4815 | -dirname = path.dirname(__file__) |
4816 | - |
4817 | -world:new_immovable_type{ |
4818 | - name = "palm_roystonea_desert_pole", |
4819 | - descname = _ "Roystonea regia Palm (Pole)", |
4820 | - editor_category = "trees_palm", |
4821 | - size = "small", |
4822 | - attributes = {}, |
4823 | - programs = { |
4824 | - program = { |
4825 | - "animate=idle 52500", |
4826 | - "remove=19", |
4827 | - "grow=palm_roystonea_desert_mature", |
4828 | - }, |
4829 | - }, |
4830 | - animations = { |
4831 | - idle = { |
4832 | - pictures = path.list_directory(dirname, "idle_\\d+.png"), |
4833 | - hotspot = { 12, 28 }, |
4834 | - fps = 8, |
4835 | - }, |
4836 | - }, |
4837 | -} |
4838 | |
4839 | === removed file 'world/immovables/trees/palm_roystonea_desert_sapling/init.lua' |
4840 | --- world/immovables/trees/palm_roystonea_desert_sapling/init.lua 2014-05-03 08:40:59 +0000 |
4841 | +++ world/immovables/trees/palm_roystonea_desert_sapling/init.lua 1970-01-01 00:00:00 +0000 |
4842 | @@ -1,23 +0,0 @@ |
4843 | -dirname = path.dirname(__file__) |
4844 | - |
4845 | -world:new_immovable_type{ |
4846 | - name = "palm_roystonea_desert_sapling", |
4847 | - descname = _ "Roystonea regia Palm (Sapling)", |
4848 | - editor_category = "trees_palm", |
4849 | - size = "small", |
4850 | - attributes = { "seed" }, |
4851 | - programs = { |
4852 | - program = { |
4853 | - "animate=idle 57500", |
4854 | - "remove=21", |
4855 | - "grow=palm_roystonea_desert_pole", |
4856 | - }, |
4857 | - }, |
4858 | - animations = { |
4859 | - idle = { |
4860 | - pictures = path.list_directory(dirname, "idle_\\d+.png"), |
4861 | - hotspot = { 5, 12 }, |
4862 | - fps = 8, |
4863 | - }, |
4864 | - }, |
4865 | -} |
4866 | |
4867 | === added directory 'world/immovables/trees/rowan' |
4868 | === added file 'world/immovables/trees/rowan/init.lua' |
4869 | --- world/immovables/trees/rowan/init.lua 1970-01-01 00:00:00 +0000 |
4870 | +++ world/immovables/trees/rowan/init.lua 2014-07-06 08:25:52 +0000 |
4871 | @@ -0,0 +1,110 @@ |
4872 | +dirname = path.dirname(__file__) |
4873 | + |
4874 | +terrain_affinity = { |
4875 | + preferred_temperature = 298, |
4876 | + preferred_humidity = 0.43, |
4877 | + preferred_fertility = 0.85, |
4878 | + pickiness = 0.5, |
4879 | +} |
4880 | + |
4881 | +world:new_immovable_type{ |
4882 | + name = "rowan_summer_sapling", |
4883 | + descname = _ "Rowan (Sapling)", |
4884 | + editor_category = "trees_deciduous", |
4885 | + size = "small", |
4886 | + attributes = { "tree_sapling" }, |
4887 | + terrain_affinity = terrain_affinity, |
4888 | + programs = { |
4889 | + program = { |
4890 | + "animate=idle 60000", |
4891 | + "remove=40", |
4892 | + "grow=rowan_summer_pole", |
4893 | + }, |
4894 | + }, |
4895 | + animations = { |
4896 | + idle = { |
4897 | + pictures = path.list_directory(dirname .. "sapling/", "idle_\\d+.png"), |
4898 | + hotspot = { 5, 12 }, |
4899 | + fps = 8, |
4900 | + }, |
4901 | + }, |
4902 | +} |
4903 | + |
4904 | +world:new_immovable_type{ |
4905 | + name = "rowan_summer_pole", |
4906 | + descname = _ "Rowan (Pole)", |
4907 | + editor_category = "trees_deciduous", |
4908 | + size = "small", |
4909 | + attributes = {}, |
4910 | + terrain_affinity = terrain_affinity, |
4911 | + programs = { |
4912 | + program = { |
4913 | + "animate=idle 55000", |
4914 | + "remove=30", |
4915 | + "grow=rowan_summer_mature", |
4916 | + }, |
4917 | + }, |
4918 | + animations = { |
4919 | + idle = { |
4920 | + pictures = path.list_directory(dirname .. "pole/", "idle_\\d+.png"), |
4921 | + hotspot = { 12, 28 }, |
4922 | + fps = 8, |
4923 | + }, |
4924 | + }, |
4925 | +} |
4926 | + |
4927 | +world:new_immovable_type{ |
4928 | + name = "rowan_summer_mature", |
4929 | + descname = _ "Rowan (Mature)", |
4930 | + editor_category = "trees_deciduous", |
4931 | + size = "small", |
4932 | + attributes = {}, |
4933 | + terrain_affinity = terrain_affinity, |
4934 | + programs = { |
4935 | + program = { |
4936 | + "animate=idle 55000", |
4937 | + "remove=7", |
4938 | + "seed=rowan_summer_sapling", |
4939 | + "animate=idle 30000", |
4940 | + "remove=10", |
4941 | + "grow=rowan_summer_old", |
4942 | + }, |
4943 | + }, |
4944 | + animations = { |
4945 | + idle = { |
4946 | + pictures = path.list_directory(dirname .. "mature/", "idle_\\d+.png"), |
4947 | + hotspot = { 18, 48 }, |
4948 | + fps = 8, |
4949 | + }, |
4950 | + }, |
4951 | +} |
4952 | + |
4953 | +world:new_immovable_type{ |
4954 | + name = "rowan_summer_old", |
4955 | + descname = _ "Rowan (Old)", |
4956 | + editor_category = "trees_deciduous", |
4957 | + size = "small", |
4958 | + attributes = { "tree" }, |
4959 | + terrain_affinity = terrain_affinity, |
4960 | + programs = { |
4961 | + program = { |
4962 | + "animate=idle 1432000", |
4963 | + "transform=deadtree4 26", |
4964 | + "seed=rowan_summer_sapling", |
4965 | + }, |
4966 | + fall = { |
4967 | + "remove=", |
4968 | + }, |
4969 | + }, |
4970 | + animations = { |
4971 | + idle = { |
4972 | + pictures = path.list_directory(dirname .. "old/", "idle_\\d+.png"), |
4973 | + hotspot = { 23, 59 }, |
4974 | + fps = 10, |
4975 | + sound_effect = { |
4976 | + directory = "sound/animals", |
4977 | + name = "bird6", |
4978 | + }, |
4979 | + }, |
4980 | + }, |
4981 | +} |
4982 | |
4983 | === renamed directory 'world/immovables/trees/rowan_summer_mature' => 'world/immovables/trees/rowan/mature' |
4984 | === renamed directory 'world/immovables/trees/rowan_summer_old' => 'world/immovables/trees/rowan/old' |
4985 | === renamed directory 'world/immovables/trees/rowan_summer_pole' => 'world/immovables/trees/rowan/pole' |
4986 | === renamed directory 'world/immovables/trees/rowan_summer_sapling' => 'world/immovables/trees/rowan/sapling' |
4987 | === removed file 'world/immovables/trees/rowan_summer_mature/init.lua' |
4988 | --- world/immovables/trees/rowan_summer_mature/init.lua 2014-05-03 08:40:59 +0000 |
4989 | +++ world/immovables/trees/rowan_summer_mature/init.lua 1970-01-01 00:00:00 +0000 |
4990 | @@ -1,26 +0,0 @@ |
4991 | -dirname = path.dirname(__file__) |
4992 | - |
4993 | -world:new_immovable_type{ |
4994 | - name = "rowan_summer_mature", |
4995 | - descname = _ "Rowan (Mature)", |
4996 | - editor_category = "trees_deciduous", |
4997 | - size = "small", |
4998 | - attributes = {}, |
4999 | - programs = { |
5000 | - program = { |
This still needs numbers to be put in. The corresponding bug has suggestions. I might be able to do it this week - not sure though.