Remove ZeroedMemoryAllocator from ScriptText

Have ScriptText initialise all of its members on construction and
not derive from ZeroedMemoryAllocator.

(cherry picked from commit 3240126202d3437396004f2d5b0371783effb1ea)

Reorder ScriptText constructor initialisers.
This commit is contained in:
cirdan
2015-11-26 21:24:43 +01:00
committed by Jonathan G Rennison
parent 80fd6a2783
commit e6122f5ce4
2 changed files with 2 additions and 2 deletions

View File

@@ -30,7 +30,7 @@ RawText::~RawText()
ScriptText::ScriptText(HSQUIRRELVM vm) : ScriptText::ScriptText(HSQUIRRELVM vm) :
ZeroedMemoryAllocator() string(STR_NULL), params(), parami(), paramt(), paramc(0)
{ {
int nparam = sq_gettop(vm) - 1; int nparam = sq_gettop(vm) - 1;
if (nparam < 1) { if (nparam < 1) {

View File

@@ -73,7 +73,7 @@ private:
* *
* @api game * @api game
*/ */
class ScriptText : public Text , public ZeroedMemoryAllocator { class ScriptText : public Text {
public: public:
static const int SCRIPT_TEXT_MAX_PARAMETERS = 20; ///< The maximum amount of parameters you can give to one object. static const int SCRIPT_TEXT_MAX_PARAMETERS = 20; ///< The maximum amount of parameters you can give to one object.