Overview
The server-side portion of Utility Objectify is responsible for owning, spawning, and networking all entity logic in a centralized, authoritative way. While the client reacts to objects being rendered, the server creates and manages these objects in the world and coordinates interactions via RPC and plugins.
This section provides a high-level overview of what happens on the server, and how to work with it.
π§ Core Responsibilities
β
1. Entity Creation & Management
Server-side code is responsible for creating and destroying entity instances using UtilityNet
.
When a class extending BaseEntity
is instantiated:
A networked entity is created in the world.
A corresponding server-side script instance is stored in memory.
Plugins are instantiated and attached to the main object.
β 2. Plugin Instantiation If the entity class has plugins (via @plugin(pluginName)), those are automatically initialized and linked to the main instance.
β The server does not react to object rendering or visibility like the client. It owns the logic and data, while the client reacts to whatβs visible.
π§ Script Registration
π§© Plugin System
π‘ RPC Server β Client
π Entity-Based RPC (via self.server or self.client)
π§© Global RPC (via Server.<method> or Client.<method>)
π State Change Handling
π£ Event Handling
@event("eventName", ignoreRendering?)
π¦ Object Registry: Entities
Entities
π« Not Supported on Server
The following features are client-only and not applicable to server-side code:
OnRegister/OnUnregister β Only run with temporary client objects
Last updated