No replies
Jeremy
Jeremy's picture
User offline. Last seen 1 year 25 weeks ago. Offline
Joined: 06/14/2009
Posts: 268

Game Commander Pro Built In Commands

New Commands (Added since this document was first posted)

Layout [LayoutName]
Loads a screen layout and moves windows to match it. If [LayoutName] is omitted then the default layout is used.
MasterKey [Key]
Sends keys to the master computer. These keys are seen by GCPs key handler, so mapped keys will invoke the appropriate command.
MasterRun [Command]
Runs a command on the master computer. This can be a user defined command, or a built in GCP command.
MasterSet [Variable Name],[Value]
Sets a variable on the master computer.
Swap [NumberA],[NumberB]
Swaps the position of two windows
Hint: Use Swap 1,%$LeaderChan% to select with mouse


Variables
Variables in GCP may be set by calc, set and get commands (along with a few special cases set by the system or user functions)
Once a variable is set, it can be used in any command by enclosing its name in percent symbols (e.g. %MyVar%).  The value of the variable will be substituted where this placeholder is found.  These placeholders can be used in any part of a command line.


Pre Defined Variables

  • ActiveChan : Contains the active channel number
  • KeyCount : No of times the last key has been pressed - used to trigger multiple actions for a key
  • KeyTime : Time since key was last pressed - can be used as part of the above methods
  • $LeaderChan : Which channel is the current leader
  • $LeaderName : Who is the current leader



Examples:
Set x,Hello
Msg %x%
Displays “Hello”

Set y,%x% World
Msg %y%
Displays “Hello World”

Set x,1
Calc y,%x% + 1
Msg %y%
Displays 2

Set m,Msg Hello
%m%
Displays Hello

Command Syntax



<<[Character Name]>>

e.g. <<Fred>> or <<Fred,Bill,Bob>>

Sets the current character(s).  If multiple characters are specified, then the commands following this line are repeated for each character.


Active [0 or 1]

1 switches GCP on

0 switches GCP off


Assistant [Character Name]

Marks specified character as assistant.  Movement keys with <ctrl> pressed will move this character.

Broadcast [0 or 1]

1 switches on broadcast mode - all keys pressed are sent to all characters (special keys are ignored)


Calc [Result],[Calculation]

Performs a calculation and sets result variable.  Can use any VBScipt functions including those loaded in a VBScript.Load command.

Chan [Number]

Commands following this will operate on the specified channel.

<<Character Name>> will be converted to Chan [Number of channel for character]

CountDown [Time]

Starts a 1 second tick.  After the specified time a "pong" sound occurs.

Clip [Text]

Places [text] on the system clipboard

Focus

Sets window of current target to be top window (highlighted by system)

Frames [0 or 1]

Switches on/off window surrounds to enable moving and sizing.

Get [Variable Name],[Prompt]

Displays prompt, waits for a key, then stores the pressed key in variable.


GroupSet [Character],[Group]

Places character in group


Hit [Key]

sends [key] to current channel.

Supports +^! prefixes to specify shift, control and alt keys

Supports fancy key names {Return},{Tab},{Left} etc

Supports repeats {5 N} = press n 5 times

If..Else..Endif

Control of flow commands

KeyReset [time]

The system keeps count of the number of times each key is pressed.  This sets a time after which the count will be reset.  The keycount can be used to implement a different command for each press of the key using the if statement.  The KeyReset command allows this sequence to restart if the key is not pressed within a certain time.  If time is zero, the reset occurs now

Max / Std

Max zooms the current channel, Std restores window positions.

MouseBroadcast [0 or 1]

1 switches on mouse broadcast mode - all clicks are sent to all characters.

Msg [Message]

Displays a message in the GCP prompt area.  Clears automatically after 3 seconds

PassThru [0 or 1]

1 switches on passthru mode - all keys pressed are sent to current character (special keys are ignored)

Set [Variable Name],[Value]

Sets variable name to value.

System [Command]

Executes a command within the GCP addon.

Press & Release [Key]

See Hit command.  In this case, however, Press presses the key and release releases it.

Quit

Stops the program


Suspend [Time]

De activates GCP for the set time (in milliseconds)

useful if you have another application which needs to see key strokes


Script.Execute [VBScript Command(s)]

Executes one ore more VBScript commands

Script.Load [filename]

Loads a file containing VBScript functions into memory

Spare

Marks specified character as assistant.  Movement keys with <ctrl> pressed will move this character.


World Of Warcraft Commands

For these commands:
[Spell] is the name of the spell to cast
[charactername] is the name of one of your characters
[target] is the name of the target (can be [charactername] or [charactername]-target)
[group name] is the name of one of your sub-groups (such as DPS,Heals etc)
[n] is a slot number (position on your tool bar)


Command Syntax

Cast [spell] On [target] From [charactername]

Instructs a character to cast a spell.  If from is omitted, the current character is used.  If on is omitted, the spell is cast on the current target.

CastFromGroup [spell] From [group name]

Instructs a group to cast a spell.

GroupCast [spell] From [group name]

Instructs a group to cast a spell.

Focus [target]

Sets the focus of the current character to target.

Target [target]

Sets the target of the current character to target.

Follow [character name]

Instructs the current character to follow the specified character.

Slot [n]

Casts the spell in the specified slot.

GroupSlot [n] From [group name]

Instructs all of a group to cast the spell in a specified slot.


__________________

GameCommanderPro Graphics Designer / Software Engineer