Commit graph

18 commits

Author SHA1 Message Date
Erik Ogenvik
2eeab96efa Separate BBox property from Density property. 2018-12-16 20:40:48 +01:00
Erik Ogenvik
164816f646 Adapt tests to changed structure. 2018-11-03 17:17:50 +01:00
Erik Ogenvik
e85f0831b2 Restructure rule classes.
Classes under "rulesets" have been moved to "rules", and split up into
futher subdirectories matching their library. As a result we can now
better separate the python bindings, so that things that belongs to the
simulation are separeted from things that belongs to the ai.
2018-10-31 21:38:35 +01:00
Erik Ogenvik
e0b45800ef Fix broken tests. 2018-10-29 21:11:23 +01:00
Erik Ogenvik
7e064963c6 Remove Plant and replace it with scripts. 2018-08-19 00:00:46 +02:00
Erik Ogenvik
c84f5fe926 Don't implicitly convert from Ref to ptr.
Since it's too easy to introduce subtle bugs.
2018-08-05 20:47:09 +02:00
Erik Ogenvik
a12b1a00a3 Delete when refs go to zero.
This changes how entities are dereferenced to work more like you would
expect.
2018-08-05 14:36:21 +02:00
Erik Ogenvik
4d1dc775b0 Moved BaseWorld to rulesets.
Since it better belongs there.
2018-07-25 00:16:09 +02:00
Erik Ogenvik
33dfbb3425 Added tests. 2018-07-24 21:18:50 +02:00
Erik Ogenvik
0ca22bcf68 Specify scripts for entity as property.
This allows multiple scripts to be used. In addition it allows for
entity with specific scripts.
2018-07-04 19:20:24 +02:00
Erik Ogenvik
beafd38e63 Scale plants, using the "maxscale" prop.
Instead of having different properties for max size and max mass we now
only use a "max scale" property, and we only change the size of the
plant by altering the scale.
2018-06-29 12:26:08 +02:00
Erik Ogenvik
e80d07560c Reload entity scripts when python code changes.
For now we reload all scripts. We should be smarter and only reload
those scripts which are affected though.
2018-04-30 23:34:58 +02:00
Erik Ogenvik
664988645e Make all properties define type and optional name. 2018-04-27 23:12:15 +02:00
Erik Ogenvik
7ae19d5038 Use Singleton base class.
I.e. make sure that all objects have a defined life time. This requires
that we actually set up and tear down the singletons.
2018-04-25 20:15:29 +02:00
Erik Ogenvik
6275555b20 Improved stub generation and create all stubs. 2017-07-25 23:40:40 +02:00
Erik Ogenvik
3a16efe860 Added script to generate stubs.
The script is copied from the GoogleMock project and adapted
to instead generate stubs.
Two stub files are generated, one being named *_custom.h.
Any custom behaviour can be added to the latter, since it won't be
regenerated when the stub is recreated.
2017-07-25 23:40:39 +02:00
Erik Ogenvik
0db8323325 Fixed tests. 2016-12-19 22:01:23 +01:00
Erik Ogenvik
1c69b3aae6 Use camel casing for tests.
This makes it much easier to find them in various editors.
2016-06-26 20:17:18 +02:00
Renamed from tests/Planttest.cpp (Browse further)