|VR| MADMANs Scripting Site
An fairly quick reference

Home

A Good Start
Po's Scripting Guide
An fairly quick reference
Defence
Offence
Miscellaneous
Links
DownLoads
Scripting Forum

Scripting: An fairly quick reference

killercloun1.jpg

Ok so you can find all this in you BG2 folder just thought id post it hear so you can have all the info you need in the same place.

Scripting: An fairly quick reference

 

Creature and Object Identification

Creature and Object Identification is done through the ObjectType Class.

 

The IDS file used is Object.ids

 

ObjectType is arranged as follows

 

EnemyAlly                  General

General                      |

Race                           |

Class                          |

Specifics                   V

Instance                      Specific

SpecialCase

 

Eg. [EnemyAlly.General.Race.Class.Specifics.Instance.SpecialCase]

 

EnemyAlly is a range between the PC and the evil NPCs Creatures can fall anywhere along this range.

 

The IDS file used is EA.ids

 

PC refers to any of the possible six party members.

GOODCUTOFF refers to anyone good.  Party members, allies, summoned monsters, etc.

GOODBUTBLUE refers to anyone good but with a blue circle.

ENEMY refers to anyone evil, generally red circles.

EVILBUTBLUE refers to anyone evil but with a blue circle.

EVILBUTGREEN refers to anyone evil but with a green circle.

NEUTRAL refers to anyone neutral, generally blue circles.

ANYONE refers to any object.

 

General specifies the generic characteristics of the creature.

 

The IDS file used is General.ids

 

HUMANOID

ANIMAL

DEAD

UNDEAD

GIANTHUMANOID

MONSTER

Etc.

 

Race is the race of the creature.

 

The IDS file used is Race.ids

 

HUMAN

ELF

HALF_ELF

DWARF

HALFLING

GNOME

ANKHEG

BASILISK

BEAR

Etc.

 

Class is the class information (Mage, Fighter ) Alternatively it can be used for more detailed information (e.g. Drow is more specific then elf)

 

The IDS file used is Class.ids

 

MAGE

FIGHTER

CLERIC

FIGHTER_THIEF

BASILISK

BASILISK_GREATER

BEAR_POLAR

Etc.

 

Specifics holds the identification for special NPCs

 

Instance is unique for each creature within the game.  It should not generally be specifies in the AI scripting but will be set by the AI code once a target is selected

 

SpecialCase is used to specify whether or not to use any special case information. Currently this will only be used for LAttacked and LTargetted.  Protecting, Protector and Myself must be stored in a different way so that you can do things like Protecting.Lattacked.

 

 

Eg. To specify all Enemy Fighters: [ENEMY.0.0.FIGHTER]

 

 

 

 

Special Object Identification

 

The following functions return ObjectType variables corresponding to some special cases.  They are called using the following syntax:

 

Function(Source)

For Example: LAttacked(Spud) will return the ObjectType of the last thing to attack Spud.

 

If One of Leader, Weakest, Strongest, MDamaged, LDamaged is called, the Source will be used ONLY to determine which group to use.

For Example: Leader(Spud) will return the leader of Spuds Group

 

These functions can be used as the Source for any other of these functions.  HOWEVER, this nesting can only go 5 deep.

For Example: Protector(LAttacked(LTargeted(Protecting(Myself)))) is valid and will return the protector of the person last attacked by the person last targeted by the person protecting myself.  Any more then this depth of nesting is NOT allowed, however.

Note: If you ever use this level of nesting, please seek professional help.

 

NAME

This is the scriptname in the creature file.

 

Myself

This is the creature that the script belongs to.

Leaving out the Object within the brackets defaults the Object to Myself

 

LastAttackerOf(Object)

The Creature that last did the Object damage.

 

LastHeardBy(Object)

Last heard by the Object.

 

LastSeenBy(Object)

Last seen by the Object.

 

LastTalkedToBy(Object)

Last talked to by the Object.

 

LastTalkedToBy()

LastTalkedToBy

Both of these default to LastTalkedToBy(Myself)

 

LastTrigger(Object)

Last triggerer of the Object

Player1 or Protagonist

This is the Main Character or Protagonist.

 

Player2 Player6

Character 2, 3, 4, 5 or 6 in the order they have joined.

 

StrongestOf()

Party member with the highest threat rating.

 

StrongestOfMale()

Male party member with the highest threat rating.

 

WeakestOf()

Party member with lowest threat rating.

 

NearestEnemyOf(Object)

Returns the nearest creature with Enemy / Ally flag opposite to the Object.

 

SecondNearestEnemyOf(Object)

You can check the first ten nearest enemies.

 

Nearest(Type)

Returns the instance of the nearest Object of the given Type.

Eg. Nearest([0.0.DWARF])

 

SecondNearest()

You can check the first ten nearest.

 

WorstAC()

Party member with the worst AC.

 

BestAC()

Party member with the best AC.

 

NearestEnemyOfType(Type)

Nearest enemy of myself that is of the Type.

Eg. NearestEnemyOfType([0.0.0.MAGE])

 

SecondNearestEnemyOfType(Type)

You can check the first ten nearest.

 

 

 

 

 

 

Trigger Descriptions

 

Event Triggers

 

Triggers return True or False

 

Doors, Containers and Traps

 

Clicked(Object)

I am a game trigger and have just been clicked on by Object.  Usually info triggers use this.

 

Entered(Object)

I am a trigger and an Object just entered me.  Usually proximity traps use this.

 

Closed(Object)

I am a Door and I have just been closed by an Object.

 

Opened(Object)

I am a Door, container and I have just been opened by an Object.

 

Detected(Object)

I am a Door, container, trigger and my trap has been detected by an Object.

 

Disarmed(Object)

I am a Door, container, trigger and my trap has been disarmed by an Object.

 

DisarmFailed(Object)

I am a Door, container, trigger and my trap has failed to be disarmed by an Object.

 

PickLockFailed(Object)

Object just failed to pick my lock.

 

Unlocked(Object)

Object just unlocked me.

 

 

 

 

 

 

 

Creatures

 

AttackedBy(Object, Style Y)

I was just attacked by an Object using Style.

Style:             DEFAULT

MELEE

RANGED

 

BecameVisible()

I am a creature and I just became visible to the party.

 

BreakingPoint()

I am in the party and have reached my breaking Point.

 

Die()

I have just died.  This does not always seem to work.

 

Died(Object)

An Object just died in my hearing range.

 

Heard(Object, Integer: X)

I heard an Object shout X.

 

HitBy(Object, Style)

I have just been hit by an Object using Style.

 

OnCreation()

I have just been created (not necessarily for the first time)

This can be used for creature and area scripts.

 

OutOfAmmo()

My weapon is out of ammo.

 

ActionListEmpty()

I have no current actions to complete.

 

 

 

 

 

 

 

 

 

 

 

Creature Status

 

Alignment(Object, Alignment)

The Object is of the Alignment specified.

 

The IDS file used the Align.ids

 

LAWFUL_GOOD

NEUTRAL

CHAOTIC_EVIL

MASK_GOOD

Etc.

 

Allegiance(Object, Allegiance)

The Object is of the Allegiance specified.

 

The IDS file used is EA.ids

 

Class(Object, Class)

The Object is of the Class specified.

 

The IDS file used is Class.ids

 

Kit(Object, Kit)

The Object is of the Kit specified.

 

The IDS file used is Kit.ids

 

Race(Object, Race)

The Object is of the Race specified.

 

The IDS file used is Race.ids

 

Gender(Object, Gender)

The Object is of the Gender specified.

 

The IDS file used is Gender.ids

 

MALE

FEMALE

SUMMONED

ILLUSIONARY 

EXTRA

SUMMONED_DEMON

Etc.

 

General(Object, General)

The Object is of the General state specified.

 

The IDS file used is General.ids

 

Specifics(Object, Specific)

The Object is of the Specific state specified.

 

The IDS file used is Specific.ids

 

HP(Object, X)

HPGT(Object, X)

HPLT(Object, X)

Compares the Objects hitpoints to X.

 

HPPercent(Object, X)

HPPercentLT(Object, X)

HPPercentGT(Object, X)

Compares the Objects hitpoints to X percent.

 

Morale(Object, X)

MoraleGT(Object, X)

MoraleLT(Object, X)

Compares the Objects morale to X.

 

Reputation(Object, X)

ReputationGT(Object, X)

ReputationLT(Object, X)

Compares the Objects reputation to X.

 

StateCheck(Object, State)

The Object is in the specified State.

 

The IDS file used is State.ids

 

STATE_NORMAL                     

STATE_DEAD                       

STATE_ACID_DEATH                 

STATE_FLAME_DEATH                

STATE_EXPLODING_DEATH            

Etc.

 

 

 

 

 

CheckStat(Object, X, Stat)

CheckStatGT(Object, X, Stat)

CheckStatLT(Object, X, Stat)

Compares the Objects Stat is to X.

 

The IDS file used is Stats.ids

 

STR

STREXTRA

INT

WIS

DEX

CON

CHR

Etc.

 

NumTimesTalkedTo(X)

NumberOfTimesTalkedTo(X)

NumTimesTalkedToGT(X)

NumTimesTalkedToLT(X)

Compares the number of times I have been talked to with X.

 

Reaction(Object, Reaction)

ReactionGT(Object, Reaction)

ReactionLT(Object, Reaction)

 

The IDS file used is Reaction.ids

 

20 FRIENDLY_UPPER

15 FRIENDLY_LOWER

14 NEUTRAL_UPPER

8 NEUTRAL_LOWER

7 HOSTILE_UPPER

2 HOSTILE_LOWER

 

Numbers can be used as well as the defines above.

 

Exists(Object)

The Object currently exists.

 

Level(Object, X)

LevelGT(Object, X)

LevelLT(Object, X)

Compares the Objects level to X.

 

 

Name(Name, Object)

Checks the Objects scriptname.

 

Range(Object, X)

The Object is within X search squares.

 

See(Object)

The Object is visible to me.

 

Detect(Object)

The Object may not be visible but is within sight range.

 

TimerExpired(Value)

This is a timer specific an instance of a creature. It does not get saved in the savegame.

 

Global(Name, Area, Value)

GlobalGT(Name, Area, Value)

GlobalLT(Name, Area, Value)

The Name must be in quotes and can be 32 chars long.

The Area must also be in quotes and can be one of the following:

            GLOBAL can be accessed anywhere in the game.

            LOCALS can only be accessed by an instance of a creature.

            AR0200 can only be accessed in the area.

All globals default to 0.

 

GlobalsEqual(Name1, Name2)

GlobalsGT(Name1, Name2)

GlobalsLT(Name1, Name2)

LocalsEqual(Name1, Name2)

LocalsGT(Name1, Name2)

LocalsLT(Name1, Name2)

Compares the value of Name1 to that of Name2.

 

Eg. GlobalsGT(Bob, John) checks to see if Bob is greater than John.

 

GlobalTimerExact(Name, Area)

GlobalTimerExpired(Name, Area)

GlobalTimerNotExpired(Name, Area)

Checks the status of a global timer.

 

RealGlobalTimerExact(Name, Area)

RealGlobalTimerExpired(Name, Area)

RealGlobalTimerNotExpired(Name, Area)

Same as global timers but using real time not game time.

 

NumInParty(Number)

NumInPartyGT(Number)

NumInPartyLT(Number)

Checks the number of party members.

 

NumInPartyAlive(Number)

NumInPartyAliveGT(Number)

NumInPartyAliveLT(Number)

Checks the number of living party members.

 

PartyHasItem(Item)

Checks to see if anyone in the party has the item.  The item name must be in quotes.

 

PartyHasItemIdentified(Item)

Checks to see if anyone in the party has the item and it is identified.

 

NumItems(Item, Object, Number)

NumItemsGT(Item, Object, Number)

NumItemsLT(Item, Object, Number)

Checks the number of items

 

NumItemsParty(Item, Object, Number)

NumItemsPartyGT(Item, Object, Number)

NumItemsPartyLT(Item, Object, Number)

 

Time(Time)

TimeGT(Time)

TimeLT(Time)

Checks to see if the time is a specified hour.

 

The IDS file used is Time.ids

 

MIDNIGHT

NOON

DAWN_START

DAWN_END

DUSK_START

DUSK_END

 

The hour can be used as well as the defines above.

 

 

 

 

 

TimeOfDay(Time)

This command checks to see if the game is at a specified time of day.

 

The IDS file used is TimeODay.ids

 

DAY

DUSK

NIGHT

MORNING

 

NumCreature(Object, Number)

NumCreatureLT(Object, Number)

NumCreatureGT(Object, Number)

 

Delay(Number)

This command is used to delay the actions of a starting condition so they do not happen every time the script is checked.  The delay value is in seconds.

 

Eg.

 

IF

            See([ENEMY])

            Delay(10)

THEN

            RESPONSE #100

                        RunAwayFrom([ENEMY])

END

 

Heard(Object, Number)

This command checks to see if I heard the Object shout the Number specified.

 

HaveSpell(Spell)

This command checks to see if I have the specified Spell memorized.

 

The IDS file used is Spell.ids

 

CLERIC_BLESS

CLERIC_COMMAND

CLERIC_CURE_LIGHT_WOUNDS

CLERIC_DETECT_EVIL

CLERIC_ENTANGLE

Etc.

 

HaveAnySpells()

This command checks to see if I have any spells memorized.

 

InParty(Object)

This command checks to see if the Object is in the party.

 

RandomNum(Range, Value)

RandomNumGT(Range, Value)

RandomNumLT(Range, Value)

Compares a random number between 0 and Range to Value.

 

PartyGold(Amount)

PartyGoldGT(Amount)

PartyGoldLT(Amount)

Checks the amount of party gold.

 

HasItem(Item, Object)

This command checks to see if the Object has the Item specified.

 

Contains(Item, Object)

This command checks to see if the container Object contains the Item specified.

 

NumDead(Object, Number)

NumDeadGT(Object, Number)

NumDeadLT(Object, Number)

Checks the number of Objects that have died.

 

OpenState(Object, TRUE/FALSE)

This command checks to see if the door Object is open or not.

 

IsOverMe(Object)

This command checks to see if the Object is over me.  This is used for proximity triggers.

 

InWeaponRange(Object)

This command checks to see if the Object is within my current weapons range.

 

HasItemEquiped(Item, Object)

This command checks to see if the Object has the specified Item equipped.

 

HasWeaponEquiped(Object)

This command checks to see if the Object has a weapon equipped.

 

AreaCheck(Area)

This command checks to see if the current area I am in matches the specified Area.

 

 

 

AreaType(Type)

This command checks to see if the current area is of Type.

 

The IDS file used is AreaType.ids

 

OUTDOOR          

DAYNIGHT         

WEATHER          

CITY             

FOREST           

DUNGEON          

EXTENDEDNIGHT

 

CombatCounter(Number)

CombatCounterLT(Number)

CombatCounterGT(Number)

The combat counter is set to 150 every time an attack is made and decreases from there.  A value of 0 means that there is definitely no combat.

 

InPartySlot(Object, Slot)

This command checks to see which party Slot the Object is in.  The main character is always Slot 0.

 

PartyRested()

This command checks to see if the party has just rested.

 

SpellCast(Object, Spell)

This command checks to see if the Object has just cast the specified Spell.

 

OnScreen(Object)

This command checks to see if the Object is currently on the screen.

 

InMyGroup(Object)

This command checks to see if the Object is in my group.  The group value is set in the creature file.

 

OR(Lines)

This command is used to OR a number of Lines together.

 

IF

            PartyRested()

            Time(0)

THEN

 

This checks to see if the part has rested and the current time is midnight.

 

Actions

 

NoAction()

This command does nothing.

 

ActionOverride(Object, Action)

This commands passes the specified Action to the Object.  This is used to have one creature tell another to do something.  Eg. ActionOverride(Bob, Wait(1))

 

Attack(Object)

This command is used to attack an Object until unable.

 

AttackReevaluate(Object, Period)

This command is used to attack an Object for a Period of time.

 

AttackNoSound(Object)

This command is used to attack an Object without making an attack sound.

 

AttackOneRound(Object)

This command is used to attack an Object for one round.

 

GroupAttack(Object)

This command is used to attack an Object until dead and then pick another Object of the same type.

 

CreateCreature(Creature, Location, Face)

This command creates the Creature at the specified Location.

The Creature must be the Resref in quotes.  The Location is the coordinates in square brackets separated by a period.  The Face is a value between 0 and 15 with 0 being south and moving clockwise.

 

Eg. CreateCreature(WOLF,[550.427],4)

 

CreateCreatureObject(Creature, Object, Face, 0, 0)

This command creates the Creature beside the Object specified.  The zeros after Face must be there but are not really used.

 

CreateCreatureImpassable(Creature, Location, Face)

This command creates the Creature at the specified Location and can be placed over impassable areas such as beds and tables.

 

CreateCreatureDoor(Creature, Location, Face)

This command creates the Creature at the specified Location with a dimension door effect preceding it.

 

 

CreateCreatureObjectDoor(Creature, Object, Face, 0, 0)

This command creates the Creature beside the Object specified with a dimension door effect preceding it. The zeros after Face must be there but are not really used.

 

CreateCreatureOffScreen(Creature, Face)

This command creates the Creature at the edge of the screen. The zeros after Face must be there but are not really used.

 

CreateCreatureObjectOffScreen(Creature, Object, Face, 0, 0)

This command creates the Creature as close to the Object specified without creating it onscreen. The zeros after Face must be there but are not really used.

 

CreateCreatureAtLocation(Global, Area, Creature)

This command creates the Creature at a location saved in the Global.  The Area can be is the same as in setting or checking globals.

 

CreateCreatureObjectOffset(Creature, Object, Offset)

This command creates the Creature at an Offset to the Object.

 

Dialog(Object)

Approach the Object and starts dialog.

 

DialogForceInterrupt(Object)

Approach the Object and start dialog, interrupting any conversations.

 

StartDialog(DialogFile, Object)

Start dialog with the Object at a distance using the specified DialogFile.

 

StartDialogNoSet(Object)

Start dialog with the Object at a distance using the current DialogFile.

 

StartDialogNoInterrupt(DialogFile, Object)

Start dialog with the Object at a distance using the specified DialogFile.  This command will not interrupt another conversation.

 

StartDialogNoSetNoInterrupt(Object)

Start dialog with the Object at a distance using the current DialogFile.  This command will not interrupt another conversation.

 

SetDialog(DialogFile)

This command will set the current DialogFile to whatever is specified.

 

SetLeavePartyDialogFile()

This command sets the current DialogFile to the leave party file specified in the Pdialog.2DA.

DialogInterrupt(Boolean)

This command sets whether I can be talked to or not.

 

MoveToObject(Object)

Move to the Object specified.  Will not move to an unseen Object unless you are using the scriptname or Player1 Player6.

 

MoveToObjectFollow(Object)

Move to the Object specified and follow until another condition becomes True.

 

MoveToObjectNoInterrupt(Object)

Move to the Object specified until completed.

 

MoveToPoint(Location)

Move to the Location specified.

 

MoveToPointNoRecticle(Location)

Move to the Location specified without showing destination.

 

MoveToPointNoInterrupt(Location)

Move to the Location specified until completed.

 

MoveViewPoint(Location, ScrollSpeed)

Move the center of the screen to the Location specified.  For the ScrollSpeed, 0 is instant and gets slower the larger the number is.

 

MoveViewObject(Object, ScrollSpeed)

Move the center of the screen to the Object specified.  For the ScrollSpeed, 0 is instant and gets slower the larger the number is.

 

MoveGlobal(Area, Object, Location)

Moves a global Object, a character that can join the party, to the Area and Location specified.

 

MoveGlobalObjectOffScreen(Object, Target)

Moves a global Object, a character that can join the party, as close to the Target specified without creating it onscreen.

 

MoveBetweenAreas(Area, Location, Face)

Move to the Area at the Location specified.

 

EscapeArea()

Escape the area, find a transition or edge of screen.

 

 

 

EscapeAreaMove(Area,X,Y,Face)

Escape the area, find a transition or edge of screen, and move to the Area at X, Y.  This is the only command where the coordinates are not in square brackets and separated by a period.

 

Face(Direction)

Face the specified direction. The Face is a value between 0 and 15 with 0 being south and moving clockwise.

 

FaceObject(Object)

Face the specified Object.

 

RestParty()

This command rests the party.

 

DropItem(Item, Location)

Drop the Item at the Location specified.

 

Enemy()

Turn hostile toward the party.

 

EquipItem(Item)

Equip the specified Item.

 

CreateItem(Item, Usatge1, Usage2, Usage3)

This command creates the Item your the inventory.

The Item must be the Resref in quotes.  The Usage counts are the number of items to create in a stack.

 

Eg. CreateItem(ARROWS,20,0,0)

 

GiveItem(Item, Object)

Give the Item, must be in the inventory, to the Object.

 

GiveItemCreate(Item, Object, Usage1, Usage2, Usage3)

This command is used to create and give an Item to an Object.

 

TakePartyItem(Item)

This command is used to take an Item from the party.

 

TakePartyItemNum(Item, Number)

This command is used to take a Number of a specified Item from the party.

 

TakePartyItemAll(Item)

This command is used to take all of a specified Item from the party.

 

TakeItemListParty(List)

This command is used to take an item from the party based on a List of items.  The list is checked from top to bottom and when a matching item is found in the party inventory, that item is taken.  The list contains a default item in case the list does not match any inventory items.

 

DestroyItem(Item)

This command is used to destroy an item.

 

TakePartyGold(Amount)

This command is used to take an Amount of gold from the party.

 

GivePartyGold(Amount)

This command is used to give an Amount of gold to the party from a creatures inventory.

 

GiveGoldForce(Amount)

This command is used to create and give an Amount of gold to the party.

 

GivePartyGoldGlobal(Name, Area)

This command is used to give an Amount of gold saved in a Global to the party.

 

DestroyGold(Amount)

This command is used to destroy an Amount of gold.

 

DropInventory()

This command drops all my inventory on the ground.

 

Hide()

Try to hide in shadows.

 

JoinParty()

Join the party and change the dialog file to the join party dialog as specified in the Pdialog.2DA.

 

LeaveParty()

Leave the party.

 

PlaySound(Sound)

Play the specified sound.

 

RunAwayFrom(Object, Time)

Run away from the Object for a specified Time.  The time is in 15ths of a second.

 

RunAwayFromNoInterrupt(Object, Time)

Run away from the Object for a specified Time without being inturrpted.

SetGlobal(Name, Area, Value)

The Name must be in quotes and can be 32 chars long.

The Area must also be in quotes and can be one of the following:

            GLOBAL can be accessed anywhere in the game.

            LOCALS can only be accessed by an instance of a creature.

            AR0200 can only be accessed in the area.

 

IncrementGlobal(Name, Area, Value)

Increments the Global by the Value.

 

SetGlobalTimer(S:Name*,S:Area*,I:Time*GTimes)

 

 

Spell(Object, Spell)

Cast the Spell at the specified Object.

 

SpellPoint(Location, Spell)

Cast the Spell at the specified Location.

 

ForceSpell(Object, Spell)

Cast the Spell at the specified Object with no interruptions.

 

ForceSpellPoint(Location, Spell)

Cast the Spell at the specified Location with no interruptions.

 

SpellNoDec(Object, Spell)

Cast the Spell at the specified Object and keep it memorized.

 

SpellPointNoDec(Location, Spell)

Cast the Spell at the specified Location and keep it memorized.

 

ReallyForceSpell(Object, Spell)

Cast the Spell at the specified Object without a casting time.  This uses the spell as an ability and skips the casting animation.

 

ReallyForceSpellDead(Object, Spell)

Cast the Spell at the specified Object during the process of dying.

 

ApplySpell(Object, Spell)

Apply the Spells effects to the Object.

 

Turn()

Turn undead.

 

Continue()

Continue through the script without leaving.

 

PlayDead(Time)

Fall down and play dead for a specified Time.  The time is in 15ths of a second.

 

JumpToPoint(Location)

Jump to the Location specified.

 

ChangeAIScript(ScriptFile, Level)

Change current AI script to the ScriptFile at the Level specified.

 

The IDS file used is Scrlev.ids

 

OVERRIDE

AREA

SPECIFICS

CLASS

RACE

GENERAL

DEFAULT

 

Wait(Time)

Wait for the specified Time.  The time is in seconds.

 

SmallWait(Time)

Wait for the specified Time.  The time is in 15ths of a second.

 

UndoExplore()

 

Explore()

Explore the current area.

 

DayNight(Time)

Change the Time using the hour.

 

The IDS file used is Time.ids

 

Weather(Weather)

Change the Weather.

 

The IDS file used is Weather.ids

 

0 NOWEATHER

1 RAIN

2 SNOW

3 FOG

 

RandomWalk()

Walks in a random direction.

 

RandomFly()

Flies in a random direction.

 

RandomTurn()

Turns in a random direction.

 

SetInterrupt(Boolean)

Set the interruption of current actions to True/False.

 

Shout(Number)

Shout out a Number to anyone within sight range.

 

 

GlobalShout(Number)

Shout out a Number to anyone within the area.

 

LeaveAreaLUA(Area, Parchment, Location, Face)

This command is used to immediately move global creatures to another area.  The Parchment file is used on the loading screen.

 

DestroySelf()

This command is used to instantly destroy an object.

 

StartCutScene(CutScene)

This command starts a specified CutScene.  A cutscene is a special script that stops all AI not done in the script.  This way we can ensure that the actions in the cutscene happen as we want them to.

 

StartCutSceneMode()

This command starts the cutscene mode which disables all user buttons and turns off all AI.

 

EndCutSceneMode()

This command ends the cutscene mode.

 

CutSceneId(Object)

This command is used in a cutscene to identify the Object that is to complete the following list of commands.

 

ClearAllActions()

This command clears all the actions of everyone in the area.

 

 

ClearActions(Object)

This command will clear the actions of the Object.

 

Deactivate(Object)

This command deactivates the Object.

 

Activate(Object)

This command reactivates a Object.

 

Kill(Object)

This command will kill the Object.

 

VerbalConstant(O:Object*,I:Constant*soundOff)

 

 

OpenDoor(Door)

 

CloseDoor(Door)

 

 

Polymorph(Animation)

This command will change the my Animation without changing any stats.

 

EquipMostDamagingMelee()

This command will equip the most powerful melee weapon in my inventory.

 

StartStore(Store,Object)

This command will bring up a specified Store screen for the Object to buy and sell.

 

DisplayString(Object, String)

This command displays the String in the text window originating from the Object.

 

IncrementChapter(S:RESREF*)

 

 

ReputationSet(I:Reputation*)

 

 

ReputationInc(I:Reputation*)

 

 

AddexperienceParty(I:XP*)

 

 

 

AddexperiencePartyGlobal(S:Name*,S:Area*)

 

 

SetNumTimesTalkedTo(I:Num*)

 

 

StartMovie(S:ResRef*)

 

 

Interact(O:Object*)

 

 

RevealAreaOnMap(S:ResRef*)

 

 

AddJournalEntry(I:Entry*,I:Type*JourType)

 

 

EquipRanged()

 

 

TriggerActivation(O:Object*,I:State*Boolean)

 

 

MultiPlayerSync()

 

 

SetMasterArea(S:Name*)

 

 

EndCredits()

 

 

StartMusic(I:Slot*,I:Flags*MFLAGS)

 

 

LeaveAreaLUAPanic(S:Area*,S:Parchment*,P:Location*,I:Face*)

 

 

SaveGame(I:Slot*)

 

 

ChangeAnimation(S:ResRef*)

 

 

 

Lock(O:Object*)

 

 

Unlock(O:Object*)

 

 

TextScreen(S:TextList*)

 

 

RandomWalkContinuous()

 

 

DetectSecretDoor(O:Object*)

 

 

FadeToColor(P:Location*,I:Blue*)

 

 

FadeFromColor(P:Location*,I:Blue*)

 

 

SpawnPtActivate(O:Object*)

 

 

SpawnPtDeactivate(O:Object*)

 

 

SpawnPtSpawn(O:Object*)

 

 

StaticStart(O:Object*)

 

 

StaticStop(O:Object*)

 

 

FollowObjectFormation(O:Object*,I:Formation*,I:Position*)

 

 

AddFamiliar()

 

 

RemoveFamiliar()

 

 

 

PauseGame()

 

 

ChangeAnimationNoEffect(S:ResRef*)

 

 

SetMoraleAI(I:Morale*MoraleAI)

 

 

IncMoraleAI(I:Morale*)

 

 

DestroyAllEquipment()

 

 

GivePartyAllEquipment()

 

 

TakeItemListPartyNum(S:ResRef*,I:Num*)

 

 

SetQuestDone(I:STRREF*)

 

 

StorePartyLocations()

 

 

RestorePartyLocations()

 

 

Calm(O:Object)

 

 

Ally()

 

 

RestNoSpells()

 

 

SaveLocation(S:Area*,S:Global*,P:Location*)

 

 

SaveObjectLocation(S:Area*,S:Global*,O:Object*)

 

 

 

SetToken(S:Token*,I:STRREF*)

 

 

SetTokenObject(S:Token*,O:Object)

 

 

SetGabber(O:Object)

 

 

CreateCreatureObjectCopy(S:ResRef*,O:Object*,I:Usage1*,I:Usage2*,I:Usage3*)

 

 

HideAreaOnMap(S:ResRef*)

 

 

ContainerEnable(O:Object,I:Bool*BOOLEAN)

 

 

ScreenShake(P:Location*,I:Duration*)

 

 

AddGlobals(S:Name*,S:Name2*)

 

 

CreateItemGlobal(S:Global*,S:Area*,S:ResRef*)

 

 

FillSlot(I:Slot*SLOTS)

 

 

AddXPObject(O:Object*,I:XP*)

 

 

SetHomeLocation(P:Location*)

 

 

DisplayStringNoName(O:Object*,I:StrRef*)

 

 

EraseJournalEntry(I:STRREF*)

 

 

CopyGroundPilesTo(S:ResRef*)

 

 

RealSetGlobalTimer(S:Name*,S:Area*,I:Time*GTimes)

 

 

DisplayStringHead(O:Object*,I:StrRef*)

 

 

PolymorphCopy(O:Object*)

 

 

VerbalConstantHead(O:Object*,I:Constant*soundOff)

 

 

CreateVisualEffect(S:Object*,P:Location*)

 

 

CreateVisualEffectObject(S:DialogFile*,O:Target*)