Trigger Reference of GS2-Enhance Script
Reference for event triggers that call extended scripts, as defined in GS2-Enhance
enhance
Event trigger to call GS2-Script before reinforcement.
Request
| Type | Description |
---|
namespace | Namespace | Namespace |
rateModel | RateModel | Enhanced Rate Model |
targetItemSetId | string | GRN for the item set to be enhanced (number of items held per validity period) |
bonusRate | float | Experience bonus multiplier (1.0 = no bonus) |
experienceValue | long | Amount of experience gained |
Result
| Type | Require | Default | Limitation | Description |
---|
permit | bool | ✓ | | | Allow enhancement execution |
overrideExperienceValue | long | | | ~ 2147483645 | Amount of available experience to be overwritten |
Implementation Example
namespace = args.namespace
rateModel = args.rateModel
targetItemSetId = args.targetItemSetId
bonusRate = args.bonusRate
experienceValue = args.experienceValue
result = {
permit=permit,
overrideExperienceValue=overrideExperienceValue
}
enhanceDone
GS2-Script called after reinforcement.
Request
| Type | Description |
---|
namespace | Namespace | Namespace |
rateModel | RateModel | Enhanced Rate Model |
targetItemSetId | string | GRN for the item set to be enhanced (number of items held per validity period) |
bonusRate | float | Experience bonus multiplier (1.0 = no bonus) |
experienceValue | long | Amount of experience gained |
Result
| Type | Require | Default | Limitation | Description |
---|
Implementation Example
namespace = args.namespace
rateModel = args.rateModel
targetItemSetId = args.targetItemSetId
bonusRate = args.bonusRate
experienceValue = args.experienceValue
result = {
}