Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .github/CODEOWNERS
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# About this file: https://docs.github.com/en/repositories/managing-your-repositorys-settings-and-features/customizing-your-repository/about-code-owners

* @albert-wang @camr
* @albert-wang

.github/ @albert-wang @camr
.github/ @albert-wang
5 changes: 5 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
*.swp
*.swo
.DS_Store
*.tar.gz
*.zip
*.dylib
*.so
Session.vim

CMakeCache.txt
Expand Down
6 changes: 5 additions & 1 deletion include/gateway.h
Original file line number Diff line number Diff line change
Expand Up @@ -178,13 +178,17 @@ namespace gateway
struct GamechangerPollData
{
string Name;
string InitiatorID;
string InitiatorUsername;
std::vector<GamechangerTier> Tiers;

// Shouldn't need to be changed, a marker to signal for special-case handling
string Type = string("gamechanger");

MUXY_GAMELINK_SERIALIZE_INTRUSIVE_3(GamechangerPollData,
MUXY_GAMELINK_SERIALIZE_INTRUSIVE_5(GamechangerPollData,
"name", Name,
"initiator_id", InitiatorID,
"initiator_username", InitiatorUsername,
"type", Type,
"tiers", Tiers
);
Expand Down
4 changes: 4 additions & 0 deletions test/gateway_matches.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,8 @@

cfg.Mode = gateway::PollMode::Chaos;
cfg.UserData.Name = "Delivery Budget";
cfg.UserData.InitiatorID = "0001234";
cfg.UserData.InitiatorUsername = "DeliveryDude";
cfg.UserData.Tiers = {
gateway::GamechangerTier{
.IncrementalText = "Spend $1 more",
Expand All @@ -33,7 +35,7 @@
.EffectText = "Spend $100 more",
.EffectValue = 100,

.IncrementalText = "Spend $10 more",

Check warning on line 38 in test/gateway_matches.cpp

View workflow job for this annotation

GitHub Actions / build

ISO C++ requires field designators to be specified in declaration order; field 'EffectValue' will be initialized after field 'IncrementalText' [-Wreorder-init-list]

Check warning on line 38 in test/gateway_matches.cpp

View workflow job for this annotation

GitHub Actions / build

ISO C++ requires field designators to be specified in declaration order; field 'EffectValue' will be initialized after field 'IncrementalText' [-Wreorder-init-list]
.IncrementalValue = 10,

.TierDuration = 60,
Expand All @@ -44,7 +46,7 @@
.EffectText = "Spend $200 more",
.EffectValue = 200,

.IncrementalText = "Spend $20 more",

Check warning on line 49 in test/gateway_matches.cpp

View workflow job for this annotation

GitHub Actions / build

ISO C++ requires field designators to be specified in declaration order; field 'EffectValue' will be initialized after field 'IncrementalText' [-Wreorder-init-list]

Check warning on line 49 in test/gateway_matches.cpp

View workflow job for this annotation

GitHub Actions / build

ISO C++ requires field designators to be specified in declaration order; field 'EffectValue' will be initialized after field 'IncrementalText' [-Wreorder-init-list]
.IncrementalValue = 20,

.TierDuration = 30,
Expand All @@ -55,7 +57,7 @@
.EffectText = "Go for broke!!",
.EffectValue = 1000,

.IncrementalText = "Please no more :(",

Check warning on line 60 in test/gateway_matches.cpp

View workflow job for this annotation

GitHub Actions / build

ISO C++ requires field designators to be specified in declaration order; field 'EffectValue' will be initialized after field 'IncrementalText' [-Wreorder-init-list]

Check warning on line 60 in test/gateway_matches.cpp

View workflow job for this annotation

GitHub Actions / build

ISO C++ requires field designators to be specified in declaration order; field 'EffectValue' will be initialized after field 'IncrementalText' [-Wreorder-init-list]
.IncrementalValue = 5,

.TierDuration = 15,
Expand Down Expand Up @@ -128,6 +130,8 @@
"prompt": "Empower my snacks",
"user_data": {
"name": "Delivery Budget",
"initiator_id": "0001234",
"initiator_username": "DeliveryDude",
"type": "gamechanger",
"tiers": [
{
Expand Down
Loading