📖 Wall Plast Documentation
Complete guide to the game scripting language
Language Syntax
▼The programming language has a simple and intuitive syntax. The syntax is as follows: first comes a command (case doesn't matter), and parameters are separated by underscores _.
Log_"Hello world!"
Here Log is the command, and "Hello world!" is the parameter
Basic syntax rules:
- Command name is case-insensitive (Log, log, LOG - all work the same)
- Parameters are separated by underscores
_ - Text parameters are usually written in quotes for clarity to the script
- Multiple commands are separated by
;for sequential execution
SetActive_"Block"_false; Log_"block hidden";
SetActive executes first, then Log. This way you can combine command execution across multiple lines.
Math in Scripts
The language supports mathematical calculations and lets you compute values right in the code. Supported operators: + (addition), - (subtraction), * (multiplication), / (division).
Wait_2+2;
transform_"Block"_position_y = 10 * 5;
player_target_activated_moveSpeed *= 2;
Script waits 4 seconds, teleports block to height 50, doubles player speed
Assignment operators:
When you change values (position, text, etc), you can use different operators:
=- set exact value+=- add to current value-=- subtract from current value*=- multiply current value/=- divide current value
Working with text (concatenation):
Text values can be "concatenated" using +. This lets you combine text strings and variable values:
text_"Sign" = "Level: " + 5;
text_"Status" = "Player: " + "Alice";
local_Message = "HP: " + player_target_activated_hp;
Plate Events
▼Scripts are attached to specific plate events. It's important to understand when each one triggers. The event determines the moment and conditions when your script will execute.
| Event | Description |
|---|---|
| Start | Executes exactly once when you start the map test. If you return to build mode and start the test again, the script executes again. Perfect for initializing variables and initial setup. |
| Update | This script runs constantly and continuously throughout the game, executing every frame. Great for constant state checks or continuous object movement. |
| OnPress | Triggers exactly ONCE the moment when a player (or multiple) steps on the plate and it depresses. If OnRelease or WhileNotPressed scripts are running at this time, they are immediately interrupted (stopped) to not interfere with press logic. |
| WhilePressed | Executes continuously in a loop all the time someone is on the plate. Triggers right after OnPress and continues until OnRelease. |
| OnRelease | Triggers exactly ONCE when the plate returns to its original (depressed) state and all players have left it. At this point, OnPress and WhilePressed scripts are immediately stopped. |
| WhileNotPressed | Executes continuously in a loop all the time no one is on the plate. Triggers after OnRelease. |
Event execution logic:
Start ➜ Update (continuous)
↓
Player pressed ➜ OnPress (once) ➜ WhilePressed (continuous)
↓
Player left ➜ OnRelease (once) ➜ WhileNotPressed (continuous)
Coordinates and Vectors (Vector3)
▼To manage objects in three-dimensional space (position, size, rotation), use the vector concept Vector3_X_Y_Z, where X, Y, Z are numbers, variable values, or mathematical expressions. X is horizontal position (left-right), Y is vertical position (up-down), Z is depth (forward-backward).
Vector3_10_5_1.5
Where X=10, Y=5, Z=1.5
Applying a vector to an object:
You can apply the entire vector to an object to change all coordinates simultaneously:
transform_"Block"_position = Vector3_0_10_0;
Teleports block to coordinates X=0, Y=10 (up), Z=0
Or change only a specific axis (x, y or z):
transform_"Block"_position_y += 5;
transform_"Block"_position_x = 20;
transform_"Block"_position_z -= 3;
Raises block by 5 units, moves to 20 on X, pushes back 3 on Z
Supported axes: x, y, z
Working with vectors in math:
You can use mathematical expressions when creating vectors:
Vector3_10*2_5+5_1.5;
transform_"Block"_position = Vector3_(player_target_activated_transform_position_x)_0_0;
Convert to String (_tostring)
▼To display coordinates, properties, or calculation results on a text panel, add the _tostring suffix at the end of the variable or property.
text_"MySign" = "Block: " + transform_"Block"_position_tostring;
text_"HealthBar" = "HP: " + player_target_activated_hp_tostring;
SetActive - Object Visibility Control
▼Controls whether objects are active in the game world. Inactive objects are not rendered, don't interact with physics, and don't execute scripts. This is useful for hiding/revealing objects, managing scene complexity, and creating dynamic game mechanics.
Syntax:
| Parameter | Description |
|---|---|
| a | Object name in quotes, for example "Door" or "Light". Can be a variable (without quotes) |
| b | true (object is active, visible and working) or false (object is inactive, hidden) |
Common use cases:
SetActive_"Door"_false;
Log_"Door is hidden";
SetActive_"Light"_true;
transform_"Light"_position = Vector3_0_5_-10;
local_doorName = "MainDoor";
local_isOpen = true;
SetActive_local_doorName_!local_isOpen;
SetActive_"Door"_false;
SetActive_"Light"_true;
SetActive_"Trap"_false;
text_"Status" = "Objects toggled";
Cycle_5 {
SetActive_"Moving_Box"_true;
Wait_1;
SetActive_"Moving_Box"_false;
Wait_1;
}
ChangeSound - Audio Control
▼Allows you to manage speaker parameters in real time. Change music, volume, playback speed, working range and other properties of the audio source.
Syntax:
ChangeSound_"speaker"_"SoundCode"_volume_speed_radius_canPlayerToggle_playOnStart_visible_globalAudio
Parameters:
| Parameter | Type | Description |
|---|---|---|
| a | string | Speaker object name |
| b | string | Music code (must be defined in map properties) |
| c | float | Music volume (0.0 - 1.0 and higher) |
| d | float | Playback speed (1.0 = normal) |
| e | float | Sound reach radius in game units |
| f | bool | Can player toggle speaker on/off (true/false) |
| g | bool | Play music when map loads (true/false) |
| h | bool | Show speaker 3D model in world (true/false) |
| k | bool | Audible everywhere on map, regardless of distance (true/false) |
Usage examples:
ChangeSound_"speaker"_"WpNight"_1_1_15_false_true_false_true;
local_volume = 0.5;
ChangeSound_"speaker"_"WpNight"_local_volume_1_15_true_true_true_false;
ChangeSound_"AmbienceLoop"_"Forest"_0.8_1_100_false_true_false_true;
ChangeSound_"BellRing"_"BellSound"_0.7_1_20_false_true_true_false;
if (contains_text_player_target_activated_name_"bot") {
ChangeSound_"speaker"_"FastMusic"_1_1.5_20_false_true_false_false;
} else {
ChangeSound_"speaker"_"SlowMusic"_0.8_1_15_true_true_false_false;
}
Log - Debug Output
▼Outputs debug messages to the developer console. Useful for tracking script execution, variable values, and diagnosing problems.
Syntax:
Log_"Message";
Message types:
| Parameter | Type | Description |
|---|---|---|
| a | string | Message to output in quotes (supports string concatenation with +) |
| b | string | Log type (optional): "warning" (yellow) or "error" (red). Default is normal message (white) |
Message types:
- Normal: Log_"Message"; (white message)
- Warning: Log_"Message"_"warning"; (yellow message)
- Error: Log_"Message"_"error"; (red message)
Log_"Hello World!";
Log_"Critical error!"_"error";
Log_"Low HP value"_"warning";
local_playerName = player_target_activated_name;
local_score = 100;
Log_"Player: " + local_playerName + ", Score: " + local_score;
Log_"Script started!";
SetActive_"Door"_true;
Log_"Door opened";
Wait_2;
Log_"Wait completed"_"warning";
Wait - Delay
▼Stops script execution for a specified number of seconds. Useful for creating pauses between events, synchronizing animations, or creating delays in game logic.
Syntax:
Wait_seconds;
Parameters:
| Parameter | Type | Description |
|---|---|---|
| a | float/int | Time in seconds - supports decimal numbers (0.5, 1.25, etc.) and mathematical expressions |
Features:
- Time is specified in seconds
- Decimal numbers are supported for delays less than 1 second
- Mathematical expressions can be used
- While waiting, the rest of the code does not execute
- Variables can be used for time values
Log_"Starting";
Wait_2;
Log_"2 seconds have passed";
Wait_0.5; // Half a second
Wait_0.1; // 0.1 seconds
Wait_2+3; // Wait 5 seconds
Wait_10/2; // Wait 5 seconds
Wait_1*5; // Wait 5 seconds
local_delayTime = 3;
Log_"Waiting " + local_delayTime + " seconds";
Wait_local_delayTime;
Log_"Waiting completed";
SetActive_"Light1"_true;
Wait_1;
SetActive_"Light2"_true;
Wait_1;
SetActive_"Light3"_true;
Wait_0.5;
text_"Status" = "All lights on";
Cycle_3 {
Clone_"Box";
Wait_0.5;
Log_"Clone created";
}
Cycle - Loops
▼Executes a block of code a certain number of times.
| Parameter | Description |
|---|---|
| a | Number of repeats: integer (int) or inf (infinite) |
Cycle_5 {
Log_"cycled";
}
Cycle_inf {
Log_"Infinite loop";
}
Transform - Object Transformation
▼Allows you to change object position, rotation, and scale.
| Parameter | Description |
|---|---|
| a | Object name in quotes |
| b | Property: position, localposition, rotation, localrotation, scale |
| c | Axis (optional): x, y or z |
| d | Value: number or Vector3_x_y_z |
transform_"Block"_position_y += 5;
transform_"Block"_scale = Vector3_2_2_2;
transform_"Block"_rotation_z = 45;
Clone - Object Cloning
▼Creates exact copies of objects during script execution.
Method 1: Automatic name
Clone_"WoodCube";
Clone gets name: WoodCube_(1), WoodCube_(2) etc.
Method 2: Custom name
Clone_"WoodCube"_"MyNewCube";
Method 3: Save to variable
local_SpawnedCube = clone_"WoodCube";
transform_local_SpawnedCube_position_y += 10;
Clone yourself:
Clone_"self";
Destroy - Object Removal
▼Removes an object from the map during gameplay.
Destroy_"Door";
Destroy_"self";
Parent - Parenting
▼Connects objects in a hierarchy. Parented objects follow their parent's movement.
Parent block to another block:
transform_"Hat"_parent = transform_"HeadBlock";
Parent block to player:
transform_"Block"_parent = player_target_activated;
Unparent object:
transform_"Hat"_parent = "none";
Parent player to platform:
player_target_activated_parent = "Platform";
Text - Change Text
▼Changes text on text objects.
Parameters:
a- Text object name in quotesb- Text in quotes (supports + concatenation)
text_"MySign" = "Hello!";
text_"MySign" += " How are you?";
textraw_"MySign" = "Just text";
Difference between text and textraw:
text- supports concatenation and variablestextraw- inserts text as-is, without processing
Player - Player Management
▼Powerful command for interacting with players, changing stats, and teleporting.
Search modes (mode):
target- search by targetnickname- search by nicknamesaved- use saved player
Selectors for target:
all- all playersnearest- nearest playerfarthest- farthest playerrandom- random playeractivated- player who triggered the platelocal- local player
Usage examples:
player_target_activated_hp -= 10;
player_target_nearest_jumpForce += 5;
player_target_all_moveSpeed = 10;
Save a player:
player_save_"Winner"_target_activated;
player_saved_"Winner"_hp = 100;
Player Stats
▼All available parameters for controlling player characteristics.
Basic stats:
| Stat | Description |
|---|---|
hp |
Current player health |
maxHp |
Maximum health |
moveSpeed |
Running speed |
jumpForce |
Jump height |
respawnDuration |
Wait time before respawn |
Stamina:
| Stat | Description |
|---|---|
doesNotNeedStamina |
Disable fatigue (1=yes, 0=no) |
maxStaminaValue |
Maximum stamina pool |
staminaValue |
Current stamina |
staminaRegen |
Stamina regeneration speed |
staminaWaitTimeForRegen |
Delay before regeneration starts |
player_target_activated_moveSpeed += 5;
player_target_all_doesNotNeedStamina = 1;
player_target_nearest_hp = player_target_nearest_maxHp;
Variables and Data Storage
▼Variables are virtual "boxes" for storing values. Creating and modifying variables requires no special commands.
Variable types by scope:
| Type | Scope | Example |
|---|---|---|
| local_ | Personal for player, all plates on map | local_Coins = 10; |
| global_ | Synced on server, visible to all | global_Score = 100; |
| self_ | Only this plate, for current player | self_Count = 5; |
| globalself_ | Only this plate, synced for all | globalself_Health = 50; |
| plate_ | Other plate's local variable | plate_"Manager"_Value = 10; |
| globalplate_ | Other plate's global variable | globalplate_"Boss"_HP = 100; |
Working with numbers and text:
local_Health = 100;
local_Health -= 25;
local_Health *= 2;
global_Name = "Player1";
local_Message = "Hello, " + global_Name;
Random - Random Numbers
▼The language has a built-in powerful random number generator that works like an "on-demand" variable. Instead of a variable name, you write the random command and the game automatically substitutes a random number! This lets you create diverse and unpredictable gameplay mechanics.
Basic syntax:
random_(Min)_(Max)
Random integer (int):
Generates an integer in the range, including boundaries:
local_Dice = random_1_6;
local_Chance = random_0_100;
self_AttackDamage = random_10_25;
Will generate numbers: 1 to 6, 0 to 100, 10 to 25 inclusive
Random float (with decimal):
Generates a number with a decimal part:
local_Chance = random_0_1_float;
local_Speed = random_0.5_2.5_float;
Will generate numbers: 0.0 to 1.0 (e.g. 0.43), 0.5 to 2.5 (e.g. 1.73)
Random with step (rounding):
Generates a number that is a multiple of a specific step:
local_Angle = random_0_360_float_0.5;
local_Price = random_100_1000_int_50;
Will generate numbers: 0 to 360 with 0.5 step (45.5, 120.0 etc), 100 to 1000 with 50 step
Practical usage examples:
transform_"Enemy"_position_x = random_-50_50_float;
transform_"Enemy"_position_z = random_-50_50_float;
local_Action = random_1_3;
if (local_Action == 1) {
Log_"Selected option 1";
}
Conditions (If / Else If / Else)
▼Conditions allow you to execute different code depending on the situation.
Basic syntax:
if (condition) {
// Code if true
} else if (other_condition) {
// Code if first is false but this is true
} else {
// Code in all other cases
}
Comparison operators:
==- equal!=- not equal>- greater than<- less than>=- greater than or equal<=- less than or equal
Logical operators:
&&- AND (both parts must be true)||- OR (at least one part must be true)
Password check example:
if (local_Password == "1234") {
SetActive_"Door"_false;
Log_"Access granted!";
} else {
Log_"Invalid password!"_"error";
}
Player health check:
if (player_target_activated_hp < 30) {
player_target_activated_hp += 50;
Log_"Player saved!";
} else if (player_target_activated_hp == player_target_activated_maxHp) {
Log_"Health at maximum";
}
Complex check with AND/OR:
if (local_Coins >= 10 && local_HasKey == "true") {
Log_"Chest opened!";
local_Coins -= 10;
} else {
text_"Info" = "Need 10 coins and key!";
}
Contains - Text Search
▼Operator contains checks if one text is inside another. Case-insensitive.
Syntax:
if (text1 contains text2) { ... }
Check object name:
if (transform_"SecretDoor"_name contains "Door") {
Log_"Name contains Door!";
}
Password check:
if (local_EnteredPassword contains "admin") {
Log_"Found word admin"_"warning";
}
Foreach - List Iteration
▼Foreach is a loop that iterates through each element in a list (array) and stores the current element's name in a variable at each step. Inside the curly braces you write code that executes for EACH list element in sequence.
Syntax:
foreach (variable in list) {
// Code executes once for each element
// "variable" will contain the current element's name
}
You can use any variable type (local_, global_, self_ etc) as the variable. At each step it will record the name (name) of the current object or player from the list.
Available lists (arrays):
GetAllObjects- list of all objects present on the mapGetAllPlayers- list of all players currently in the gametransform_(a)_childs- list of child objects "attached" to object (a)player_(mode)_(selector)_childs- list of child objects "attached" to a player
Usage examples:
foreach (local_Item in GetAllObjects) {
Log_"Found object: " + local_Item;
}
foreach (local_P in GetAllPlayers) {
player_nickname_local_P_hp = player_nickname_local_P_maxHp;
}
foreach (local_Child in transform_"Container"_childs) {
SetActive_local_Child_false;
}
player_nickname_VariableName_... or transform_VariableName_...
Name - Object and Player Names
▼Each object in the world and each player has a name property that uniquely identifies them. Object names can be read and modified at any time, while player names are read-only for security reasons.
Object Names:
Every object has a unique name that persists if you save the map or clone the object.
Getting an object name:
transform_"Block"_name
Player Names (Name vs Nickname):
Players have two name properties:
| Property | Description |
|---|---|
name |
Internal player identifier (assigned by system, read-only) |
nickname |
Player's display name (set if player connected to server, shorter and user-friendly) |
Syntax for reading player names:
| Syntax | Returns |
|---|---|
player_target_activated_name |
Internal name of activated player |
player_target_activated_nickname |
Real nickname (if player is connected) |
player_[selector]_[filter]_name |
Internal name with selector and filter |
player_[selector]_[filter]_nickname |
Nickname with selector and filter |
Modifying object names:
Object names can be changed during script execution. This is useful for tracking objects or simplifying references later.
transform_"Block"_name = "NewName";
transform_"Block"_name += "_2";
text_"Output" = transform_"NewName_2"_name;
Real-world usage examples:
text_"Welcome" = "Hello, " + player_target_activated_nickname + "!";
clone_"Projectile"_transform_"Bullet1" = new_transform;
transform_"Bullet1"_name = "fired_projectile_" + timer_;
log_(transform_"fired_projectile_" + timer__name);
if (player_target_activated_nickname != "") {
text_"Info" = "Server player: " + player_target_activated_nickname;
} else {
text_"Info" = "Offline player: " + player_target_activated_name;
}