-
Notifications
You must be signed in to change notification settings - Fork 5
ChangeGoodPriority
Change the transportation priority of a good type in a specific eco sector. This is usually the event that is issued by the player when changing the order in the goods side menu panel.
BOOL ISettlers4Api::ChangeGoodPriority(
S4_GOOD_ENUM good,
INT offset,
DWORD ecosector
DWORD player
);
good
The good type you want to change the priority. See S4_GOOD_ENUM for a list of possible good types.
offset
This parameter specifies how many positions the priority is increased or decreased. Use negative values to increase the priority and use positive values to decrease the priority. Usually you would specify -1 or 1 to change the priority one step higher or lower.
ecosector
The eco sector identifier to change the priority for.
player
The player who issues the command. Use 0 (zero) to issue this event as the local player.
If this method could append the event successfully it will return TRUE. If an error occurred it will return FALSE.
The corresponding network event id of the command is ID 5029.
When changing the priority of a good the game usually outputs multiple events at the same tick to make sure that a swap occurs with the priority of another good.
Minimum API Level | 1 |
Target Edition | Any |
Header | S4ModApi.h |
Library | S4ModApi.lib |
DLL | S4ModApi.dll |