Logic
Logic (WIP, HIRING) This page is a work-in-progress and may contain user notes. |
Warning This page explains advanced features, some players may not understand everything in this page. |
Wubby Logic is the second-most important thing in your Wubby worlds, They can do mostly anything such as:
- Changing block colors
- Moving blocks / platforms
- Custom NPC movement
Here are some useful links for wiring:
Easings.net | Contains most easing types with directions.
Input[edit]
Notice! Using a parallel wiring block helps reduce the chances of these blocks not firing correctly. |
Input parts are blocks that cannot be connected to in wiring, only connect to. The Input tab is clearly separated from the Special tab, as the line between them is thicker.
These are blocks that are used to power wiring systems. They do not receive wiring inputs, and can only output.
Emits a signal when touched by an unanchored block or gear debris.
Output: The part that touched it.
Configurations:
- Activation Time: How long it activates for. Default is 1
- Anchor Type: Decides what blocks get detected. Default is NonAnchored
- Color To Filter: When filter color is true, only blocks with this color will trigger it. Default is pearl.
- Filter Color: Whether if this block will only trigger when a block with the specified color touches it. Default is false.
- Use Activation Time: If set to true, the block will stop outputting when (Activation Time) passed, if set to false, it will stop outputting when the block stops touching it. Default is true.
- Reverse Output: When it was turned on, It outputs the Block itself instead of the Block that it detected
Emits a signal when clicked on.
Output: The player that clicked it.
Configurations:
- Activation Time: How long it activates for. Default is 1.
- Max Distance: How far you can click this block. Default is 32.
- Toggleable: Whether if this block acts like a switch. Default is true.
Notice! This block is Admin+. |
Emits a signal everytime the server calculates a physics frame.
Output: the deltaTime between the frames.
Notice! deltaTime is the time (in milliseconds) the server took calculating a physics frame. |
Emits a signal when a humanoid changes to the specified state.
Output: The player's username.
Configurations:
- Activation Time: How long it activates for. Default is 1.
- State: The block fires when a humanoid enters this state. Default is Landed.
- Use Activation Time: If this is off, then the block will only stop firing once the humanoid exits the state. Default is true.
Emits a signal when a player presses the selected key or mobile button.
Output: The player's username.
Configurations:
- Activation Time: How long it activates for. Default is 1.
- Input Detection Type: Determines if the block will fire if the input ended, or started.
- Use Activation Time: When this is off, the block will only stop firing once the player releases the key. This can only be turned off if the "Input Detection Type" is set to "InputStarted", otherwise this setting will be forced.
- Key: The key which the player has to press/release to trigger the block. Default is LeftShift.
- Mobile Button Enabled: If this is on, touchscreen players will get a button on their screen that activates the block.
- Mobile Button Position: The UDIM2 position (possibly scale) of the mobile button on a players screen if "Mobile Button Enabled" is on.
- Mobile Button Text: What the text on the block's mobile button will be if "Mobile Button Enabled" is on.
Emits a signal once an NPC does the selected NPC event.
Output: The NPC's NPC Block.
Configurations:
- Activation Time: How long it activates for. Default is 1.
- Event: The NPC Event to detect.
All NPC events
- NPCDied - Triggers when a NPC dies.
- NPCRespawned - Triggers when a NPC respawns.
- NPCWasAttacked- Triggers when a NPC was attacked by another NPC or player.
- NPCAttacking - Triggers when a NPC harmed another NPC or player.
- NPCWasKilled- Triggers when a NPC was killed by another NPC or player.
- NPCKilling- Triggers when a NPC killed another NPC or player.
- NPCFocusChanged- Triggers when a NPC changed it's focus another NPC or player.
- NPCPathReached- Triggers when a NPC reached it's path.
Emits a signal every time a player chats.
Output: Either the player's username or what they said depending on the "Output Type" setting.
Configurations:
- Activation Time: How long it activates for. Default is 1.
- Output Type: Determines if the block will output the players chat message or their username when its fired. Default is "Message".
Emits a signal when the selected player event is triggered.
Output: The player's username.
Configurations:
- Activation Time: How long it activates for. Default is 1.
- Event: The Player Event to detect.
All player events
- PlayerJoined - Triggers when a player joins the world.
- PlayerLeft - Triggers when a player leaves the world.
- PlayerRespawned - Triggers when a player respawns.
- PlayerKills - Triggers when a player kills another player.
- PlayerRespawned - Triggers when a player has joined the world through a warp with warp infomation.
- HealthChanged - Triggers when a player's health changes.
Emits a signal when a Player/NPC touches this block.
Output: The player's username. (If Detect is set to "NPC" it always outputs the NPC Block)
Configurations:
- Activation Time: How long it activates for. Default is 1.
- Detect: A dropdown menu with the items: Players, NPCs, Everything.
- Use Activation Time: When this is off, the block will only stop firing once the Player/NPC stops touching the block.
- Reverse Output: When it was turned on, It outputs the Block itself instead of the NPC that it detected
Emits a signal when it's Proximity Prompt has been triggered.
Output: The player's username.
Configurations:
- Activation Time: How long it activates for. Default is 1.
- Hold Duration: Amount of time to trigger the prompt. Default is 0.5
- Key: Key to hold when triggering the prompt. Default is E.
- Toggleable: Whether if this block acts like a switch. Default is true.
Emits a signal when the specified item name is bought.
Output: The player's username.
Configurations:
- Activation Time: How long it activates for. Default is 1.
- Item Name: The item to detect a purchase on.
Emits a signal when a player presses a mouse button.
Output: The player's username.
Configurations:
- Activation Time: How long it activates for. Default is 1.
- Input Detection Type: Determines if the block will fire if the input ended, or started.
- Key: What mouse button is being interacted with.
- Use Activation Time: When this is off, the block will only stop firing once the Player stops giving inputs. (Will be turned On if Input Detection Type is "InputEnded")
Logic[edit]
These are blocks that allow a player with building permissions to add extra functionality to their world, these examples include:
- A simple Counter
- A Typewriter
and etc.
Notice! An input is where the gate recieves a signal from a wire connected to it.
An output is where the gate sends a signal to a wire connected from it. "true" = active signal "false" = inactive signal This is known as a bool |
Warning Gate descriptions are in-progress and may be incorrect, if you find any incorrect circuits please use the wiki feedback form. |
Input: 2 values (any)
Output: Bool
Input: none
Output: none
- Value: The Bool Value to set a BOOL STORAGE to either True or False.
Input: none
Output: Stored Value
- Delay Before Output: Seconds to wait before outputting.
- Save Value: ??? (presumably decides whether value is saved on world restart)
- Value: The stored value.
Input: none
Output: none
- X: The X Axis of the Vector3
- Y: The Y Axis of the Vector3
- Z: The Z Axis of the Vector3
- Magnitude: Length of a Vector3
- Unit: Length of a Vector3 but in between 1 and -1
Roblox link about Vector3
Input: Vector3
Output: Number (none if Input is not a vector3)
- Axis: The axis to get from the input.
Input: any (Number if gate uses {INPUT})
Notice! The Property can be changed in the "Types" Tab in Properties |
Changes the signal into the selected property.
Input: any if input is the same property type with the selected property
Output: any
- Selected Property: The property type to change into.
wait()
)
Input: any
Output: any (same as Input)
- Delay: The amount of time to delay.
- Ignore Deactivation: Determines if the gate will stop its signal when the previous gate stopped sending its signal
Input: any (Block if Destination is not set)
Output: any (The type of the retrieved property)
- Property Name: The property to retrieve.
- Destination: The block to get the properties from.
Gets a property of the world.
Input: any (Type Needed Differs)
Output: any (The type of the retrieved property)
- Property Name: The property to retrieve.
- Value: ??
Depending on the chosen property the Input may need to be a specific type.
- NumPlayersOnTeam: Requires a team name as input.
- IsPlayerOnServer: Requires a username as input.
- TotalColoredBlocks: Requires a color as input.
Gets a property of the specified NPC Block.
Input: any (NPC Block if no Destination is set)
Output: any (The type of the retrieved property)
- Property Name: The property to retrieve.
- Destination: The NPC Block to get the properties from.
Gets a property of the specified player.
Input: Player Username
Output: any (The type of the retrieved property)
- Property Name: The property to retrieve.
- Property Name: The advanced property to retrieve, it is only use for Body Color.
Gets the stat of the specified player.
Input: Player Username
Output: Number
- Stat Name: The stat to retrieve.
Input: any
Output: Bool
- Check Type: How the value is compared.
- Keep Activation: Determines if the gate will stop its signal when the previous gate stopped sending its signal
- Value: The value to compare the Input to.
Input: any
Output: Player Username
- Active Time: How long each loop takes. (seconds)
- Delay: How long to wait for another loop. (seconds)
- Loop Type: Determines if it loops through NPCs or Players.
Input: Number
Output: Number
- Math Order: Determines if the Input is before the Value and vice versa.
- Operation Type: The operation to do.
- Next Gate Type: Determines if the output needs to go through a NUMBER STORAGE to complete an operation.
- Disable Output: Determines if a connected NUMBER STORAGE outputs its value after this gate output.
- Value: The value to calculate the Input with.
Input: any
Output: Signal
Notice! Use |
Sets the value of a NUMBER STORAGE Gate
Input: any (Number if using Input)
Output: none
- Disable Output: Determines if a connected NUMBER STORAGE outputs its value after this gate output.
- Value: The value to store the NUMBER STORAGE.
Input: Number
Output: Number
- Delay Before Output: Seconds to wait before outputting.
- Save Value: ??? (presumambly decides whether value is saved on world restart)
- Value: The stored value.
Notice! This gate will pass any input it receives to its output. |
If 1 or more signals are connected to this gate, this gate will fire.
Input: any
Output: any
Outputs a signal when a player owns a pass/gear.
Input: Pass Name/Gear ID
Output: Player Username
- Pass/Gear ID: The pass/gear id used for check if a player has the inputted pass or not.
- Activation time: how long the signal will last until it loops back again.
- Delay: how long to wait before the next loop starts
- Loop Type: How the repeater will behave.
- Increment: The Increment to use when in enumerating or repetition mode (eg if increment is 2 then the loop would be like 2, 4, 6,...).
- Start index: the starting number the repeater will use
- Finish index: the ending number the repeater will use
Sets the stat of the input and outputs the stat's value
Input: Player Username
Output: Number
- Operation Type: Set, add or subteact the stat value.
- Stat name: The stat name to set.
- Value: The new value to set (or add / subtract) the stat.
Sets the value of the connected TEXT STORAGE.
Input: any
Output: none (String if Next Gate Type is Normal)
- Next Gate Type: Decides if it can go through only a TEXT STORAGE or any gate.
- Disable Output: Determines if a connected TEXT STORAGE outputs its value after this gate output.
- Operation Type: Decides what to do with the value.
- Value: The value to set a TEXT STORAGE to. (Output if Next Gate Type is Normal)
Brings up a dialog box on the Input's screen and outputs the response.
Input: any
Output: String
- Cancel Button Disabled: Decides of if the Cancel / X Button shows up.
- Input Position: Changes the dialog's position.
- Input Size: Changes the dialog's size.
Stores a text value that can be edited using a TEXT EDITING Gate.
Input: TEXT EDITING Signal
Output: String
- Delay Before Output: Seconds to wait before outputting.
- Save Value: ??? (presumambly decides whether value is saved on world restart)
- Value: The stored value.
Input: Number
Output: Number
- Operation type: Decides what to do with the X, Y and Z numbers.
- X: X of the vector.
- Y: Y of the vector.
- Z: Z of the vector.
Input: any (Multiple)
Output: Bool
Notice! The ColorSpace can be changed in the "Modes" Tab in Properties |
Input: Number
Output: None
- Red: Output Red Value
- Green: Output Green Value
- Blue: Output Blue Value
- Hue: Output Hue Value
- Saturation: Output Saturation Value
- Hex: Output Hex Value
- Brickcolor: Output the closest Brickcolor
- Value: Output Value Value (Lol)
Output: Color
Input: Signal
Output: None
Output[edit]
These are blocks that can be connected to, but despite the name, also can connect TO blocks.
Legend[edit]
* - Not in the Output section of the Build tab, but still technically output since it can be connected to.
List[edit]
Notice! Please turn these into tabs, copy the above tabs code in the source editor and go from there. |
- Attach Block
- Attribute Changer
- Camera Block
- Clone Block
- Command Block
- Message Display Block
- Path Block
- Property Changer
- Wirer Block
- Wiring Variable Block
- World Setting Changer
- Zone Changer
- Motor*
- Sound Block*
- Morph Block*