Skip to content

Create a new store plugin#1743

Merged
Daztek merged 2 commits intonwnxee:masterfrom
julien-lecomte:stores
Mar 5, 2024
Merged

Create a new store plugin#1743
Daztek merged 2 commits intonwnxee:masterfrom
julien-lecomte:stores

Conversation

@julien-lecomte
Copy link
Copy Markdown
Contributor

@julien-lecomte julien-lecomte commented Mar 1, 2024

New NWScript Functions
  • Store: New GetIsRestrictedBuyItem
  • Store: New {Get|Set}BlackMarketMarkDown
  • Store: New {Get|Set}MarkDown
  • Store: New {Get|Set}MarkUp

Since there's the possibilty of having a whitelist or blacklist for selling back to the store, I'm unsure if exposing just GetIsRestrictedBuyItem is sufficient.

Comment on lines +76 to +77
ASSERT_OR_THROW(nValue >= 1);
ASSERT_OR_THROW(nValue <= 1000);
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why are the asserts >=1 and <= 1000 here while for the others it's >=0 and <=100, that said, are they percentages or flat goldpiece values?

Copy link
Copy Markdown
Contributor Author

@julien-lecomte julien-lecomte Mar 5, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The values are the min and max that the toolset editor allows us to use in the UI. They're percentage points: 110 is 10% increase in price.

@Daztek Daztek merged commit 41dd0c2 into nwnxee:master Mar 5, 2024
@julien-lecomte julien-lecomte deleted the stores branch March 5, 2024 22:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants