-
Notifications
You must be signed in to change notification settings - Fork 18
Script API
Cook Green edited this page Apr 11, 2019
·
15 revisions
AMGE has a individual script system like lua or python
Each global variable in the script file started with $
Each local variable in the script file started with %
There are 9 register variable in the system, you can store some specific value in them
| Register Variable | Description |
|---|---|
reg0~5 |
Global Register Variable #1~#5 |
vect1~5 |
Global Vector Variable #1~#5 |
| Script Command | Param | Description |
|---|---|---|
add_light |
#1: Light Type #2: Light Name #3: Light Position Vector #4: Light Direction Vector |
Add a specific light to the scene with specific name |
assign |
#1: Variable Name #2: Variable value |
Assign a value to a specific variable |
call |
#1: Function Name | Call a function with specific name |
end |
None | End Syntax |
function |
#1: Function Name | Start a function code region, and end with end
|
init_vector |
#1: Vector Variable | Reset value a vector |
loop |
#1: Start Value #2: End Value #3: Step |
Start a loop code region, and end with end
|
remove_light |
#1: Light Name | Remove a light with specific name |
spawn |
#1: Character Type #2: Character ID #3: Character Team #4: Spawn Vector |
Spawn a character with specific id and name |
store |
#1: Destion Value #2: Source Value |
Store value to destion value from source value |
trigger |
#1: Trigger Name #2: Trigger Delay Time #3: Trigger Frozen Time |
Start a trigger code region, and end with end
|
vector_get_x |
#1: Destion Value #2: Vector Variable |
Get Vector Variable x value |
vector_get_y |
#1: Destion Value #2: Vector Variable |
Get Vector Variable y value |
vector_get_z |
#1: Destion Value #2: Vector Variable |
Get Vector Variable z value |
vector_set_x |
#1: Vector Variable #2: Value |
Set Vector Variable x value |
vector_set_y |
#1: Vector Variable #2: Value |
Set Vector Variable y value |
vector_set_z |
#1: Vector Variable #2: Value |
Set Vector Variable z value |