Player attributes

From Graal Bible

The properties of any given player. The client is usually afforded the ability to change the visual aspects of their player, whilst more important modifications - money, health and so on - can only be set from the RC or by using scripts designed to do so.

The full list of attributes editable by the RC is listed below.

Player look: head, body, animation, skin colour, coat colour, sleeve colour, shoe colour and belt colour. These can usually be changed by the client using simple chat commands: see appearance commands.

Player properties: Level, x co-ordinate, y co-ordinate, hearts, fullhearts, AP, MP, gralats, glove power, bomb count, arrow count, sword power, sword image, shield power, shield image, gender, weapon status, spin attack status, opened chests, weapons, and script flags.


Scripting items designed for editting player attributes include:
(OBJ: GScript1 -> GScript2)
sword: #1 -> player.swordimg
shield: #2 -> player.shieldimg
head: #3 -> player.headimg
Body: #8 -> player.bodyimg
Skin: #C0 -> player.colors[0]
Shoes: #C1 -> player.colors[1]
Sleeves: #C2 -> player.colors[2]
Coat: #C3 -> player.colors[3]
Belt: #C4 -> player.colors[4]

Here's a simple list of player Variables.

players[index] -- gets player from level (for gmaps, this includes players in the 3x3 levels around you)
players[index].x -- a player’s horizontal position
players[index].y -- a player’s vertical position
players[index].z -- a player’s z position
players[index].rupees -- a player’s rupees count
players[index].bombs -- a player’s bombs count
players[index].darts -- a player’s darts count
players[index].mp -- a player’s magic points (0..100)
players[index].ap -- a player’s alignment points (0..100)
players[index].hearts -- a player’s hearts count
players[index].fullhearts -- a player’s max hearts count
players[index].dir -- a player’s (0-up,1-left,2-down,3-right)
players[index].glovepower -- a player’s glove power (2-glove1,3-glove2)
players[index].swordpower -- a player’s sword power (1-normal sword,2-axe,3-lizardsword,4-golden sword)
players[index].shieldpower -- a player’s sield power (1-normal sword,2-mirror shield,3-lizard shield)
players[index].headset -- a player’s head sprites set (”head”+playerheadset+”.gif”)
players[index].sprite -- a player’s sprites set (0..40)
players[index].anistep -- the anistep of the player)
players[index].id -- a player’s id (=-1 for npc characters)
players[index].saysnumber -- the (index+1)th player says that number
players[index].id -- a player’s id (=-1 for npc characters)
players[index].attachid -- the player is attached to the npc with that id (<=0-> not attached)
players[index].attachtype -- the type of object the player is attached to
players[index].logintime -- when the player logged in (in timevar)
players[index].lastdead -- when the player last died (in timevar)

See Also