SetPlrMagic

Category: Player
Since engine version: 4.6.5.0 CP

Description

Adds or removes a magic spell to or from the list of available spells of a player.

Syntax

int SetPlrMagic (int iPlr, id id, bool Remove);

Parameters

iPlr:
Number of the player whose list of available spells you want to change
id:
ID of the spell
Remove:
Whether to remove the spell

Example

var i = 0;
for (var plrnum = GetPlayerCount (); plrnum; i++)
  if (GetPlayerName (i)) {
    plrnum--;
    SetPlrMagic (i, MGHL);
  }
Makes the Healing spell available to all players.
See also: GetPlrMagic
Günther, November 2002, Februar 2005