Trigger Reference of GS2-Lottery Script

Reference for event triggers that call extended scripts, as defined in GS2-Lottery

lottery

Event trigger to call GS2-Script when drawing.

Request

TypeDescription
namespaceNamespaceNamespace
lotteryModelLotteryModelLottery Model Name
drawnPrizesDrawnPrize[]List of Drawn Prizes
boxItemsBoxItemsList of items taken out of the box

Result

TypeRequireDefaultLimitationDescription
permitboolAllow lottery
overrideDrawnPrizesDrawnPrize[]~ 1000 itemsList of Drawn Prizes

Implementation Example

namespace = args.namespace
lotteryModel = args.lotteryModel
drawnPrizes = args.drawnPrizes
boxItems = args.boxItems

result = {
  permit=permit,
  overrideDrawnPrizes=overrideDrawnPrizes
}