Can't say for sure, everything seems alright, although if (!UseDoodadSkill(skill.id, plant, true, plant.modelRadius)) LogError("Could not {0} the {1}", skill.name, plant.name); as a second cast, could be casting on a disconnected object. To figure out exactly where that's happening I suggest...