Creator Guide
English
English
  • OVERDARE
    • 🚩Introduction to OVERDARE
    • 🐤Get Started
      • OVERDARE App
      • OVERDARE Studio
    • 📌Policy
      • Community Guidelines
      • UGC Creation Guidelines
      • Guidelines on the External Use of UGC
      • Logo Usage Guidelines
      • Intellectual Property Rights Policy
      • Reporting Guidelines
      • Guidelines on Disputing Suspensions and Bans
      • Creator Payout Policy
      • Monetization Guidelines
      • Forum Guidelines
    • 🅰️OVERDARE Glossary
  • MANUAL
    • 🏰Studio Manual
      • Get Started
        • Studio Interface
        • World Template
        • Coordinate System
        • Studio Test Play
        • World Publish
        • Collaboration
      • Asset & Resource Creation
        • Asset Import
        • Animation Editor
        • Setting Shadow Detail
      • Game Development
        • Game Settings
        • Script Editor
        • Align Tool
        • Material Manager
        • Collision Groups
        • Tag Editor
        • World Performance Optimization
      • Object
        • Part
        • Model
        • Camera
        • Physics
        • Lighting
        • Tool
        • VFX
        • Sound
      • Character
        • Character Animation
        • Humanoid Description
      • GUI
    • 📝Script Manual
      • Get Started
        • Script Overview
        • Basic Guide to Lua
        • Coding Style
        • Object Reference
      • Events & Communication
        • Event
        • Server-Client Communication
        • BindableEvent
        • Value Objects
      • Input & Controls
        • Mobile Input Handling
        • TPS Strafing System
      • Advanced Gameplay Systems
        • Saving & Loading Data
        • Tween
        • Module Script
        • JSON and HTTP Communication
      • Debugging & Optimization
        • Breakpoint
        • Practical Guide to Script Optimization
    • 🚀Quick Start Guide
      • Unity Developer Guide
    • 💡Creator Reference Materials
      • Game Term Translation Guide for Creators
    • 💸Monetization
      • Payout Guideline
  • DEVELOPMENT
    • 📚API Reference
      • Enums
        • ActuatorRelativeTo
        • AnimationPriority
        • AspectType
        • AssetTypeVerification
        • BorderMode
        • CameraMode
        • CameraType
        • ContextActionResult
        • CoreGuiType
        • DominantAxis
        • EasingDirection
        • EasingStyle
        • ForceLimitMode
        • HttpCompression
        • HttpContentType
        • HumanoidDisplayDistanceType
        • HumanoidStateType
        • KeyCode
        • Material
        • MaterialPattern
        • NormalId
        • ParticleEmitterShape
        • ParticleEmitterShapeInOut
        • ParticleEmitterShapeStyle
        • ParticleFlipbookLayout
        • ParticleFlipbookMode
        • ParticleOrientation
        • PartType
        • PlaybackState
        • RaycastFilterType
        • RollOffMode
        • RotationType
        • UserInputState
        • UserInputType
        • VelocityConstraintMode
      • DataTypes
        • BlendSpaceSampleSata
        • BrickColor
        • CFrame
        • Color3
        • ColorSequence
        • ColorSequenceKeypoint
        • Content
        • Enum
        • EnumItem
        • NumberRange
        • NumberSequence
        • NumberSequenceKeypoint
        • OverlapParams
        • PhysicalProperties
        • Ray
        • RaycastParams
        • RaycastResult
        • ScriptConnection
        • ScriptSignal
        • TweenInfo
        • Udim
        • Udim2
        • Vector2
        • Vector3
      • Classes
        • Animation
        • AngularVelocity
        • AnimationTrack
        • Animator
        • Atmosphere
        • Attachment
        • Backpack
        • BackpackItem
        • BasePart
        • BaseScript
        • Beam
        • BindableEvent
        • BlendSpace
        • BoolValue
        • Bone
        • Camera
        • CharacterMesh
        • CollectionService
        • Constraint
        • ContextActionService
        • CoreGui
        • DataStore
        • DataModel
        • DataStoreGetOptions
        • DataStoreIncrementOptions
        • DataStoreInfo
        • DataStoreKeyPages
        • DataStoreKeyInfo
        • DataStoreService
        • DataStoreListingPages
        • DataStoreSetOptions
        • FormFactorPart
        • Frame
        • Folder
        • GlobalDataStore
        • GuiBase2d
        • GuiButton
        • GuiObject
        • HttpService
        • Humanoid
        • HumanoidDescription
        • ImageButton
        • ImageLabel
        • InputObject
        • IntValue
        • LayerCollector
        • Instance
        • Light
        • Lighting
        • LinearVelocity
        • LocalScript
        • LuaSourceContainer
        • MaterialService
        • MaterialVariant
        • MeshPart
        • Model
        • ModuleScript
        • Mouse
        • NumberValue
        • OrderedDataStore
        • Pages
        • Part
        • ParticleEmitter
        • PhysicsService
        • Player
        • PlayerGui
        • Players
        • PlayerScripts
        • PointLight
        • PVInstance
        • ReplicatedStorage
        • RemoteEvent
        • ScreenGui
        • RunService
        • Script
        • ServerStorage
        • ServiceProvider
        • Skeleton
        • ServerScriptService
        • Sound
        • SoundService
        • SoundGroup
        • SpotLight
        • SpawnLocation
        • StarterCharacterScripts
        • StarterPack
        • StarterGui
        • StarterPlayer
        • StarterPlayerScripts
        • StringValue
        • SurfaceGui
        • SurfaceGuiBase
        • Team
        • Teams
        • TextLabel
        • TextButton
        • Tool
        • Trail
        • Tween
        • TweenService
        • TweenBase
        • UIAspectRatioConstraint
        • UserGameSettings
        • UserInputService
        • UserSettings
        • VectorForce
        • Workspace
        • WrapLayer
        • WorldRoot
        • WrapTarget
  • UPDATE
    • 📰Release Note
Powered by GitBook
On this page
  • Properties
  • Methods
  • FireServer
  • FireClient
  • FireAllClients
  • Events
  • OnClientEvent
  • OnServerEvent
  1. DEVELOPMENT
  2. API Reference
  3. Classes

RemoteEvent

RemoteEvent : Instance

Properties

Methods

FireServer

The FireServer method executes server-side functionality within the context of Lua or initiates communication with a server for data transfer.

Parameters

Tuple Arguments

Return

void

Code Samples

-- LocalScript
local ReplicatedStorage = game:GetService("ReplicatedStorage") 
local C2S_EnterPlayer = ReplicatedStorage:WaitForChild("C2S_EnterPlayer")

local SomeNumber = 10
C2S_EnterPlayer:FireServer(SomeNumber) -- Passing arguments


-----------------------------------------------------------------------------------
-- Script
local ReplicatedStorage = game:GetService("ReplicatedStorage") 
local C2S_EnterPlayer = ReplicatedStorage:WaitForChild("C2S_EnterPlayer")

local function OnEnterPlayer(player, number)
    print("[OnEnterPlayer]", player.Name, " / Parameter : ", number)
end
C2S_EnterPlayer.OnServerEvent:Connect(OnEnterPlayer)

FireClient

Fire an event to the specified player client.

Parameters

Player Player

Tuple Arguments

Return

void

Code Samples

-- Script
local Players = game:GetService("Players")
local ReplicatedStorage = game:GetService("ReplicatedStorage") 
local S2C_DeadEvent = ReplicatedStorage:WaitForChild("S2C_DeadEvent")

local SomeText = "FireClient"

local function EnterPlayer(player)
    S2C_DeadEvent:FireClient(player, SomeText) -- Passing arguments
end
Players.PlayerAdded:Connect(EnterPlayer)


-----------------------------------------------------------------------------------
-- LocalScript
local Players = game:GetService("Players")
local ReplicatedStorage = game:GetService("ReplicatedStorage") 
local S2C_DeadEvent = ReplicatedStorage:WaitForChild("S2C_DeadEvent")

local function OnDeadEvent(text)
    print("[OnDeadEvent]", "Parameter : ", text)
end
S2C_DeadEvent.OnClientEvent:Connect(OnDeadEvent)

FireAllClients

Fire an event to the All players client.

Parameters

Tuple Arguments

Return

void

Code Samples

-- Script
local Players = game:GetService("Players")
local ReplicatedStorage = game:GetService("ReplicatedStorage") 
local S2C_DeadEvent = ReplicatedStorage:WaitForChild("S2C_DeadEvent")

local function EnterPlayer(player)
    local SomeText = "FireAllClients"
    S2C_DeadEvent:FireAllClients(SomeText) -- Passing arguments
end
Players.PlayerAdded:Connect(EnterPlayer)


-----------------------------------------------------------------------------------
-- LocalScript
local Players = game:GetService("Players")
local ReplicatedStorage = game:GetService("ReplicatedStorage") 
local S2C_DeadEvent = ReplicatedStorage:WaitForChild("S2C_DeadEvent")

local function OnDeadEvent(text)
    print("[OnDeadEvent]", "Parameter : ", text)
end
S2C_DeadEvent.OnClientEvent:Connect(OnDeadEvent)

Events

OnClientEvent

The OnClientEvent is an event that is fired when the server communicates with the client via RemoteEvent. It is commonly used to notify clients about specific server actions or send data from the server to the client. This event is useful for handling client-side logic based on server-triggered interactions or updates.

Parameters

Code Samples

local ReplicatedStorage = game:GetService("ReplicatedStorage") 
local S2C_DeadEvent = ReplicatedStorage:WaitForChild("S2C_DeadEvent")

local function OnDeadEvent(text)
    print("[OnDeadEvent]", "Parameter : ", text)
end
S2C_DeadEvent.OnClientEvent:Connect(OnDeadEvent)

OnServerEvent

OnServerEvent is an event that is triggered when the client communicates with the server using RemoteEvent. It is used for handling and processing data or actions sent by the client to the server. This event is particularly useful for managing server-side logic based on client-triggered interactions or requests.

Parameters

Code Samples

local ReplicatedStorage = game:GetService("ReplicatedStorage") 
local C2S_EnterPlayer = ReplicatedStorage:WaitForChild("C2S_EnterPlayer")

local function OnEnterPlayer(player, number)
    print("[OnEnterPlayer]", player.Name, " / Parameter : ", number)
end
C2S_EnterPlayer.OnServerEvent:Connect(OnEnterPlayer)
PreviousReplicatedStorageNextScreenGui

Last updated 11 days ago

📚