Game Editor - the easy game design software.
 

    Actor Actions

Home  
 
Getting Started  
Scripting  
 
FAQs  
Welcome   How Game Editor Works   Interface   Main Menu   Actor Control   Events   Actions
 
   


Actor Actions

Action is what should happen in response to an event. For example, when an actor collides with a rocket an explosion should be created. Game Editor has a set of predefined actions and any events can fire one or more actions.
Actions follow Events. If the event defines a Mouse Down click on an Actor, the Action takes place after the mouse click Event occurs.

Notes about Actors:

- "Event Actor" is the Actor that currently receives the Event.
- "Parent Actor" is the current Actor's parent, if exists.
- "Creator Actor" is the creator of
the current Actor, if the Actor is created in the "Create Actor" Action.
- If an Actor's name is selected, all of the Actor's clones will receive the
Action.
- If the "Collision Event" is selected, the "Collide Actor" is the Actor that currently collides.
- An Actor's Action is immediately  executed when an Event occurs, or it can be put in a queue, to be executed when certain frames of a specified animation are displayed.

Action execution:

Clicking the "Add" button for all Actor Actions, enables you to choose if an action will execute immediately at an Event's occurrence, or if the Action will be executed at a specific frame: "Wait for Frame".

Animation: Select an Actor Animation.
Frames:
Enter the frame numbers where the action should happen. (For Example: 14;2...)
Specify whether only the last action in the queue must be executed.

 

Game Editor supports the following Actions:

Change Animation
Change Path
Conditional Action
Destroy Timer

Move To
Script Editor
Change Animation Direction
Change Transparency
Create Actor
Event Disable
Physical Response
Set Text
Change Cusor
Change Z Depth
Create Timer
Event Enable
Play Music
To Anterior Position
Change Parent
Collision State
Destroy Actor

Follow Mouse
Play Sound
Visibility State

Change Animation:

Change the current Actor's Animation.

Actor: Select the Actor that will have its animation changed.
Animation:
Select the Actor's Animation.
Direction:
Specify whether
the animation starts in normal, reverse or stopped mode.

This action will change the animindex variable.
You can't change the animation of a collide actor.

script function

Change Animation Direction:

Change the current Actor's Animation Direction.

Actor: Select the Actor that will have its animation direction changed.
Direction:
Specify whether
the animation starts in normal, reverse or stopped mode.

script function

Change Cursor:

Change the current Actor's Mouse Cursor.

Actor: Select the Actor.
File:
Select image file (Load jpeg, gif, png, bmp, pcx, tga, xpm, xcf, lbm and tif image files).
Horizontal Frames:
Enter the number of horizontal frames.
Vertical Frames:
Enter the number of vertical frames.
Hotspot X:
X coordinate of the Cursor hot spot.
Hotspot Y:
Y coordinate of the Cursor hot spot.

script function

Change Parent:

Change the selected Actor's Parent.

Child: Select the Child Actor.
Parent:
Select the Parent Actor.

script function

Change Path:

Change the selected Actor's Path.

Actor: Select the Actor that will have its path changed.
Path:
Select a path (options include: any path that you have previously created, "no path" and "random path").
Axis:
Specify whether this path affects x axis, y axis or both axis.

script function

Change Transparency:

Change the selected Actor's  Transparency.

Actor: Select the Actor that will have its transparency changed.
Transparency:
Set the amount of transparency using the slider bar. Slide the bar to the right for greater transparency and to the left for less transparency.

script function

Change Z Depth:

Change the selected Actor Depth.

Actor: Select the Actor that will have its position changed relative to the Z axis.
Z Depth:
Set the amount of depth using the slider bar. Slide the bar right for greater
depth and to the left for less depth.

script function

Collision State:

Enable or Disable  collisions on selected Actor.

Actor: Select the Actor.
State:
Enable or
Disable.

script function

Conditional Action:

Call Actions if Expressions match certain Conditions.

Expression 1 and Expression 2: Expressions that will be compared.
Condition:
Equal, Greater Than, Less Than, Greater or Equal To, Less or Equal To.
The drop down lists show Actors and variables that can be used in the comparison.

Create Actor:

Put a new Actor in the game.

Actor: Select an actor to create.
Animation:
Animation name for the selected actor.
Parent:
Select an Actor's parent (options include any previously created Actor, the "view" Actor, and "no parent").
Path:
Select  a path (options include: any path that you have previously created, "no path", and "random path").
x,y:
Set the coordinates of a New Actor's initial position.
Relative to creator:
True or false.

script function

Create Timer:

Create a Timer for the selected Actor.

Actor: Select the Actor.
Timer:
Select the timer.

If you wish to specify a new timer, select "New Timer".

Name: New Timer name.
Time:
Timer interval in milliseconds.
Type:
Periodic or Random timer.
Min time:
For Random timers, specify the minimum timer interval here and the maximum timer interval in the Time field.
Repeat:
"Forever" or "Specify Quantity".
Count:
If the timer is not set to "Forever", set number of repetitions here.

script function

Destroy Actor:

Destroy the selected Actor.

Actor: Select the Actor to be destroyed.

script function

Destroy Timer:

Destroy the selected Timer.

Timer: Select the Timer to be destroyed.
Destroy Timer action must be called in the actor that have an active timer.

script function

Event Disable:

Disable a specified Event.

Actor: Select the Actor.
Event:
Select the Event to be Disabled.

script function

Event Enable:

Enable a specified Event.

Actor: Select the Actor.
Event:
Select the Event to Enable.

script function

Follow Mouse:

Make the Actor Follow the Mouse.

Actor: Select the Actor that will follow the mouse.
Axis: Specify if this path affects "x" axis, "y" axis, "both" axis or "none" axis (end following).

script function

Move To:

Move the Actor to a specified position, at a specified velocity.
Causes the Move Finish event when the actor reaches the specified position.

Actor: Select the Actor.
x, y:
position.
Velocity:
movement velocity/speed. Use high numbers to do a instantaneous move. (Higher number = greater speed)
Relative to: The
Actor can be moved relative to the game center (absolute coordinate), relative to the mouse or any actor in the game.
Avoid: Set the actor to avoid collisions while moving.
If you select the actor name, not a clone name, all clones will be considered.
If you select a actor with tiles, the bound box of each tile will be considered.

Only the actor bound box will be considered, not the real shape.

The move path is calculated only when the action is executed.
So, if you need avoid collision with other moving actors, you need to call the
Move To action again.

To make a more natural move, the resulting path is smoothing, so if you want to move
the actor through a maze, sometimes the actor will touch the walls.


Examples:

1) Move the Event Actor to the right 10 positions
Actor:= "Event Actor"
x: 10
y: 0
velocity = 1000 (Use a high velocity to instantaneously move an actor.)
Relative to: "Event Actor"
Avoid: (none)

2) Move the view to the player position.
Actor = "view"
x: 0
y: 0
Relative to: "player"
Avoid: (none)

3) Move the player to the mouse position.
Actor:"player"
x: 0
y: 0
Relative to: "Mouse Position"
Avoid: (none)

4) Move the player to the mouse position, avoiding lakes in a terrain.
Actor:"player"
x: 0
y: 0
Relative to: "Mouse Position"
Avoid: "lake"

script function

Physical Response:

Physically Move an Actor after a Collision Event.

Move: After collision, move "Event Actor Only", "Collide Actor Only" or "Both Actors"
Mass: Select "Use Calculated" to use the internally calculated mass. Select "Specify" to manually enter an Actor's mass.
- Event Actor: Enter the Event Actor's mass in "Specify" mode or the Event Actor's mass multiplier in the "Use Calculated" mode.
- Collide Actor:
Enter Collide Actor's mass in "Specify" mode or the Collide Actor's mass multiplier in the "Use Calculated" mode.

Final velocity multiplier:
- Event Actor:
Event Actor's calculated velocity multiplier.
- Collide Actor:
Collide Actor's calculated velocity multiplier.

script function

Play Music:

Play selected music upon an Event.

File: Select music file (Load Ogg Vorbis, wav, mid, s3m, it, or xm music files).
Volume:
Set music volume.
Loop:
Set loop count (1 to 65000 or 0 to infinite loop)
Startup Priority:
In slower machines, like PDA devices, the music may load very slowly. Setting the "Startup Priority" for your machine will help to address the speed issues.

- High: The game stops while the music loads, but is the fastest music mode.
- Medium: The game doesn't stop while the music loads, but this mode can be slow.
- Low: The game will play in normal velocity, but the music load will be slow.

Notes:
- Music files are not entirely loaded into memory.
- Only one music file will be played at a time.


script function

Play Sound:

Play a selected Sound upon an Event.

File: Select a sound File (wav, voc, iff audio files).
Volume:
Set the sound "Volume".
Pan:
Set the sound "Pan".
Loop:
Set the loop count (1 to 65000 or 0 to infinite loop).
The maximum simultaneous sound must be adjusted in "Game Properties" panel.

script function

Script Editor:

Enter a C Script to be executed upon an Event.
Read more aboud scripts here.

Set Text:

Set or change the Actor text. See text actor.

To Anterior Position:

Send the Actor to the Anterior Frame Position.

Actor: Select the Actor.

script function

Visible State:

Show or Hide the selected Actor.

Actor: Select the Actor.
State:
"Enable" (show the Actor), "Disable" (hide the Actor) and "Don't draw, but allow events" (use to speed up collision map Actors).

script function

 

Scripting >>

 
   

Home     Top