-
Notifications
You must be signed in to change notification settings - Fork 94
summon_player
Ryzom Core Wiki edited this page Jul 8, 2024
·
3 revisions
title: Summon Player description: published: true date: 2023-03-16T23:12:25.959Z tags: editor: markdown dateCreated: 2023-03-16T22:30:30.967Z
The summonPlayer native AI script function can be used by a bot to summon a player to its location or to a specific location. This can be used, for example, by a boss to teleport a player to its location, or to create a teleporter.
()summonPlayer(botIndex: f, playerEid: s) // summonPlayer_fs_
- botIndex (float): The index of the bot in the current group.
- playerEid (string): The entityId of the player to be summoned.
($playerId)getRandomPlayerAggroListTarget(0);
()summonPlayer(0, $playerEid); // Teleport the player to the bot's location.
This example code gets a random player from the current group's aggro list and teleports them to the location of bot 0. The $playerId
variable is used to store the entityId of the player, and $playerEid
is used as the parameter for the summonPlayer
function.