Game Development Reference
In-Depth Information
self.currentAction_:Update(deltaTimeInMillis);
-- Clean up the Action once it has terminated.
if (status == Action.Status.TERMINATED) then
self.currentAction_:CleanUp();
self.currentAction_ = nil;
end
end
function DecisionTree.new()
local decisionTree = {};
-- The DecisionTree's data members.
decisionTree.branch_ = nil;
decisionTree.currentAction_ = nil;
-- The DecisionTree's accessor functions.
decisionTree.SetBranch = DecisionTree.SetBranch;
decisionTree.Update = DecisionTree.Update;
return decisionTree;
end
Search WWH ::




Custom Search