SetPlayerStat

Prototype: GemRB.SetPlayerStat(Slot, ID, Value)

Description: Sets a player character's base stat. The stats are listed in ie_stats.py.

Parameters: Slot - actor index in game structure

  • ID - Stat index
  • Value - New stat value

Return value: N/A

Example: PickedColor=GemRB.GetTableValue(ColorTable, ColorIndex, GemRB.GetVar(“Selected”)) GemRB.SetPlayerStat (pc, IE_MAJOR_COLOR, PickedColor) The above example sets the player's color just picked via the color customisation dialog. ColorTable holds the available colors.

See also: GetPlayerStat, SetPlayerName, ApplyEffect

Function index

 
guiscript/setplayerstat.txt · Last modified: 2009/08/03 12:59 (external edit)
 
Except where otherwise noted, content on this wiki is licensed under the following license: CC Attribution-Noncommercial-Share Alike 3.0 Unported
Recent changes RSS feed Donate Powered by PHP Valid XHTML 1.0 Valid CSS Driven by DokuWiki