Skip to content

Commit

Permalink
const
Browse files Browse the repository at this point in the history
  • Loading branch information
EmosewaMC committed Jan 3, 2024
1 parent 5cc6f69 commit 88fa58d
Show file tree
Hide file tree
Showing 16 changed files with 39 additions and 39 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@ class ActionContext {
public:
ActionContext();
ActionContext(AMFArrayValue* arguments, std::string customStateKey = "stateID", std::string customStripKey = "stripID");
const StripId GetStripId() { return stripId; };
const BehaviorState GetStateId() { return stateId; };
const StripId GetStripId() const { return stripId; };
const BehaviorState GetStateId() const { return stateId; };
private:
BehaviorState GetBehaviorStateFromArgument(AMFArrayValue* arguments, const std::string& key);
StripId GetStripIdFromArgument(AMFArrayValue* arguments, const std::string& key);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,9 @@ class AMFArrayValue;
class AddActionMessage : public BehaviorMessageBase {
public:
AddActionMessage(AMFArrayValue* arguments);
const uint32_t GetActionIndex() { return actionIndex; };
Action GetAction() { return action; };
ActionContext GetActionContext() { return actionContext; };
int32_t GetActionIndex() const { return actionIndex; };
Action GetAction() const { return action; };
ActionContext GetActionContext() const { return actionContext; };
private:
int32_t actionIndex = -1;
ActionContext actionContext;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
class AddMessage : public BehaviorMessageBase {
public:
AddMessage(AMFArrayValue* arguments);
const uint32_t GetBehaviorIndex() { return behaviorIndex; };
const uint32_t GetBehaviorIndex() const { return behaviorIndex; };
private:
uint32_t behaviorIndex;
};
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,9 +19,9 @@ class AMFArrayValue;
class AddStripMessage : public BehaviorMessageBase {
public:
AddStripMessage(AMFArrayValue* arguments);
StripUiPosition GetPosition() { return position; };
ActionContext GetActionContext() { return actionContext; };
std::vector<Action> GetActionsToAdd() { return actionsToAdd; };
StripUiPosition GetPosition() const { return position; };
ActionContext GetActionContext() const { return actionContext; };
std::vector<Action> GetActionsToAdd() const { return actionsToAdd; };
private:
StripUiPosition position;
ActionContext actionContext;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ enum class BehaviorState : uint32_t;
class BehaviorMessageBase {
public:
static inline int32_t DefaultBehaviorId = -1;
const int32_t GetBehaviorId() { return behaviorId; };
const int32_t GetBehaviorId() const { return behaviorId; };
bool IsDefaultBehaviorId() { return behaviorId == DefaultBehaviorId; };
BehaviorMessageBase(AMFArrayValue* arguments);
protected:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,10 @@ class AMFArrayValue;
class MergeStripsMessage : public BehaviorMessageBase {
public:
MergeStripsMessage(AMFArrayValue* arguments);
int32_t GetDstActionIndex() { return dstActionIndex; };
ActionContext GetSourceActionContext() { return sourceActionContext; };
ActionContext GetDestinationActionContext() { return destinationActionContext; };
const std::vector<Action>& GetMigratedActions() { return migratedActions; };
int32_t GetDstActionIndex() const { return dstActionIndex; };
ActionContext GetSourceActionContext() const { return sourceActionContext; };
ActionContext GetDestinationActionContext() const { return destinationActionContext; };
const std::vector<Action>& GetMigratedActions() const { return migratedActions; };
void SetMigratedActions(std::vector<Action>::const_iterator start, std::vector<Action>::const_iterator end) { migratedActions.assign(start, end); };
private:
std::vector<Action> migratedActions;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,11 +14,11 @@ class AMFArrayValue;
class MigrateActionsMessage : public BehaviorMessageBase {
public:
MigrateActionsMessage(AMFArrayValue* arguments);
int32_t GetSrcActionIndex() { return srcActionIndex; };
int32_t GetDstActionIndex() { return dstActionIndex; };
ActionContext GetSourceActionContext() { return sourceActionContext; };
ActionContext GetDestinationActionContext() { return destinationActionContext; };
const std::vector<Action>& GetMigratedActions() { return migratedActions; };
int32_t GetSrcActionIndex() const { return srcActionIndex; };
int32_t GetDstActionIndex() const { return dstActionIndex; };
ActionContext GetSourceActionContext() const { return sourceActionContext; };
ActionContext GetDestinationActionContext() const { return destinationActionContext; };
const std::vector<Action>& GetMigratedActions() const { return migratedActions; };
void SetMigratedActions(std::vector<Action>::const_iterator start, std::vector<Action>::const_iterator end) { migratedActions.assign(start, end); };
private:
std::vector<Action> migratedActions;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ class AMFArrayValue;
class MoveToInventoryMessage : public BehaviorMessageBase {
public:
MoveToInventoryMessage(AMFArrayValue* arguments);
const uint32_t GetBehaviorIndex() { return behaviorIndex; };
const uint32_t GetBehaviorIndex() const { return behaviorIndex; };
private:
uint32_t behaviorIndex;
};
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,9 @@
class RearrangeStripMessage : public BehaviorMessageBase {
public:
RearrangeStripMessage(AMFArrayValue* arguments);
int32_t GetSrcActionIndex() { return srcActionIndex; };
int32_t GetDstActionIndex() { return dstActionIndex; };
ActionContext GetActionContext() { return actionContext; };
int32_t GetSrcActionIndex() const { return srcActionIndex; };
int32_t GetDstActionIndex() const { return dstActionIndex; };
ActionContext GetActionContext() const { return actionContext; };
private:
ActionContext actionContext;
int32_t srcActionIndex;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@ class AMFArrayValue;
class RemoveActionsMessage : public BehaviorMessageBase {
public:
RemoveActionsMessage(AMFArrayValue* arguments);
int32_t GetActionIndex() { return actionIndex; };
ActionContext GetActionContext() { return actionContext; };
int32_t GetActionIndex() const { return actionIndex; };
ActionContext GetActionContext() const { return actionContext; };
private:
ActionContext actionContext;
int32_t actionIndex;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
class RemoveStripMessage : public BehaviorMessageBase {
public:
RemoveStripMessage(AMFArrayValue* arguments);
ActionContext GetActionContext() { return actionContext; };
ActionContext GetActionContext() const { return actionContext; };
private:
ActionContext actionContext;
};
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ class AMFArrayValue;
class RenameMessage : public BehaviorMessageBase {
public:
RenameMessage(AMFArrayValue* arguments);
const std::string& GetName() { return name; };
const std::string& GetName() const { return name; };
private:
std::string name;
};
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,11 @@ class AMFArrayValue;
class SplitStripMessage : public BehaviorMessageBase {
public:
SplitStripMessage(AMFArrayValue* arguments);
ActionContext GetSourceActionContext() { return sourceActionContext; };
ActionContext GetDestinationActionContext() { return destinationActionContext; };
int32_t GetSrcActionIndex() { return srcActionIndex; };
StripUiPosition GetPosition() { return destinationPosition; };
const std::vector<Action>& GetTransferredActions() { return transferredActions; };
ActionContext GetSourceActionContext() const { return sourceActionContext; };
ActionContext GetDestinationActionContext() const { return destinationActionContext; };
int32_t GetSrcActionIndex() const { return srcActionIndex; };
StripUiPosition GetPosition() const { return destinationPosition; };
const std::vector<Action>& GetTransferredActions() const { return transferredActions; };
void SetTransferredActions(std::vector<Action>::const_iterator begin, std::vector<Action>::const_iterator end) { transferredActions.assign(begin, end); };
private:
ActionContext sourceActionContext;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@ class StripUiPosition {
StripUiPosition();
StripUiPosition(AMFArrayValue* arguments, std::string uiKeyName = "ui");
void SendBehaviorBlocksToClient(AMFArrayValue& args) const;
double GetX() { return xPosition; };
double GetY() { return yPosition; };
double GetX() const { return xPosition; };
double GetY() const { return yPosition; };
private:
double xPosition;
double yPosition;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,9 @@ class AMFArrayValue;
class UpdateActionMessage : public BehaviorMessageBase {
public:
UpdateActionMessage(AMFArrayValue* arguments);
int32_t GetActionIndex() { return actionIndex; };
ActionContext GetActionContext() { return actionContext; };
Action GetAction() { return action; };
int32_t GetActionIndex() const { return actionIndex; };
ActionContext GetActionContext() const { return actionContext; };
Action GetAction() const { return action; };
private:
int32_t actionIndex;
ActionContext actionContext;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@ class AMFArrayValue;
class UpdateStripUiMessage : public BehaviorMessageBase {
public:
UpdateStripUiMessage(AMFArrayValue* arguments);
StripUiPosition GetPosition() { return position; };
ActionContext GetActionContext() { return actionContext; };
StripUiPosition GetPosition() const { return position; };
ActionContext GetActionContext() const { return actionContext; };
private:
StripUiPosition position;
ActionContext actionContext;
Expand Down

0 comments on commit 88fa58d

Please sign in to comment.