2023-02-14 02:55:44 +00:00
|
|
|
#include "UpdateActionMessage.h"
|
|
|
|
|
2023-02-16 17:30:33 +00:00
|
|
|
#include "Action.h"
|
2023-02-14 02:55:44 +00:00
|
|
|
|
2023-02-16 17:30:33 +00:00
|
|
|
UpdateActionMessage::UpdateActionMessage(AMFArrayValue* arguments) : BehaviorMessageBase(arguments) {
|
|
|
|
actionContext = ActionContext(arguments);
|
2023-02-14 02:55:44 +00:00
|
|
|
|
2023-02-16 17:30:33 +00:00
|
|
|
auto* actionValue = arguments->FindValue<AMFArrayValue>("action");
|
|
|
|
if (!actionValue) return;
|
2023-02-14 02:55:44 +00:00
|
|
|
|
2023-02-16 17:30:33 +00:00
|
|
|
action = Action(actionValue);
|
|
|
|
actionIndex = GetActionIndexFromArgument(arguments);
|
2023-02-14 02:55:44 +00:00
|
|
|
|
2023-02-16 17:30:33 +00:00
|
|
|
Game::logger->LogDebug("UpdateActionMessage", "type %s valueParameterName %s valueParameterString %s valueParameterDouble %f behaviorId %i actionIndex %i stripId %i stateId %i", action.GetType().c_str(), action.GetValueParameterName().c_str(), action.GetValueParameterString().c_str(), action.GetValueParameterDouble(), behaviorId, actionIndex, actionContext.GetStripId(), actionContext.GetStateId());
|
2023-02-14 02:55:44 +00:00
|
|
|
}
|