From 266bcfb97add23f46be7e2a125190f9e3598f7bc Mon Sep 17 00:00:00 2001 From: Nipun Garg Date: Thu, 20 Jun 2019 05:24:08 +0530 Subject: HDB: Remove Cache Gfx stub from spawn --- engines/hdb/ai-funcs.cpp | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) (limited to 'engines') diff --git a/engines/hdb/ai-funcs.cpp b/engines/hdb/ai-funcs.cpp index fd3e0ba532..453d7cc428 100644 --- a/engines/hdb/ai-funcs.cpp +++ b/engines/hdb/ai-funcs.cpp @@ -68,9 +68,15 @@ AIEntity *AI::spawn(AIType type, AIDir dir, int x, int y, char *funcInit, char * if (e->luaFuncUse[0] == '*') e->luaFuncUse[0] = 0; - _ents->push_back(e); + e->standdownFrames = e->standupFrames = e->standleftFrames = e->standrightFrames = 0; + e->movedownFrames = e->moveupFrames = e->moveleftFrames = e->moverightFrames = 0; + e->blinkFrames = 0; - warning("STUB: AI::spawn: CacheEntGfx required"); + if (!cacheEntGfx(e, (bool)callInit)) { + return NULL; + } else { + _ents->push_back(e); + } return e; } -- cgit v1.2.3