fixed weird function glitch in engine
engine version 1.0.6