Commit graph

24 commits

Author SHA1 Message Date
Erik Ogenvik
45555fd698 Use custom format for archetypes.
This required the EntityKit to be refactored, so that most fields are
pushed into EntityFactory. Due to the nature of how the rule handlers
and the factories interact the code is pretty messy. It works, but it's
tangled and not really clean.
2013-11-15 21:39:35 +01:00
Olek Wojnar
7f9ff2246d Remove CVS $Id tags
The legacy tags are causing build issues in Debian.
2013-07-15 20:31:59 +02:00
Alistair Riddoch
745d263709 Fail cleanly if a type exists
The code would segfault if installing a new entity class failed at the last
stage in Inheritance. Inheritance would return null, which would be assigned
to the factory's m_type. addProperties() assumes the pointer is not null.
This fix adds a check, and reports a failure undoing the whole process.
2013-02-21 21:53:11 +00:00
Alistair Riddoch
4a9c7078f7 Refactor to use LocatedEntity as base class
All IG code should use the interface of LocatedEntity when dealing
with any entity, rather than sometimes requiring Entity. Add virtual
functions to the interface where required, and modify all other interfaces
to stop them using Entity. This makes the code way cleaner, and much better
de-coupled.
2013-01-17 10:17:07 +00:00
Alistair Riddoch
5cedd45f29 Turns out this doesn't use the concrete factory 2011-12-21 00:26:43 +00:00
Alistair Riddoch
d1ac1ad740 I love removing includes 2011-12-20 16:03:47 +00:00
Alistair Riddoch
43e06f60c4 Change the place where script factory is deleted
When the module has change, we get rid of the old factory, but it is
bad to do this before we know whether the new module is good.
2011-12-18 21:09:48 +00:00
Alistair Riddoch
d3c1b94537 Move call to refresh class on rule update
Previous was the wrong place, as it would result in a reload
even if it had change, and later had to be loaded from the new class name
2011-12-18 20:48:01 +00:00
Alistair Riddoch
577539aa6e Make installing types a little more consistent 2011-12-17 18:37:28 +00:00
Alistair Riddoch
046bb0565d Remove support for old style mind rules 2011-12-16 16:50:45 +00:00
Alistair Riddoch
be735604b3 Move mind creation to the property
Also clean up factory, make more flexible and use shared script factory
code.
2011-12-15 18:33:32 +00:00
Alistair Riddoch
1f4b7bf1b9 Move PythonScriptFactory into the correct named file in the right place 2011-12-15 18:26:37 +00:00
Alistair Riddoch
e7f5ac91ea Converty ScriptFactory for Entity to a template
This class is now completely generic except for the type pointers for
the class being wrapped, so this starts the codebase moving to using
it for all server objects that should be scriptable
2011-12-15 01:00:28 +00:00
Alistair Riddoch
0e8f9ccc95 Replace abstract script factories with common template 2011-12-14 14:26:01 +00:00
Alistair Riddoch
325d9265f3 Remove updateChildren to updateProperties
This name makes more sense, and now the interface is more consistent.
2011-12-13 00:40:43 +00:00
Alistair Riddoch
a59c17f109 Remove now empty method 2011-12-13 00:39:08 +00:00
Alistair Riddoch
95d0d4ccad Move attribute copying into the function 2011-12-11 05:31:43 +00:00
Alistair Riddoch
92dba70495 Refactor script factories to use PythonClass 2011-11-08 19:55:51 +00:00
Alistair Riddoch
5e1461a95c Add some parameter checking assertions 2011-09-21 11:18:30 +01:00
Alistair Riddoch
5817393989 Consolidate Atlas script description parsing
This helper in the base class is identical to the query which was duplicated
in two places, so clearly needed to be consolidated here
2011-09-19 00:40:40 +01:00
Alistair Riddoch
ceb67d1033 Remove some unneeded includes 2011-09-18 17:36:42 +01:00
Alistair Riddoch
07201f1358 Handle Inheritance more consistently
Add an internal method for base classes, allowing the code that manipulates
the inheritance tree to be in a consistent place.
2011-09-18 17:26:26 +01:00
Alistair Riddoch
50043e6759 Remove some unneeded includes 2011-09-18 14:58:16 +01:00
Alistair Riddoch
4cf672cb23 Move Entity class rule processing to it's own class 2011-09-18 01:33:07 +01:00