The giveReward native AI script function sends a message to the EGS server to reward a player and notifies a specified NPC group of the reward.
TODO: This function causes one or more undocumented user event IDs to be triggered on the NPC group that is to be notified. The list of notifications needs to be documented here.
TODO: This document is autogenerated and has not yet been reviewed.
()giveReward(rewardText: s, rareRewardText: s, inventoryFullText: s, notEnoughPointsText: s, groupToNotify: c)
This function sends a message to the EGS server to reward the player and notify the NPC group of the reward.
(@groupToNotify)group_name.context();
()giveReward("You got a reward!", "You got a rare reward!", "Your inventory is full.", "You don't have enough points.", @groupToNotify);
This example code sends a reward message to the EGS server with the specified texts and sends user events to the group_name
group to notify of the reward.