diff --git a/redist/redist-manifests/.manifest.redist-server-publicized.txt b/redist/redist-manifests/.manifest.redist-server-publicized.txt index 4384ba88..f0db02d8 100644 --- a/redist/redist-manifests/.manifest.redist-server-publicized.txt +++ b/redist/redist-manifests/.manifest.redist-server-publicized.txt @@ -1 +1 @@ -8214312218889421489 +4222459000333949915 diff --git a/redist/redist-server-publicized/Assembly-CSharp.dll b/redist/redist-server-publicized/Assembly-CSharp.dll index c4fc6fdb..064649d1 100644 Binary files a/redist/redist-server-publicized/Assembly-CSharp.dll and b/redist/redist-server-publicized/Assembly-CSharp.dll differ diff --git a/redist/redist-server-publicized/Assembly-CSharp.xml b/redist/redist-server-publicized/Assembly-CSharp.xml index 28131ee0..77fa68c6 100755 --- a/redist/redist-server-publicized/Assembly-CSharp.xml +++ b/redist/redist-server-publicized/Assembly-CSharp.xml @@ -4,3463 +4,3344 @@ Assembly-CSharp - + - Helper for drawing label outline/shadow so that we can easily change it. + After the key "limit" is loaded we stop reading. - + - Helper for drawing label outline/shadow so that we can easily change it. + If the type name has been redirected this method will be called recursively until the most recent name is found and returned. - + - If true, SizeOffset_X and SizeOffset_Y are used when image is available. - Defaults to false. + Path to the folder which contains the Unity player executable. - + - If useImageDimensions is on and image width exceeds this value, scale down - respecting aspect ratio. + Legacy implementation of foliage storage, with one file per tile. - - - If useImageDimensions is on and image height exceeds this value, scale down - respecting aspect ratio. - + + Should angle limits and subtractive volumes be respected? Disabled when manually placing individually. + If true, trees do a sphere overlap to prevent placement inside objects. - + - If true, NVGs work in third-person, not just first-person. - Defaults to false. + Pick a point inside the bounds to test for foliage placement. The base implementation is completely random, but a blue noise implementation could be very nice. - + - Type the annotated class was generated for. + Does this tile contain any placed foliage? - + - Method the annotated method was generated for. + Settings configured when starting the bake. - + - Exposes the same API as the older Block class used by existing netcode, but implemented using new bit reader/writer. + Implementation of tile data storage. - + - Last realtime a request was sent. - Used to rate-limit clientside. + Nelson 2025-04-22: instanced foliage rendering is a decent chunk of CPU time. In retrospect this seems like + an obvious optimization: Graphics.DrawMeshInstanced accepts up to 1023* instances per call. Each tile + groups instances in lists of up to 1023*, but often isn't that high. Now, we collect instances until we + hit the 1023* limit. This is particularly useful for sparse variants like colored flowers. + With a consistent camera transform ("/copycameratransform") on an upcoming map remaster I went from between + 0.72-0.8 ms on my PC to 0.55-0.6 ms! + *Nelson 2025-07-14: refer to NON_UNIFORM_SCALE_INSTANCES_PER_BATCH. - + - Perform rate limiting and update timestamp. + 2022-04-26: drawTiles previously looped over a square [-N, +N] from the upper-left to the bottom-right, + and each tile checked radial distance. We can improve over this by pre-computing the radial offsets and + starting from the center to improve responsiveness. N is [1, 5] - True if we can proceed with request. - + + - Do we think the local player is eligible to send request? + Nelson 2025-07-14: although Graphics.DrawMeshInstanced accepts 1023 instances, it will split them into max + batches of [1, 511, 511] if shader does not have: #pragma instancing_options assumeuniformscaling + So, we might as well do our own splitting of batches to avoid batches of 1. - - - Exposed for Rocket transition to modules backwards compatibility. - + + Must be within [0, MAX_MATRICES_PER_BATCH] range. - + - Find difficulty asset (if valid) for navigation bound index. + Version number associated with this particular system instance. - + - Could potentially be reused generically. + Automatically placing foliage onto tiles in editor. - + - When zombie falls outside the map it needs a replacement spawnpoint within the same navmesh area. + 2022-04-26: this used to be environment layer, but "scope focus foliage" can draw outside that render distance + so we now use the sky layer which is visible up to the far clip plane. - + - Find replacement spawnpoint for a zombie and teleport it there. + If true, ResourceAsset's legacy random rotation and scale properties are used. + (As opposed to FoliageInfoAsset properties.) + Defaults to true for backwards compatibility. - + - Kills night-only zombies at dawn. + If true, mesh is not loaded when clutter is turned off in graphics menu. + Defaults to false. - + - Allows Unity events to call in airdrops. + Foliage to use during the Christmas event instead. - + - Used by weather assets. + Foliage to use during the Halloween event instead. - + - Distance inward from edge before intensity reaches 100%. + Get asset ref to replace this one for holiday, invalid to disable, or null if it should not be redirected. - - - Alpha is 0.0 outside volume and 1.0 inside inner volume. - + + True if other IFoliageSurface methods can be called. - + - Given a point in world space, find the closest point within the total volume in world space. + Replacement foliage storage with all tiles in a single file. + + In the level editor all tiles are loaded into memory, whereas during gameplay the relevant tiles + are loaded as-needed by a worker thread. - + - World space size of the box. + Entry point for worker thread loop. - + - Half the world space size of the box. + Order is important because TileBecameRelevant is called from the closest tile outward. - + - World space size of inner falloff box when falloffDistance is non-zero. - For example a 24x12x6 box with a falloff of 4 has an inner box sized 16x4x0. + Offsets into blob for per-tile data. - + - World space extents of inner falloff box when falloffDistance is non-zero. + Tiles save an index into this list rather than guid. - + - Local space size of inner falloff box when falloffDistance is non-zero. + Offset from header data. - + - Local space extents of inner falloff box when falloffDistance is non-zero. + Data-only FoliageInstanceList shared between threads. - + - World space radius of the sphere. + Data-only FoliageTile shared between threads. - + - Local space radius of the sphere. + Ready to be released to the worker thread during the next lock. - + - World space radius of inner falloff sphere when falloffDistance is non-zero. + Mutex lock. Only used in the main thread Update loop and worker thread loop. - + - Local space radius of inner falloff sphere when falloffDistance is non-zero. + SHARED BY BOTH THREADS! + Coordinates requested by main thread for worker thread to read. + This is a list because while main thread is busy the worker thread can continue reading. - + - Useful for code which previously depended on creating the Unity collider to calculate bounding box. + SHARED BY BOTH THREADS! + Tiles read by worker thread ready to be copied into actual foliage tiles on main thread. - + - Called in the level editor during registraion and when visibility is changed. + SHARED BY BOTH THREADS! + Main thread has finished using this tile data and it can be released back to the pool on the worker thread. + This is a list because main thread could have populated multiple foliage tiles while the worker thread was busy reading. - + - Editor-only solid/opaque child mesh renderer object. + Lifecycle: + 1. Worker thread claims or allocates data. + 2. Worker thread passes data to main thread. + 3. Main thread copies data over to actual foliage tile. + 4. Main thread passes data back to worker thread. + 5. Worker thread releases data back to pool. - + - If true during Awake the collider component will be added. - Otherwise only in the level editor. Some volume types like water use the collider in gameplay, - whereas most only need the collider for general-purpose selection in the level editor. + Responsible for reading and writing persistent foliage data. - + - Camera does not rotate when the car rotates. + Called after creating instance for level, prior to any loading. + Not called when creating the auto-upgrade instance for editorSaveAllTiles. - + - Camera rotates when the car rotates. + Called prior to destroying instance. - + - If hit from the left view rolls right, if hit from the right view rolls left. This may reduce motion - sickness for some players. + Called when tile wants to be drawn. - + - Rotate on all axes according to damage direction. This may induce motion sickness. + Called when tile no longer wants to be drawn. - + - Unfortunately the version which added hitmarker style saved but didn't actually load (sigh). + Called during Unity's Update loop. - + - Nelson 2023-12-28: this option was causing players to crash in the 3.23.14.0 update. Hopefully - it's resolved for the patch, but to be safe it will default to false. + Load known tiles during level load. - + - Prior to 3.22.8.0 all scopes/optics had a base fov of 90 degrees. + Save tiles during level save. - + - If false, call Start and Stop recording before and after push-to-talk key is pressed. This was the - original default behavior, but causes a hitch for some players. As a workaround we can always keep - the microphone rolling and only send data when the push-to-talk key is held. (public issue #4248) + Nelson 2024-11-11: Collider may have been destroyed by an unexpected mod script configuration (or perhaps + simply missing in the first place). Should fix/prevent public issue #4749. - + - If true, group member name labels fade out when near the center of the screen. - Defaults to true. + Called when we position, rotate or scale this transform. - - - If true, hide identifiable details of other multiplayer clients like avatars, player names, number of - players online, server name, etc. Live streamers may find this useful to help prevent stream sniping. - - Separated from the older "streamer mode" option. - - - - - If true, don't share details like "editing map X" or "join" with Steam. Useful for anyone who might be - targeted / followed into servers, or who has a project to keep secret. - - Separated from the older "streamer mode" option. - + + Identical to this object. - + - Controls whether hitmarkers are animated outward (newer) or just a static image ("classic"). + Save the state of all the fields and properties on this object to the current transaction group so that they can be checked for changes once the transaction has ended. - + - Determines how camera follows vehicle in third-person view. + Open a new transaction group which stores multiple undo/redoable actions, for example this would be called before moving an object. - + - Determines how camera follows aircraft vehicle in third-person view. + Close the pending transaction and finalize any change checks. - + - [0, 1] Blend factor between black and flashbang's desired color. + Clear the undo/redo queues. - + - [0, 1] Multiplier for shake from . + If false this transaction is ignored. If there were no changes at all in the group it's discarded. - + - Controls whether camera is constrained to roll-only or all axes. + Called when history buffer is too long so this transaction is discarded. - + - Multiplier for flinch away from damage source in . + Directly blend current value toward target value. - + - [0, 1] Intensity of FOV boost while sprinting. + Only blend current value toward target value if current is greater than target. - + - [0, 1] Intensity of first-person motion caused by walking. + Only blend current value toward target value if current is less than target. - + - Invoked when custom UI colors are set. + If true, write to LevelHierarchy file. + False for externally managed objects like legacy lighting WaterVolume. - + - Invoked when dark/light theme is set. + If true, editor tools can select and transform. + False for items like the object-owned culling volumes. - + - Number of times the player has clicked "Proceed" in the online safety menu. + Hacked to check horizontal distance. - + - If true, "don't show again" is checked in the online safety menu. + Volume doesn't override fog. - + - Prevents menu from being shown twice without a restart. + Volume fog settings are the same at all times of day. - + - Nelson 2025-02-24: Warning that this is invoked *before* the item is actually removed from the items list. - (public issue #4894) + Volume fog settings vary throughout the day. - - checks whether a space contains any filled slots - - - checks whether an item can be dragged and takes into account if the item overlaps its old self - - + - checks whether the spot currently used by the old item is big enough to fit the new item + Kept because lots of modders have been using this script in Unity, + so removing legacy effect id would break their content. - + - Please use SearchContents instead! To perform an equivalent search: - • Set ItemType to type. - • Set IncludeEmpty to false. - • Set IncludeMaxQuality to true. + If per-weather mask AND is non zero the weather will blend in. - + - Please use SearchContents instead! To perform an equivalent search: - • Set ItemType to type. - • Set IncludeEmpty to false. - • Set IncludeMaxQuality to true. - • Set CaliberId to caliber. - • Set IncludeUnspecifiedCaliber to allowZeroCaliber. + Kept for backwards compatibility with fog volumes created in Unity / by mods. - + - Please use SearchContents instead! To perform an equivalent search: - • Set AssetRef to id. - • Set IncludeEmpty to findEmpty. - • Set IncludeMaxQuality to findHealthy. + Distinguishes from zero falloff which may be useful deep in a cave. - + - Please use SearchContents instead! To perform an equivalent search: - • Set MaxResultsCount to 1. - • Set AssetRef to id. - • Set IncludeEmpty to false. - • Set IncludeMaxQuality to true. + Higher priority volumes override lower priority volumes. - + - Invoked after any player's experience value changes (not including loading). + When falloff is OFF, how long to fade in audio by time. - + - Invoked after any player's reputation value changes (not including loading). + When falloff is OFF, how long to fade out audio by time. - + - Ugly hack for the awful skills enums. Eventually skills should be replaced. + When falloff is OFF, how long to fade in audio by time. - + - Set every level to max and replicate. + When falloff is OFF, how long to fade out audio by time. - + - Serverside only. - Called when skills weren't loaded (no save, or in arena mode), as well as when reseting skills after death. + When falloff is OFF, how long to fade in lighting by time. - + - Set this item as the dragging preview. + When falloff is OFF, how long to fade out lighting by time. - + - Standard shader mode changes are based on built-in StandardShaderGUI.cs + Used by lighting to get the currently active effect. - + - Does shader name match any of the standard shaders? - Standard, StandardSpecular and the Unturned "Decalable" variants all share nearly identical parameters. + Hold onto collider and gameobject separately because collider isn't necessarily attached to gameobject. - + - Based on fixup routine in StandardShaderGUI SetMaterialKeywords. + Nelson 2024-06-10: Changed this from guid to string because Unity serialization doesn't support guids + and neither does the inspector. (e.g., couldn't duplicate reward volume without re-assigning guid) - + - Conditionally fixup older standard materials. + If true, vehicles overlapping volume will check conditions and (if met) grant rewards to passengers. - True if material was edited. - + - Parses mb:X from input string and filters assets using X master bundle. + Devkit objects are now converted to regular objects and excluded from the file when re-saving. - + - List of all loaded blueprints potentially craftable by player. Updated when assets are refreshed. This - allows us to skip blueprints that will never be craftable (such as level-specific blueprints). + Kept because lots of modders have been using this script in Unity, + so removing legacy effect id would break their content. - + - Recycled list of assets with blueprints. + For use with PoolablePool when no special construction is required. - + - Subset of loadedBlueprints. + Called when this instance is getting claimed. - + - Center column. + Called when this instance is returned to the pool. - + - Used by inventory item context menu to override which blueprints are shown. + Equivalent to MonoBehaviour.Update - + - Left-hand column. + Equivalent to MonoBehaviour.FixedUpdate - + - Right-hand column. + Useful when caller is not a MonoBehaviour, or coroutine should not be owned by a component which might get + deactivated. For example attached effects destroy timer should happen regardless of parent deactivation. - + - Returns true if all filtered blueprints are craftable. (hacked-in for item action menu) + Stop a coroutine started by InvokeAfterDelay. - + - If asset mapping has changed, find all assets with blueprints and gather the ones that can ever be crafted - on this level. (I.e., excluding ones that we shouldn't waste time considering.) + Number of items in underlying queue. - + - Accessible for UseableHousingPlanner. + Pool of objects that implement the IPoolable interface. + + Useful for types that do not need special construction, + and want notification when claimed and released. - + - Get a blank status from the pool or construct a new one. + Not necessarily cheap to calculate - probably best to cache. - + - Barricade asset's EBuild included in saves to fix state length problems. (public issue #3725) + Internal cubic meter volume. - + - Exposed for Rocket transition to modules backwards compatibility. + Surface square meters area. - + - Exposed for Rocket transition to modules backwards compatibility. + True is solid and false is empty. - + - Writable list of vehicle regions. Public add/remove methods should not be necessary. + Marked true when level editor or legacy hole volumes modify hole data. + Defaults to false in which case holes do not need to be saved. + + Initially this was not going to be marked by hole volumes because they can re-generate the holes, but saving + hole volume cuts is helpful when upgrading to remove hole volumes from a map. - + - Remove barricade instance on server and client. + If true, SetHeightsDelayLOD was called without calling SyncHeightmap yet. - + - Used by ownership change and damaged event to tell relevant clients the new health. + If true, SetHolesDelayLOD was called without calling SyncTexture yet. - + - Legacy function for UseableBarricade. + Heightmap-only data used in level editor. Refer to Landscape.DisableHoleColliders for explanation. - + - Common code between dropping barricade onto vehicle or into world. + Call this when done changing material references to grab their textures and pass them to the terrain renderer. - + - Spawn a new barricade attached to a vehicle and replicate it. + Hacky workaround for height and material brushes in editor. As far as I can tell in Unity 2019 LTS there is no method to ignore + holes when raycasting against terrain (e.g. when painting holes), so we use a duplicate TerrainData without holes in the editor. - + - Spawn a new barricade and replicate it. + Is point (on XZ plane) inside a masked-out pixel? - + + If the highest weight layer is ignoreLayer then the next highest will be returned. + + + If the highest weight layer is ignoreLayer then the next highest will be returned. + + - Not an instance method because structure might not exist yet, in which case we cancel instantiation. + Appends heightmap vertices to points list. - + - Destroy barricades whose pivots are within sphere. + Appends heightmap vertices to points list. - + - Clean up before loading vehicles. + Call this after you're done adding new tiles. - + - Register a new vehicle as a valid parent for barricades. - Each train car is registered after the root of the train. - Note: Nobody knows why these are called plants. + Call this to sync a new tile up with nearby tiles. - + - Called before destroying a vehicle GameObject because storage needed to be ManualDestroyed. + Capturing ortho view of map, so we raise the terrain to max quality. - + - Send all vehicle-mounted barricades to client. - Called after sending vehicles so all plant indexes will be valid. + Finished capturing ortho view of map, so we restore the terrain to preferred quality. - + - Original server-only version that does not replicate changes to clients. + Nelson 2025-03-10: I want to experiment whether this fixes a strange terrain hole painting bug (public issue + #4851) without potentially introducing crashes for other players. (Per an earlier, undated comment we'd + run into a SetHolesDelayLOD-related crash in 2019 LTS.) - + - Only used by plugins. Replicates state change to clients. + If a heightmap coordinate is out of bounds the tile/heightamp coordinate will be adjusted so that it is in bounds again. - + - Not ideal, but there was a problem because onLevelLoaded was not resetting these after disconnecting. + If a splatmap coordinate is out of bounds the tile/splatmap coordinate will be adjusted so that it is in bounds again. - + - Maps prefab unique id to inactive list. + Called by loading after landscapes (and legacy conversion) have been loaded. - + - Sending yaw only costs 1 bit (flag) plus yaw bits, so compared to the old 24-bit rotation we may as well - make it high-precision. Quaternion mode uses 1+27 bits! + Sorts modules by dependencies. - + - +0 = BarricadeDrop - +1 = root transform - +2 = Interactable (if exists) + Wraps module assembly and handles initialization. - + - ID unique to this zombie table in the level. If this table is deleted the ID will not be recycled. Used to - refer to zombie table from external files, e.g., NPC zombie kills condition. + True when config is enabled and dependencies are enabled. - + - Nelson 2025-08-20: changing this to affect both sentries and safezones. Some modded safezones allow - building but not weapons, so players were using charges to destroy houses. (public issue #5175) + Metadata. - + - Not an actual Steam ID or BattlEye ID, instead this is used to map player references to and from BE. + Assembly files loaded. - + - True for offline or listen server host. + Types in the assemblies of this module. Refer to this for types rather than the assemblies to avoid exception and garbage. - + - Next time method is allowed to be called. + How far along the initialization to shutdown lifecycle this module is. - + - Number of times client has tried to invoke this method while rate-limited. + Nicely formatted version, converted into . - + - Get Steam item definition ID equipped for given vehicle. + Used for module dependencies. - True if a skin was available. - + - Build econ details struct from tags and dynamic_props. - Note that details cannot be modified because it's a struct and has copies of the data. + Holds module configuration. - + - Add a recent ping sample to the average ping window. - Updates ping based on the average of several recent ping samples. + Whether to load assemblies. - Most recent ping value. - - - True if both players exist, are both members of groups, and are both members of the same group. - - - True if both players exist, are both members of groups, and are both members of the same group. - + - Get real IPv4 address of remote player NOT the relay server. + Directory containing Module file, set when loading. - True if address was available, and not flagged as a relay server. - + - See above, returns zero if failed. + Path to the Module file, set when loading. - + - Get real address of remote player NOT a relay server. + Used for module dependencies. - Null if address was unavailable. - + - Get string representation of remote end point. + Nicely formatted version, converted into . - Null if address was unavailable. - + - Players can set a "nickname" which is only shown to the members in their group. + Used for module dependencies. - + - Can be used by plugins to verify player is on a particular server. - - OnSteamAuthTicketForWebApiReceived will be invoked when the response is received. - Note that the client doesn't send anything if the request to Steam fails, so plugins may wish to kick - players if a certain amount of time passes. (e.g., if a cheat is canceling the request) + Modules that must be loaded before this module. - + - Since this isn't accessible to plugins it isn't necessarily up-to-date. For example, when a player - teleports the culledPlayers list isn't updated until the next PlayerManager sync. If this becomes - publicly accessible in some way it should be kept in sync. + Relative file paths of .dlls to load. - + - Component for the tactical laser attachment's red dot. - Resizes itself per-camera to maintain a constant on-screen size. + Requested by Trojaner. LoadFile locks the file while in use which prevents OpenMod from updating itself. - + - Used to tune the scale by distance so that far away laser is not quite as comically large. + ModuleHook looks for module entry/exit points, then calls when enabled and when disabled. - + - This value is confusing because in the level editor it is the normalized radius, but in-game it is the square radius. + Register components of this module. - + - Load {Language}.dat and/or English.dat from folder path. + Cleanup after this module. - + - Note: as of 2025-04-23 this *can* be null. (E.g., audio-only effects.) + Runs before everything else to find and load modules. - + - If set, use OneShotAudioParameters to play this audio. + Temporarily contains Unturned's code untils it's moved into modules. - + - If true the music option is respected when this effect is used by ambiance volume. + Temporarily contains types. - + - In multiplayer the effect will be spawned for players within this radius. + Should module assemblies be loaded? - + - When loaded or spawned as a vehicle, creates a different vehicle instead. - For example, Off_Roader_Orange has ID 4. When that ID is loaded/spawned the new combined Off_Roader vehicle is - used instead. Can also optionally apply a paint color, allowing saves to be converted without losing colors. + Called once after all startup enabled modules are loaded. Not called when modules are initialized due to enabling/disabling. - + - Redirectors are in the Vehicle category so that legacy vehicle IDs point at the redirector. + Called once after all modules are shutdown. Not called when modules are shutdown due to enabling/disabling. - + - Vehicle to use when attempting to load or spawn this asset. + Find modules containing an assembly with the Both_Required role. + Modules to append to. - + - If set, overrides the default random paint color when loading a vehicle from a save file. - Used to preserve colors of vehicles in existing saves. + Find module using dependency name. + - + - If set, overrides the default random paint color when spawning a new vehicle. - Optionally used to preserve colors of vehicles in spawn tables. + These are *.dll files discovered in the modules folder. - + - Invoked prior to built-in death logic. + Should missing DLLs be logged? + Opt-in because RocketMod has its own handler. - + - Event for plugins when player dies. + Should vanilla search for *.dll files? + Can be turned off in case it conflicts with third-party search mechanism. - + - Invoked after player finishes respawning. + If set, search for .dll and .module files in this directory instead of in Unturned/Modules. - + - Tracks this player as an aggressor if they were recently an aggressor or if they haven't been attacked recently. + Event for plugin frameworks (e.g., Rocket) to override AssemblyResolve handling. - Ignores rules and just make aggressive. - Whether to call markAggressive on group members. - - - Should damage be dealt even while inside safezone? - + - Set bleeding state and replicate to owner if changed. + Depending on the platform, assemblies are found in different directories. + Root folder for modules. - + - Set legs broken state and replicate to owner if changed. + Search Modules directory for .dll files and save their AssemblyName to discoveredNameToPath. - + - Add to or subtract from stamina level. - Does not replicate the change. + Search Modules directory for .module files and load them. - + - Add to or subtract from stamina level. - Does not replicate the change. + Orders configs by dependency and removes those that are missing files. - + - Called from the server to modify stamina. + Whether add can be called from the inspector. - + - Add to or subtract from stamina level on the client and server. + Whether remove can be called from the inspector. - + - Called from the server to induce a hallucination. + Called when the inspector adds an element. - + - Add to or subtract from hallucination level on the client. + Called when the inspector removes an element. - + - Add to or subtract from warmth level. - Does not replicate the change. + Called when the inspector sets an element to a different value. - + - Called from the server to modify warmth. + Whether add can be called from the inspector. - + - Add to or subtract from warmth level on the client and server. + Whether remove can be called from the inspector. - + - Add to or subtract from oxygen level. - Does not replicate the change. + Water volume marked as being sea level. - + + Null if under old water level, otherwise the volume. + + - Add to or subtract from health level. - Replicates change to owner. + Find the water elevation underneath point, or above point if underwater. - + - Add to or subtract from food level. - Replicates change to owner. + All water tiles and the planar reflection component reference this material. - + - Add to or subtract from water level. - Replicates change to owner. + If true rain will be occluded below the surface on the Y axis. - + - Add to or subtract from virus level. - Replicates change to owner. + Flag for legacy sea level. - + - Used by plugins to respawn the player bypassing timers. Issue #2701 + Convert world-space point into region coordinates that may be out of bounds. - + - Very similar to VehicleManager.sendExitVehicle. Please refer to that for comments. + Convert world-space position into a region coordinate that may be out-of-bounds. - + - Used to refill all client stats like stamina + Returns true if coord is within legacy range. - + - Used by UI. True when underwater or inside non-breathable oxygen volume. + Clamp position into the maximum bounds expected by the game, not necessarily the level bounds. + True if position was modified. - + - This value is confusing because in the level editor it is the normalized radius, but in-game it is the radius. + Sanity check all returned elements have a gameObject. - + - No longer used in vanilla. Kept in case plugins are using it. + Create software cursor visual element. - + - No longer used in vanilla. Kept in case plugins are using it. + Create green label in the upper-left. - + - No longer used in vanilla. Kept in case plugins are using it. + Create tooltip visual element. - + - Actual internal implementation. + Update upper-left green text. - + - World to local bounds only works well for axis-aligned icons. + Update software cursor visual element. - + - Unity's Camera.orthographicSize is half the height of the viewing volume. Width is calculated from aspect ratio. + Find hovered element and update tooltip visibility/text. - + - Fading in. + Container for SleekWindow element. - + - Finished fading in. + Container for top-level visual elements. - + - Fading out. + Element under the cursor on the previous frame. - + - Finished fading out. + Duration in seconds the cursor has been over the element. - + - Extensions to the built-in Input class. + Distance inward from edge before intensity reaches 100%. - + - Wrapper for Input.GetKey, but returns false while typing in a uGUI text field. + Alpha is 0.0 outside volume and 1.0 inside inner volume. - + - Wrapper for Input.GetKeyDown, but returns false while typing in a uGUI text field. + Given a point in world space, find the closest point within the total volume in world space. - + - Wrapper for Input.GetKeyUp, but returns false while typing in a uGUI text field. + World space size of the box. - - - Should be used anywhere that Input.GetKeyDown opens a UI. - - Each frame one input event can be consumed. This is a hack to prevent multiple UI-related key presses from - interfering during the same frame. Only the first input event proceeds, while the others are ignored. - - True if caller should proceed, false otherwise. - - + - Get mouse position in viewport coordinates where zero is the bottom left and one is the top right. + Half the world space size of the box. - + - If true, clients destroy Throwable prefab upon collision. Defaults to false. - Optional to ensure backwards compatibility for unexpected setups. + World space size of inner falloff box when falloffDistance is non-zero. + For example a 24x12x6 box with a falloff of 4 has an inner box sized 16x4x0. - + - Original type on the Russia map which requires a mask with filters. + World space extents of inner falloff box when falloffDistance is non-zero. - + - Requires a mask with filters and full body suit. + Local space size of inner falloff box when falloffDistance is non-zero. - + - Damage dealt to players while inside the volume if they *don't* have clothing matching the deadzone type. - Could help prevent players from running in and out to grab a few items without dieing. + Local space extents of inner falloff box when falloffDistance is non-zero. - + - Damage dealt to players while inside the volume if they *do* have clothing matching the deadzone type. - For example, an area could be so dangerous that even with protection they take a constant 0.1 DPS. + World space radius of the sphere. - + - Virus damage to players while inside the volume if they *don't* have clothing matching the deadzone type. - Defaults to 6.25 to preserve behavior from before adding this property. + Local space radius of the sphere. - + - Rate of depletion from gasmask filter's quality/durability. - Defaults to 0.4 to preserve behavior from before adding this property. + World space radius of inner falloff sphere when falloffDistance is non-zero. - + - This value is confusing because in the level editor it is the normalized radius, but in-game it is the square radius. + Local space radius of inner falloff sphere when falloffDistance is non-zero. - + - Nelson 2024-06-10: Added this property after nodes were converted to volumes. i.e., only old levels from - before this property were added still have nodes, so it's expected that they won't deal damage over time. + Useful for code which previously depended on creating the Unity collider to calculate bounding box. - + - Same description as . + Called in the level editor during registraion and when visibility is changed. - + - Same description as . + Editor-only solid/opaque child mesh renderer object. - + - Same description as . + If true during Awake the collider component will be added. + Otherwise only in the level editor. Some volume types like water use the collider in gameplay, + whereas most only need the collider for general-purpose selection in the level editor. - + - Get real IPv4 address of remote player NOT the relay server. + Sort servers by name A to Z. - True if address was available, and not flagged as a relay server. - + - See above, returns zero if failed. + Sort servers by name Z to A. - + - When placing structures that snap to grid multiple requests can come - in to the server at the same time, and checking overlaps against structures - can be problematic, so as a backup we track pending build requests - and cancel ones which conflict. + Persistent identifier for server. Relies on server assigning a Game Server Login Token (GSLT). + i.e., servers without GSLT cannot be bookmarked. - + + + IP address or DNS name to use as-is, or a web address to perform GET request. + Servers not using Fake IP can specify just a DNS entry and a static query port. + Servers using Fake IP are assigned random ports at startup, but can implement a web API endpoint to return + the IP and port. + + Nelson 2025-01-20: Making this optional now. The downside is we can't perform a Steam A2S query without + IP/port, but the upside is players can more easily join their non-port-forwarded servers. + + + - Register a location as having something built there soon. + Steam query port. Zero for servers using Fake IP. - Unique handle to later finish the request. - + - Is a location available to build at (i.e. no pending builds)? + Name updated from SteamServerAdvertisement. - False if there are any outstanding build requests for given location. - + - Notify that a previously registered build has been completed. + Short description updated from SteamServerAdvertisement. - Unique handle. - + - Nelson 2023-08-11: this probably should be rewritten a bit if used in the future - because the error context currently assumes this is an item reward for consumables. + Small icon updated from SteamServerAdvertisement. - + - Resolve table as items and grant random number to player. + Used by UI to track whether it's been added/removed. - + - Resolve table as items and grant random number to player. + Allows player to save server advertisement to join again later. Semi-replacement for Steam's built-in favorites + and history lists because as of 2024-04-26 they don't seem to work properly with Fake IP. - + + details if advertisement is bookmarked. + + - Enumerate random number of valid assetIDs. + Restore a removed bookmark. - + - Converts Steam BBcode tokens into widgets displayable using Glazier UI. + Payload for the DamageTool.explode function. + Moved into struct because the amount of arguments to that function were insane, but now is not the time to completely refactor damage. - + - If false, expect LineBreak tokens in input. (default false) - If true, insert line breaks where appropriate. - Steam's new visual editor doesn't emit newlines, instead inferring line breaks from paragraph blocks. To - make life easier we will do the same for the main menu announcement feed. + Speed to launch players away from blast position. - + - Vanilla maximum level. + This value is confusing because in the level editor it is the normalized radius, but in-game it is the square radius. - + - If set, maximum skill level attainable through gameplay. + Please check CurrentlyAllowsBuilding. + Bypassed by LevelAsset's ShouldAllowBuildingInSafezonesInSingleplayer option. - + - Multiplier for XP upgrade cost. + Tools like carjacks and tires can be used in safezone by admins for maintenance. - + - Get maximum level, or maxUnlockableLevel if set. + ID unique to this zombie table in the level. If this table is deleted the ID will not be recycled. Used to + refer to zombie table from external files, e.g., NPC zombie kills condition. - - - + - Implemented by components the player can talk with using DialogeAssets. (e.g., InteractableObjectNPC) + Visualizes reverb zone in-game. - + - Used to test whether player is within range. - Ideally, this should be removed in the future in favor of the server resetting speaker when out of range. + Temporary to unbind events because this class is static for now. (sigh) - + - Get a net ID that can be used with GetDialogueTargetFromNetId to resolve IDialogueTarget in multiplayer. + If true and player has no shirt equipped, use fallback shirt as equipped shirt. + Used by oversize vest and zip-up vest so they are visible without a shirt equipped. - + - Called on server to test whether object conditions are met. + Converts Steam BBcode tokens into widgets displayable using Glazier UI. - + - Called on server to find the start of conversation dialogue asset. + If false, expect LineBreak tokens in input. (default false) + If true, insert line breaks where appropriate. + Steam's new visual editor doesn't emit newlines, instead inferring line breaks from paragraph blocks. To + make life easier we will do the same for the main menu announcement feed. - + - Used in error messages. + Thanks to Glenn Fiedler for this RK4 implementation article: + https://gafferongames.com/post/integration_basics/ - + - Called on client to format in UI. + Higher values return to the target position faster. - + - Helper wrapping Unturned's usage of AudioListener.volume, which is the master volume level. - This makes it easier to track what controls the master volume and avoid bugs. + Higher values reduce bounciness and settle at the target position faster. + e.g. a value of zero will bounce back and forth for a long time (indefinitely?) - + - Is audio muted because this is a dedicated server? - - While dedicated server should not even be processing audio code, - older versions of Unity in particular have issues with headless audio. + Seamlessly teleports player to an equivalent position at the destination upon contact. - + - Is audio muted because loading screen is visible? + Target position and rotation. - + - Player's volume multiplier from the options menu. + Only used in the Unity editor for visualization. - + - Player's unfocused volume multiplier from the options menu. + Steam currency codes seem to be ISO 4217, however the documentation (as of 2021-01-29) does not say so. - + - Mute or un-mute audio depending whether camera is valid. + If overlay is disabled there is no point showing the in-game item store because the player will not be able + to checkout. We request listings regardless in order to show the "sale" label automatically. - + - Synchronize AudioListener.volume with Unturned's parameters. + Initially these were structs so that they would be adjacent in memory and therefore faster to iterate lots of them, + but making them classes lets them reference each other which significantly simplifies finding adjactent housing parts. - - - Note: new official code should be using per-method rate limit attribute. - This is kept for backwards compatibility with plugins however. - - Timestamp for server-side rate limiting. - - - + - Realtime this action was performed. + Item along positive direction. + Can be multiple on existing saves or if players found an exploit. - + - Realtime since performedRealtime. + Item along negative direction. + Can be multiple on existing saves or if players found an exploit. - + - if(myRateLimit.throttle(1.0)) - return; // less than 1s passed + Item between floors. + Can be multiple on existing saves or if players found an exploit. - + - Exposed for Rocket transition to modules backwards compatibility. + Is there a wall in this slot, and is it full height (not rampart)? - + + + This check prevents placing roof onto the upper edge of a rampart because ramparts + create an edge at full wall height even though they are short. + + Ideally in the future wall height will become configurable and remove + the need for this check. + + See public issue #3590. + + + - List of all interactable items. Originally only used to clamp their distance from the drop point to ensure - clients can always pick them up, but now used to find items within a radius for nearby menu as well. + Position at the base of the pillar. - + - Kept for plugin backwards compatibility. - This one is problematic because on the client physics can move items between regions. + Yaw if placing pillar at this vertex. - + - Find physically simulated items within radius. + Pillar or post currently occupying this slot. + Can be multiple on existing saves or if players found an exploit. - + - Despawn any old items in the current despawn region. + Can be zero if pillar is floating, or up to six in the center of a triangular circle. - True if the region had items to search through. - + - Attempt to respawn an item in the current respawn region. + Is there a pillar in this slot, and is it full height (not post)? - True if an item was succesfully respawned. - + - Not ideal, but there was a problem because onLevelLoaded was not resetting these after disconnecting. + Floors must be placed touching the terrain, or a fake-terrain object like a grassy cliff model. - + - Instantiate at least this many items per frame even if we exceed our time budget. + Pillars can be partly underground or inside a designated allowed underground area. Otherwise, + if the very top of the pillar is underground placement is blocked. (public issue #4250) - + - Sort servers by name A to Z. + Side length of square and triangular floor/roof. + Walls can be slightly less, but we treat them as if they are the full length. - + - Sort servers by name Z to A. + Vertical distance from edge center to wall pivot. - + - Persistent identifier for server. Relies on server assigning a Game Server Login Token (GSLT). - i.e., servers without GSLT cannot be bookmarked. + Vertical distance from edge center to rampart pivot. - - - IP address or DNS name to use as-is, or a web address to perform GET request. - Servers not using Fake IP can specify just a DNS entry and a static query port. - Servers using Fake IP are assigned random ports at startup, but can implement a web API endpoint to return - the IP and port. - - Nelson 2025-01-20: Making this optional now. The downside is we can't perform a Steam A2S query without - IP/port, but the upside is players can more easily join their non-port-forwarded servers. - - - + - Steam query port. Zero for servers using Fake IP. + If position is nearly equal within this threshold then edges/vertices will connect. - + - Name updated from SteamServerAdvertisement. + Maximum distance from player's viewpoint to allow placement. - + - Short description updated from SteamServerAdvertisement. + How far to search for empty slot best match. - + - Small icon updated from SteamServerAdvertisement. + Cosine of the angle between ray direction and direction toward slot must be greater than this. - + - Used by UI to track whether it's been added/removed. + When validating item placement expand physics overlap this much. + Useful to ensure slightly-touching overlaps (e.g. pillar touching the pillar above) are handled properly. - + - Allows player to save server advertisement to join again later. Semi-replacement for Steam's built-in favorites - and history lists because as of 2024-04-26 they don't seem to work properly with Fake IP. + Ensure players, vehicles, zombies, animals, etc are not within this distance of pending placement. - - details if advertisement is bookmarked. - - + - Restore a removed bookmark. + Distance from triangle pivot to apex of triangle. - + - Static functions for creating monitor instance on server. + Radius of circle within triangle edges. - + - Entry point called by dedicated server after loading level. + Distance from triangle pivot to center of triangle. - + - Create vanilla update monitor that watches for changes to workshop level file and any other mods. + Small threshold to allow placing even with existing barricades on the floor. - + - Helper to get updated timestamp from workshop items loaded by DedicatedUGC. + House overlap is approximately the same size as the housing item's collider(s), and is intended to check whether + any pre-existing barricades or structural items are in the way. For example whether a wall cannot be placed because + there is a storage crate in the way, or if a foundation is blocked by another slightly rotated foundation. - + - Helper to create monitored item for use with default DedicatedWorkshopUpdateMonitor implementation. + Character overlap is slightly larger than the house overlap, and checks whether any players, vehicles, animals, zombies, etc + are nearby. This is necessary because when house and characters were combined in a single physics query it was possible to + stand *just* close enough to step into the collider as it was spawned. - + - For use with default DedicatedWorkshopUpdateMonitor implementation. + Called when a housing item is spawned or after moving an existing item. - + - Get index within bounds assuming list is not empty. + Called before a housing item is destroyed or before moving a housing item. - + - Add a new item using its default constructor. + Search grid for existing vertex at approximately equal position. + Considers adjacent grid cells if near cell boundary to avoid issues with floating point inaccuracy. - + - Apply shader name redirects until a final name is found, - and then load shader for compatible version of Unity. + Search grid for existing edge at approximately equal position. + Considers adjacent grid cells if near cell boundary to avoid issues with floating point inaccuracy. - + - Apply shader name redirects until a final name is found. - Used to fix renamed shaders loaded from old asset bundles. + Find existing edge and add connection, or add new empty edge. - + - Names of older shaders mapped to their renamed counterparts. - Used to fix shaders loaded from old asset bundles. + Find existing vertex and add connection, or add new empty vertex. - + - Delete all savedata folders for player's characters. + Find existing edge and set associated wall, or add an empty edge at wall's location. - + - Number of Attack_# animations. + Find slot occupied by wall and remove if no longer attached to anything. - + - Number of Eat_# animations. + Find existing vertex and set associated pillar, or add an empty vertex at pillar's location. - + - Number of Glance_# animations. + Find slot occupied by pillar and remove if no longer attached to anything. - + - Number of Startle_# animations. + Hack to prevent ignoring floor which might be overlapping pending floor placement. + For example when placing a square floor on the opposite edge of a spot which has a triangular floor + we do not want to ignore the triangular floor during the physics query. - + - Maximum distance on the XZ plane. + Used by triangular floor and roof validation to test for collisions. - + - Maximum distance on the XZ plane when attacking vehicles. + Ensure wall fits in an empty slot. - + - Maximum distance on the Y axis. + Ensure pillar fits in an empty slot. - + - Minimum seconds between attacks. + Nelson 2024-06-26: With structure rotation replicated as a quaternion we need to be smarter about extracting + yaw from model transform. Quaternion.eulerAngles.y isn't necessarily the yaw anymore. - + - Temporary until something better makes sense? For Spyjack. + Working buffer for placement overlap tests. - + - If true, animal won't start moving until startle animation finishes. + Sorts higher rarity items into the front of the list. - + - Allows mappers to bulk replace assets by listing pairs in a text file. - https://github.com/SmartlyDressedGames/Unturned-3.x-Community/issues/2275 + Plugin-only event when throwable is spawned on server. - + - If a redirector for oldGuid exists, returns target asset. Otherwise null. + Allows Unity events to spawn items. - + - Component in the root Menu scene. - Additively loads decoration levels without modifying main scene. + Used to aid backwards compatibility as much as possible when transitioning Unity versions breaks asset bundles. - + - Prevents static member from being initialized during MonoBehaviour construction. (Unity warning) + Unity 5.5 and earlier per-asset .unity3d file. - + - Nelson 2024-02-06: when looking into resolving public issue #3703 I figured since there is a common behavior - between InteractableObjectQuest, InteractableObjectNote, and InteractableObjectDropper (in that they all - request the server to do X we may as well support a "mod hook" that works with all three. + When "master bundles" were first introduced in order to convert older Unity 5.5 asset bundles in bulk. - + - Controls where attachments looks for ADS alignment transform. + Unity 2018 needed a new version number in order to convert materials from 2017 LTS asset bundles. 2019 did not need a + new version number, but in retrospect it seems unfortunate that we cannot distinguish them, so 2020 does have its own. - + - Look for aim alignment transform relative to sight model. - Defaults to Model_0/Aim. + 2022 LTS+ - + - Look for aim alignment transform relative to equipable prefab. - Requires setting AimAlignment_Path. + The first time asset loading finishes it will load the main menu. - + - Factor e.g. 2 is a 2x multiplier. - Prior to 2022-04-11 this was the target field of view. (90/fov) + If true, either loading during initial startup or full refresh. - + - Zoom factor used in third-person view. + If true, currently searching locations added after initial startup loading. - + - Whether main camera field of view should zoom without scope camera / scope overlay. + Has initial client UGC loading step run yet? + Used to defer asset loading for workshop installs that occured during startup. - + - If true, scale scope overly by 1 texel to keep "middle" pixel centered. + Has initial map loading step run yet? + Used to defer map loading for workshop installs that occured during startup. - + - Controls where to find AimAlignmentTransformPath. + Calling this "legacy" is a bit of a stretch because even most of the vanilla assets are + built around the 16-bit IDs. Ideally no new code should be relying on 16-bit IDs however. - + - If set, find this transform relative to AimAlignmentTransformOwner. + Incremented when assets are added or removed. + Used by boombox UI to only refresh songs list if assets have changed. - + - Position offset relative to Aim transform or transform specified by aimAlignmentTransformPath. + In singleplayer and the level editor this is the same as defaultAssetMapping, + but when playing on a server a subset of assets based on the server's workshop files is used. - + - [0, 1] local distance from center to start of line. + Should folders be scanned for and load .dat and asset bundle files? + Plugin developers find it useful to quickly launch the server. - + - [0, 1] local width of horizontal line. + Do we want to enable shouldDeferLoadingAssets? - + - Whether line/number are on left or right side of the center line. + Should extra validation be performed on assets as they load? + Useful for developing, but it does slow down loading. - + - If true, text label for distance is visible. + Should asset file metadata such as line numbers and comments be parsed? + Useful for development (e.g., error messages), but may slow down loading and increases RAM usage. - + - Optional component on Turret_# GameObject for modding UnityEvents. + Should asset files be re-saved after all loading is finished? + Requires asset metadata. Useful for automatically upgrading .dat/.asset files. - + - Optional collider matching the player capsule to prevent short vehicles (e.g. bikes) from clipping into walls. + Should some specific asset types which opt-in be allowed to defer loading from asset bundles until used? + Disabled by asset validation because all assets need to be loaded. - + - Displays a single random item. Placed under the other main menu buttons. + Should workshop asset names and IDs be logged while loading? + Useful when debugging unknown workshop content. - + - Hide existing icon until refresh. - Experimented with doing this for every refresh, but it looks bad in particular for hotbar. + Should a JSON report of all the game's assets be exported? - + - Name of the asset bundle. + Should GC and clear unused assets be called after every loading frame? + Potentially useful for players running out of RAM, refer to: + https://github.com/SmartlyDressedGames/Unturned-3.x-Community/issues/1352#issuecomment-751138105 - core.content - + - Path within the asset bundle. + Should modded spawn tables being inserted into parents be logged? + Useful for debugging workshop spawn table problems. - + - Used to test whether player can fit in a space. - Includes terrain because tested capsule could be slightly underground, and clip to prevent exploits at sky limit. + Loaded master bundles. - + - Used for third-person camera in vehicle. - Does not include resource layer because attached barricades are put on that layer. - Barricades layer itself is included to prevent looking inside player bases. + Loading master bundles. - + - Used to test whether player can enter a vehicle. - Does not include resource layer because attached barricades are put on that layer. + Master bundle from root /Bundles directory containing vanilla assets. - + - 2023-02-02: adding more layers since splatter can be attached to them now. - parent should only be set if that system also calls ClearAttachments, otherwise attachedEffects will leak memory. + While an asset is being loaded, this is the master bundle for that asset. + Used by master bundle pointer as a default. - + - Layer mask for CharacterController overlap test. + While an asset is being loaded, this is the asset. + Used by some error logging. + Note: not ideal because any global state like this prevents parallelization. - + - Layer mask for CharacterController overlap test while inside landscape hole volume. + This method supports . - + - Lightning strike raycasts from sky to ground using this layer mask. + Find an asset by GUID reference. + This method supports . + Asset with matching GUID if it exists, null otherwise. - + - Invoked when component is enabled and when the game object is activated. + Find an asset by GUID reference. + This method supports . + Maybe considered a hack? Ignores the current per-server asset mapping. + Asset with matching GUID if it exists, null otherwise. - + - Invoked when component is disabled and when the game object is deactivated. - Note that if the component or game object spawn deactivated this will not be immediately invoked. + Find an asset by GUID reference. + This method supports . + Maybe considered a hack? Ignores the current per-server asset mapping. + Asset with matching GUID if it exists, null otherwise. - + - Allows Unity events to print messages to the log file for debugging. + Load content from an assetbundle. - + - Text to use when PrintInfo is invoked. + Find an asset by GUID reference. + This method supports . + Asset with matching GUID if it exists, null otherwise. - + - Every time the inventory changes this number is incremented. - While a little messy, the idea is to prevent inventory checks from happening every frame. + Find an asset by GUID reference. + This method supports . + Asset with matching GUID if it exists, null otherwise. - + - Should be called every time something changes in the inventory. + This method supports . - + - Helper to prevent checking the inventory every frame for systems that don't use events. + This method supports . - + - Did owner call askInventory yet? - Prevents duplicate tell_X RPCs from being sent to owner prior to initial sync. - Ideally should be cleaned up with netcode refactor. (Client should not need to ask server for initial state.) + This method supports . + Note: this method doesn't handle redirects by VehicleRedirectorAsset. - + - Intended as nearly a drop-in replacement for . + This method supports . + Note: this method doesn't handle redirects by VehicleRedirectorAsset. - + - Intended as nearly a drop-in replacement for . + This method supports . - + - Intended as nearly a drop-in replacement for . + This method supports . - + - Intended as nearly a drop-in replacement for . + Useful if GUID can reference a different asset type than legacy ID. For example, gun magazine GUID can + reference a SpawnAsset while its legacy ID cannot. + This method supports . - + - Intended as nearly a drop-in replacement for . + Append assets that extend from result type. - + - Intended as nearly a drop-in replacement for . - This variant wraps FindFirstItemByAsset and manages the results list for you. - Only use result if true is returned, otherwise it's invalid. + Maybe considered a hack? Ignores the current per-server asset mapping. + Append assets that extend from result type. - + + + While playing on server the client will use the same dictionary/list of assets the server uses in order + to reduce issues with ID conflicts. + + 2023-05-27: server now ALSO uses the same logic to ensure IDs are applied in consistent order regardless + of multi-threaded loading order. + + + - Intended as nearly a drop-in replacement for . - This variant wraps FindFirstItemByAsset and manages the results list for you. + Search all loaded master bundles for one in path's hierarchy. - + - Helper for tryAddItemAuto. + Find loaded master bundle by name. - + - Given an item coordinate (page, x, y) could a new item take the place of an old (existing) item without - overlapping other item(s) space? Always true for equipment slots (page less than SLOTS). - For example if oldSize is (1, 2) rot 0, and newSize is (2, 1) rot 1, then they can swap. + Unload all asset bundles from memory, and empty known list. + Called when reloading assets. - + - Swap coordinates of two existing items. - Rotation is provided to handle differently shaped items e.g. a 1x2 item with a 2x1 item. + Catches exceptions thrown by LoadFile to avoid breaking loading. - + - Swap coordinates of two existing items. - Rotation is provided to handle differently shaped items e.g. a 1x2 item with a 2x1 item. + Called when a new workshop item is installed either on client or server. - + - Called from player movement to close storage that has moved away. + Reload assets in given folder. - + - Serverside open a storage crate and notify client. + Do we have any new spawn assets that have not been linked yet? + Used to skip linking spawns if not required when downloading assets. - + - Serverside grant access to car trunk storage and notify client. + Can now be safely called multiple times on client in order to handle spawns for downloaded maps. + Spawn tables have "roots" which allow mods to insert custom spawns into the vanilla spawn tables. + This method is used after workshop assets are loaded on client, or after the dedicated server is done downloading workshop content. - + - Serverside revoke trunk access and notify client. + Look through all item blueprints and log errors if there are duplicates. - + - Called on both client and server, as well as by storage itself when destroyed. + Look through all dialogue and check that their referenced + dialogueID or vendorID is an actual loaded asset. - + - Please use SearchContents instead! To perform an equivalent search: - • Set IncludeEquipmentSlots to false. - • Set IncludeActiveStorageContainer to false. - • Set ItemType to type. - • Set IncludeEmpty to false. - • Set IncludeMaxQuality to true. - OR use the nearly drop-in replacement FindItemsByType. + Manually run asset unload and garbage collection in the hope + that it will minimize RAM allocated during loading. - + - Please use SearchContents instead! To perform an equivalent search: - • Set IncludeEquipmentSlots to false. - • Set IncludeActiveStorageContainer to false. - • Set ItemType to type. - • Set IncludeEmpty to false. - • Set IncludeMaxQuality to true. - • Set AnyCaliberIds to calibers. - • Set IncludeUnspecifiedCaliber to allowZeroCaliber. - OR use the nearly drop-in replacement FindAttachmentsByCaliber. + Helper for Assets.init. + Load all non-map assets from: + /Bundles/Workshop/Content + /Servers/ServerID/Workshop/Content + /Servers/ServerID/Bundles - + - Please use SearchContents instead! To perform an equivalent search: - • Set IncludeEquipmentSlots to false. - • Set IncludeActiveStorageContainer to false. - • Set ItemType to type. - • Set IncludeEmpty to false. - • Set IncludeMaxQuality to true. - • Set CaliberId to caliber. - • Set IncludeUnspecifiedCaliber to allowZeroCaliber. - OR use the nearly drop-in replacement FindAttachmentsByCaliber. + Helper for Assets.init. + Load all non-map assets from subscribed UGC. - + - Please use SearchContents instead! To perform an equivalent search: - • Set IncludeEquipmentSlots to false. - • Set IncludeActiveStorageContainer to false. - • Set AssetRef to id. - • Set IncludeEmpty to findEmpty. - • Set IncludeMaxQuality to findHealthy. - OR use the nearly drop-in replacement FindItemsByAsset. + Helper for modders creating workshop content. + Loads folders in the "Sandbox" directory the same way workshop files are loaded. - + - Please use SearchContents instead! To perform an equivalent search: - • Set IncludeEquipmentSlots to true. - • Set IncludeActiveStorageContainer to true. - • Set MaxResultsCount to 1. - • Set AssetRef to id. - • Set IncludeEmpty to false. - • Set IncludeMaxQuality to true. - OR use the nearly drop-in replacements FindFirstItemByAsset or HasItemByAsset. + Helper for Assets.init. + Load all assets in each map's Bundles folder, and content in map's Content folder. - + - Filter for whether the Permanent Gold Upgrade DLC is required to join a server. + Not the tidiest place for this, but it allows startup to pause and show error message. + Occasionally there have been reports of the steamclient redist files being out of date on the dedicated + server causing problems. For example: https://github.com/SmartlyDressedGames/Unturned-3.x-Community/issues/2866#issuecomment-965945985 - + - All servers pass the filter. + Null token. - + - Only non-gold servers pass the filter. + Text between tags. - + - Only gold servers pass the filter. + [b] - + - Can be added to any GameObject to listen for the Event NPC reward type. + [/b] - + - *_ID configured in NPC rewards list. + [i] - + - If true the event will only be invoked in offline mode and on the server. + [/i] - + - Invoked when NPC global event matching EventId is processed. + [list] - + - Invoked when timer expires. + [/list] - + - Number of seconds to use when SetDefaultTimer is invoked. + [olist] - + - Should timer loop when SetDefaultTimer is invoked? + [/olist] - + - Stop pending timer from triggering. + [*] value + Nelson 2025-07-02: manually written lists typically don't have a ListItemClose token. - + - Handle to stop the coroutine. + [/*] + Nelson 2025-07-02: Steam's new visual editor adds closing tokens to list items, but + manually-written list items typically don't have them. - + - Horizontal distance before road begins tapering off into the terrain. + [h1] - + - Size along the "up" axis. + [/h1] - + - Distance along the terrain surface normal to move each road vertex. + [h2] - + - Multiplier for how far along the road before texture repeats. + [/h2] - + - Defaults to None, in which case the backwards-compatible chart classification is used. + [h3] - + - Physics material to assign to road colliders. - Replaces the "concrete" toggle in the older editor. + [/h3] - + - Can be added to Vehicle Turret_# GameObject to receive events. + [url=value] - + - Invoked when turret gun is fired. + [/url] - + - Invoked when turret gun begins reload sequence. + [img] - + - Invoked when turret gun begins hammer sequence. + [/img] - + - Invoked when turret gun begins aiming. + [previewyoutube=value] - + - Invoked when turret gun ends aiming. + [/previewyoutube] - + - Invoked when turret gun controlled by a local player begins aiming. + '\n' or "\r\n" - + - Invoked when turret gun controlled by a local player ends aiming. + [quote=value] (value is author) - + - Invoked when turret gun controlled by a local player begins inspecting attachments. + [/quote] - + - Invoked when turret gun controlled by a local player ends inspecting attachments. + [p] - + - Invoked when any player enters the seat. + [/p] - + - Invoked when any player exits the seat. + [u] - + - Invoked when a locally controlled player enters the seat. + [/u] - + - Invoked when a locally controlled player exits the seat. + Steam's new visual editor quotes value in [url=x] tag. If value is not quoted, this method returns as-is. + If it IS quoted, this methods returns without quotation marks. - + - Nelson 2025-06-19: using server-provided connection details is useful because - it can find its public IP (e.g., joining by LAN and sharing WAN IP), and/or - its fake IP (again when joining by LAN). + Breaks down Steam's version of BBcode into tokens like, "[b]", "[i]", "actual text", etc. - + - Is client UTC time within this time range? + If true, parse newlines in the input as LineBreak tokens. (default true) + If false, exclude LineBreak tokens from output. + Steam's new visual editor doesn't emit newlines, instead inferring line breaks from paragraph blocks. To + make life easier we will do the same for the main menu announcement feed. - + - Is server UTC time within this time range? + Extensions to the built-in Input class. - + - Adds custom data to base physics material asset. - For example how a vanilla material should respond to custom laser guns. + Wrapper for Input.GetKey, but returns false while typing in a uGUI text field. - + - Number of players inside the navmesh when the beacon was placed. - Clamped to 1 if ShouldScaleWithNumberOfParticipants is false. + Wrapper for Input.GetKeyDown, but returns false while typing in a uGUI text field. - + - Crossover from Dying Light. Only spawns during night. Explodes into fire at dawn. + Wrapper for Input.GetKeyUp, but returns false while typing in a uGUI text field. - + + + Should be used anywhere that Input.GetKeyDown opens a UI. + + Each frame one input event can be consumed. This is a hack to prevent multiple UI-related key presses from + interfering during the same frame. Only the first input event proceeds, while the others are ignored. + + True if caller should proceed, false otherwise. + + - Crossover from Dying Light. Only spawns during night. Explodes into fire at dawn. + Get mouse position in viewport coordinates where zero is the bottom left and one is the top right. - + - Elver endgame boss with reduced bullet damage and wind zombie stomping attacks. + Root transform. - + - Kuwait final boss with increased rock throwing, damage players inside vehicle (turrets), and flashbangs. + Hit collider's transform. Can be null. - + - Buak boss types have a red-eyed flashbang effect. + Lod group will be culled when screen size is smaller than this value. - + - Is this one of the Dying Light volatile zombies? Only spawns during night. Explodes into fire at dawn. + Clamp the culling screen percentage to be less than or equal to a maximum value. - + - Does this have the BOSS_* prefix? + Prevent the lowest LOD from being culled. - + - Same as FindChildRecursive, but skip specific child. + Temporary replacement for static block member because plugins might depend on it. - + - Editor-only helper to read all text/dialogue. + This overload supports legacy Reward_# format. - + - Version before named version constants were introduced. (2023-11-07) + This overload doesn't support legacy Reward_# format. - + - Delegate not reset when level reset. + Extensions to the built-in Screen class. + We have run into multiple problems with the Screen.resolutions property over the years, so this class aims to + protect against bad data. - + - Delegate not reset when level reset. + Splits string and compares substrings ignoring case. + Tokens containing a colon ':' are ignored so that they can represent special filters like MasterBundleSearchFilter. - + - Delegate not reset when level reset. + All main menu MTX shop code should be routed through here so that it could theoretically be ported to other + platforms or stores. Obviously this is all very Steam specific at the moment, but at least the UI does not + depend on Steam API here as much as older parts of the game. - + - Delegate not reset when level reset. + Was this item marked as new in the config? + If new, and not marked as seen, then a "NEW" label is shown on the listing. - + - Number of in-game days this world has run. - Incremented each time night ends. - Saved between sessions. + Do we have pricing details for a given item? + Price results may not have been returned yet, or item might not be public. - + - Weather has not been decided yet. Level might not have any enabled. + Messy, but we only show a menu alert if there was a problem. - + - Weather has been forecast. Timer counts down until activation. + Already filtered to only return locally known items which pass country restrictions. - + - Weather is now active. Timer counts down until deactivation. + Empty if outside new time window. - + - Weather is active. Will not deactivate naturally. - Prevents loaded perpetual weather from deactivating. + Subset of listings. - + - Determines which weather can naturally be scheduled in this level. - Includes default rain and snow for older levels. + Subset of listings. - + - Seconds until weather activates. + Subset of listings. - + - Seconds until weather deactivates. + Subset of listings. - + - Forecast or active weather. + Subset of listings. - + - Set weather active and disable scheduling. + Error code that the server exited with. + 0 is succesful, anything else is an error. - - True if given weather has config. - - + - Cancel scheduled weather and re-evaluate on next update. + Empty if successful, + otherwise an explanation of the first error encountered. - + - Cancel active weather and prevent next weather from being scheduled. + The dialogue to go to when a message has no available responses. + If this is not specified the previous dialogue is used as a default. - + - Get weather override for the currently loaded level. - Warning: this is kept for backwards compatibility, whereas newer maps will set LevelAsset.perpetualWeather. + For level objects with QuestCondition called when quests are added or removed. - + - Assign schedulableWeathers array according to level asset or legacy lighting settings. + Event specifically for plugins to listen to global quest progress. - - True if perpetual weather was enabled, false otherwise. - - + - Used by dawn and dusk skins which pull per-level lighting colors. + Event for plugins when group or rank changes. - + - Note: unfortunately it appears the stupid skin system always instantiated materials, but never destroys - them... will need to clean this up, but it will be tricky because the game does not hold a reference to them. + Overrides label text next to marker on map. + Used by plugins. Not saved to disk. - + - If true, sets the Magazine attachment hook inactive while this skin is applied. (guns only) - - Nelson 2025-03-10: Adding this to address mismatched Ace bullets with certain skins. (public issue #4923) - It should be fine for vanilla guns because there shouldn't be assumptions about Magazine enable/disable, - but modded guns may have different expectations (particularly with GunAttachmentEventHook). + Kept serverside. Used to check whether the player is currently in their Steam group or just a normal in-game group. - + - Used by melee skins to override impact sound. + Check before allowing changes to this player's - + - Restricts which items can be crafted. + Can rename the group. - + - Restrict blueprints that consume these items. + Can promote and demote members. - + - Restrict blueprints that generate these items. + If set, default spawn logic will check for a location node or spawnpoint node matching name. + Saved and loaded between sessions. - + - If false, blueprints on vanilla/core/built-in items are not allowed. Defaults to true. + If true, hide viewmodel and prevent using equipped item. For example, to prevent shooting gun on top of a + first-person scene. This could be expanded in the future with other flags and options. - + - If null, use index instead. + Called serverside to set marker on clients. - + - Restrict specific blueprints. + Ask server to set marker. - + - Thanks to Glenn Fiedler for this RK4 implementation article: - https://gafferongames.com/post/integration_basics/ + Call serverside to replicate new rank to clients - + - Higher values return to the target position faster. + Set player's group to their Steam group (if any) without testing restrictions. - - - Higher values reduce bounciness and settle at the target position faster. - e.g. a value of zero will bounce back and forth for a long time (indefinitely?) - + + Ignores group changing rules when true. - + - Absolute path to project directory, e.g. C:/U3 + Serverside send packet telling player about this invite - + - Overrides breathability for example in a deep cave with no oxygen, or near a deep sea plant that provides oxygen. + Called on server to finalize and remove quest. - + - Find highest alpha breathable volume overlapping position. + Called by quest details UI to request server to abandon quest. - + - Find highest alpha non-breathable volume overlapping position. + Called when there are no responses to choose, but server has indicated a next dialogue is available. - + - Unlike format, this returns null if key doesn't exist. + Called in singleplayer and on the server after client requests NPC dialogue. - + - This overload supports legacy Reward_# format. + Prevent re-creating it during destroy (e.g. plugin granting rewards) from leaking gameobject. - + - This overload doesn't support legacy Reward_# format. + Unturned wrapper for Debug.Log, Debug.LogWarning, Debug.LogError, etc. - + - Payload for the DamageTool.explode function. - Moved into struct because the amount of arguments to that function were insane, but now is not the time to completely refactor damage. + Log an exception with message providing context. - + - Speed to launch players away from blast position. + Recursively logs inner exception. + + Should only be called by itself and exception because notifications + to CommandWindow would otherwise get re-sent here as errors. - + + + This is the ONLY place Unturned should be binding logMessageReceived. + + This gives us greater control over how logging is handled. In particular, Unity's + headless builds route logs (including stack traces) through stdout which is undesirable + for dedicated servers, so we only call Debug.Log* in the editor and development builds. + + + - Can be added to any GameObject to receive weather events: - - Day/Night - - Full Moon - - Rain - - Snow + Log an exception with message providing context. - + - Invoked when night changes to day. + Convert 32-bit version into 8-char string. + String is advertised on server list for clients to filter their local map version. - + - Invoked when day changes to night. + Parse 32-bit version from 8-char string. + String is advertised on server list for clients to filter their local map version. - + - Invoked when a zombie full-moon event starts. + Catch exceptions to prevent a broken powerable from breaking all the other powerable items in the area. - + - Invoked when a zombie full-moon event finishes. + Unsorted list of world space generators turned-on and fueled. - + - Invoked when rain starts to fall. + Optional parameter for error logging. - + + + Utility for getting local hardware ID. + + One option for future improvement would be using Windows Management Infrastructure (WMI) API. + + + - Invoked when rain finishes falling. + Maximum number of HWIDs before server will reject connection request. - + - Invoked when snow starts to fall. + Get the local hardware ID(s). - + - Invoked when snow finishes falling. + Can be added to descendants of Vehicle GameObject to receive events. - + - Registers renderers with DynamicWaterTransparentSort manager. + Manually placed from the asset browser or old editor. - + - In vanilla this field is ONLY used for the per-character saves on servers. - If that changes check that it does not affect the savedata options. + Spawned by foliage baking system. - + - 20-byte SHA1 salted hashes of client's hardware ID(s). - Providing multiple HWIDs makes it more difficult to bypass HWID bans because spoofing a single component - only changes one of the bans. For example spoofing the MAC address will not spoof the Windows GUID. - - Randomized if system did not support hwid, or perhaps player is cheating. - Should not be called on the client side, but just in case there is a default zeroed array. + Brushed on with the foliage tool. - + - Ignore requests to kick me in debug mode. :) - Steam ID may not have been authenticated yet here which may seem like a security risk, but fortunately that - would get caught when Steam auth ticket response is received. + Please refer to . - + - Array of 20-byte SHA1 hashes. + Please refer to . - + + + The dialogue to go to when a message has no available responses. + If this is not specified the previous dialogue is used as a default. + If neither is available then a default "goodbye" response is added. + + For example, Chief_Police_Doughnuts_Accepted dialogue has a single message + "Let's just keep this between the two of us." shown with "prev" dialogue + set to the NPC's root dialogue asset. + + + - Not using rate limit attribute because this is potentially called for hundreds of structures at once, - and only admins will actually be allowed to apply the transform. + If true, NVGs work in third-person, not just first-person. + Defaults to false. - + - See BarricadeRegion.FindBarricadeByRootFast comment. + Single percentage randomness with two outcomes. - + - For code which does not know whether transform exists and/or even is part of a house. - See BarricadeRegion.FindBarricadeByRootFast comment. + If true the event will only be invoked in offline mode and on the server. - + - Steam APIs returned uint32 IPv4 addresses in the past, so Unturned code depends on them in some places. - Ideally these uses should be updated for IPv6 support going forward. - For the meantime this method converts from the new format to the old format for backwards compatibility. + Percentage chance of event occurring. - + - Assets cannot be loaded from Resources during static initialization, so this reference defers the load until - the first time user tries to use it. + Invoked when random event occurs. - + - Material on Model_0, the low-speed actual blade. + Invoked when random event does NOT occur. - + - Renderer on Model_1. + Far clip plane multiplier in-game. - + - Material on Model_1, the high-speed blurred outline. + Far clip plane multiplier in level editor. - + - transform's localRotation when the vehicle was instantiated. + Non-NPC object the player can talk with. - + - Rigidbody component on the root game object. + Synchronize widgets with their values. - + - If true, set sharedMaterial. If false, set material. + Assigned when a named preset is created. + 0 is the default and should be replaced by a preset when loaded. + -1 indicates the preset was modified. + -2 and below are the default presets. - + - Calculated speed of this track. Used by some wheels. + Nelson 2024-09-20: Changing default to any (from has players) because the default server list sort will now + push empty servers to the bottom. - + - Temporary array for use with physics queries. + If true, only servers with available player slots are shown. + Nelson 2024-09-20: Changing default to false because the default server list sort will now push them down + from the top a little bit. - + - Temporary list for gathering materials. + If >0, servers with ping higher than this will not be shown. - + + True if level was added to the list of maps. + + - Precursor to Net ID. Should eventually become obsolete. + Version before named version constants were introduced. (2023-11-13) - + - Asset ID. Essentially obsolete at this point. + % Full - + - Used to restore vehicle materials when changing skin. + Allows Unity events to send text chat messages from the client, for example to execute commands. - + - Only used by trains. Constrains the train to this path. + Text to use when SendDefaultTextChatMessage is invoked. - + - Unfortunately old netcode sends train position as a Vector3 using the X channel, but new code only supports - [-4096, 4096) so we pack the train position into all three channels. Eventually this should be cleaned up. + All players on the server will see the message. - + - Nelson 2024-06-24: When first implementing batteries there was only the vanilla battery item, and it was - fine to delete it when the charge reached zero. This may not be desirable, however, so zero now represents - no battery item is present, and one represents the battery is completely drained but still there. + Only nearby players will see the message. - + - Is this vehicle inside a safezone? + Chat mode to send request in. - + - Duration in seconds since this vehicle entered a safezone, - or -1 if it's not in a safezone. + If true then level should convert old terrain. - + - Should askDamage requests currently be ignored because we are inside a safezone? + If true, splatmap conversion should use weights as-is. - + - Nelson 2024-06-24: This property is confusing, especially with isEnginePowered, but essentially represents - starting the engine ignition when a player enters the driver's seat. If true, there's a driver, there was - sufficient battery to start (or battery not required), and the engine wasn't underwater. + Material guids converted by legacy asset bundle hash or texture names. - + - Doesn't imply the vehicle *uses* batteries, only that it contains a battery item with some charge left. + Hash of Trees.dat, or zeroed if any assets were missing locally. + Should only be used if level is configured to, as many mod maps are typically missing assets. - + - Doesn't imply the vehicle *uses* batteries, only that it contains a (potentially uncharged) battery item. + Nelson 2025-06-10: replacement for _trees. Enables trees outside the "insane" level bounds. - - - Nelson 2024-11-13: Adding this primarily to indicate whether a vehicle was spawned by the level versus - placed by a player or bought from a vendor. This way if the number of "naturally"-spawned vehicles is below - a certain threshold the level can spawn more. (e.g., a server where players have hoarded a bunch of - vendor-purchased vehicles and no default vehicles are left for new players.) - - Only available on the server. - Defaults to true for old saves to prevent suddenly spawning a bunch more vehicles. - - - + - Whether the player can shoot their equipped turret. + Append all trees in the level to results list. - + - Do any of the passenger seats have a player? + Game does not currently have a way to resave level's Config.json file, so instead we save a text file + indicating that the terrain auto conversion was performed. If there was a bug with auto conversion then + all of the old files are still present and can be re-converted. - + - When the server saves it doesn't include any cleared vehicles. + Stagger regional visibility across multiple frames. - + - If true, the vehicle will be destroyed at the end of the frame. Set before OnPreDestroyVehicle. - Used to reject requests to enter the vehicle on the same frame it's being destroyed. + Caches uint16 ID to ID redirects. - + - Magnitude of rigidbody velocity, replicated by current simulation owner. + Filter for whether the Permanent Gold Upgrade DLC is required to join a server. - + - Rigidbody velocity along forward axis, replicated by current simulation owner. + All servers pass the filter. - + - Replicated by current simulation owner. Target velocity used, e.g., for helicopter engine speed. + Only non-gold servers pass the filter. - + - [0, 1] If forward velocity is greater than zero, get normalized by target forward speed. If less than zero, - get normalized by target reverse speed. Result is always positive. + Only gold servers pass the filter. - + - Animated toward ReplicatedForwardVelocity. + If greater than zero, picking the lock can fail. - + - Animated toward ReplicatedVelocityInput. + Registers renderers with DynamicWaterTransparentSort manager. - + - [-1.0, 1.0] Available on both client and server. + Ehh kind of a stretch to mark this obsolete or for backwards compatibility. Introducing it for road assets + which specify the PhysicMaterial to assign to the colliders. Specifying an asset path is available, but + for the common case we will use the built-in vanilla resources. - + - Animated towards replicated steering angle. Used for steering wheel and front steering column. - Non-simulating wheels (e.g., car driven by remote client) use this as steering angle multiplied by their - per-wheel . + Get legacy enum corresponding to Unity physics material object name. + Moved from obsolete checkMaterial method. - + - Front steering column of bicycles and motorcycles. + If collider and its physics material are not null, get the physics material's name. Null otherwise. + + Nelson 2025-04-22: this method may seem silly on first glance. However, I tracked down some every-frame + memory allocation to getting the PhysicMaterial.name property. This method caches the instance ID to + name lookup in a dictionary to avoid that. Note: we don't worry about clearing the dictionary because + there aren't very many physics materials. - + - If true, server should replicate latest state to clients. + This is the only /required/ override of text writer. - + - Used by several engine modes to represent an interpolated velocity target according to input. + Allows Unity events to broadcast Event NPC rewards. - + - Set from inputTargetVelocity then multiplied by any factors which shouldn't affect the player's "target" - speed ike boatTraction. + Event ID to use when SendDefaultEventId is invoked. - + - Vehicles with buoyancy interpolate this value according to whether it's in the water, and multiply - boat-related forces by it. + The event messenger can only be triggered on the authority (server). + If true, the server will replicate the event to clients. - + - Rigidbody on the Vehicle prefab. - (not called "rigidbody" because as of 2024-02-28 the deprecated "rigidbody" property still exists) + Compares weather intensity to value. - + - Primarily for backwards compatibility with plugins. Previously, multiple "updates" could be queued per - vehicle and sent to clients. This list was public, unfortunately, so plugins may rely on submitting vehicle - updates. After making it obsolete each vehicle can only be flagged as needing a replication update, and - this is reset after each server replication update. + Invokes an event a configured number of times. - + - Is player currently allowed to repair this vehicle? + If true the event will only be invoked in offline mode and on the server. - + - Give battery item to player and set battery charge to zero. + Invoked multiple times. - + - Nelson 2024-06-24: Previously, this wouldn't give an item to the player if the quality was zero. Now it - trusts the caller to validate we have a battery item to give, and respects . + Used in a test scene to quickly test whether pooled components are cleaned up. - + - Can a tire item be used with this vehicle? + Material instantiated when dual-render scopes are enabled. + Overrides the material of the gun sight attachment. - + - Find the index of the wheel collider that contains this position. + Unintuitively (to say the least), a pitch of 0 is up, 90 is forward, and 180 is down. - + - Find the index of the wheel collider closest to this position, or -1 if not near any. + Nelson 2025-06-27: previously, stopping aim cancelled the sway offset immediately. When + experimenting with removing the dual-render scope blur this felt jarring. - + - Called during simulate at fixed rate. + Reset to actual fov when first used. - + - Is a given player allowed access to this vehicle? + If true, freecam controls take input priority. + Previously named isOrbiting. - + - If true, sentry ignores this vehicle early in target scanning. - Friendly if locked by owner/group of sentry, or driven by owner/group of sentry. + Should player stats be visible in spectator mode? - + - Average vehicle-space position of wheel bases. + Smoothing adds some initial blend-in which felt nicer for explosion rumble. - + - Turn taillights on/off depending on state. + Slightly clamped third-person version of "eyes" value to prevent sweep from hitting floor. - + - Returns null if index is out of bounds or initialization has failed. + Get point-of-view in world-space. - + - Returns null if index is out of bounds, initialization failed, or seat is empty. + Get point of view in worldspace without the left/right leaning modifier. - + - This check should really not be necessary, but somehow it is a recurring issue that servers get slowed down - by something going wrong and the vehicle exploding a billion times leaving items everywhere. + This is only used after capturing dual-render scope, not when exiting scope overlay. + Otherwise the lighting vision may have changed between entering and exiting the scope. - + - VehicleManager expects this to only find the seat, not add the player, - because it does a LoS check. + Clamp _pitch within the [0, 180] range. - + - Call on the server to empty the vehicle of passengers. + Clamp yaw while seated, and keep within the [-360, 360] range. - + - Kicks them out even if there isn't a good spot. Used when killing the occupant. + Can spectating be used without admin powers? + Plugins can enable spectator mode. - True if player is seated, false otherwise. - - - Can a safe exit point currently be found? - - Called when considering to add a new passenger to prevent players from entering - a vehicle that they wouldn't be able to exit properly. - - - + - Could a player capsule fit in a given exit position? + Can workzone be used without admin powers? + Plugins can enable workzone permissions. - - True if anything was hit. - - + - Raycast along a given direction, penetrating through barricades attached to THIS vehicle. - Returns point at the end of the ray if unblocked, or a safe (radius) distance away from hit. + Can spectator overlays be used without admin powers? + Plugins can enable specstats permissions. - - - Fallback if there are absolutely no good exit points. - Sets point and angle with a normal player spawnpoint. - - Once vehicle is completely surrounded there is no nice way to pick an exit point. Finding - a point upwards is abused to teleport upward into bases, finding an empty capsule nearby is - abused to teleport through walls, so if we're sure there isn't a nice exit point we can - fallback to teleporting them to a safe spawnpoint. - - - - True if we can safely exit. - - + - Initially use tryGetExit to find a safe exit, but if one isn't available then fallback to getExitSpawnPoint. + Called from the server to allow spectating without admin powers. + Only used by plugins. - + - Dedicated server simulate driving input. + Allow use of spectator mode without admin powers. + Only used by plugins. - + - -1 is reverse. - 0 is neutral. - +1 is index 0 in gear ratios list. + Called from the server to allow workzone without admin powers. + Only used by plugins. - + - Engine RPM replicated by current simulation owner. + Allow use of workzone mode without admin powers. + Only used by plugins. - + - Animated toward ReplicatedEngineRpm. + Called from the server to allow spectator overlays without admin powers. + Only used by plugins. - + - Called when engine RPM exceeds threshold and there are more gears available. - Purpose is to skip gear numbers that don't bring engine RPM within threshold (if possible). + Allow use of spectator overlay mode without admin powers. + Only used by plugins. - + - Called when engine RPM is below threshold and there are more lower gears available. - Purpose is to skip gear numbers that don't bring engine RPM within threshold (if possible). + Multiple hits are necessary because the first returned hit is not always the closest. - + - Client simulate driving input. + Sweep a sphere to find collisions blocking the third-person camera. + Valid world-space camera position. - + - Nelson 2025-05-05: ran into a bug where our manual OnUpdate is called before Unity calls Start! + Associates items of the same currency, e.g. dollars or bullets. - + - Nelson 2025-05-02: keeping the previous comment from 2020-11-26 here. At first I wondered if 24 vehicles - wasn't enough to properly test, but even with a higher vehicle count it can seemingly be *slower* to - call Update manually. That said, calling Update manually does give us the option to time-slice vehicle - updates. On the client and singleplayer we now update vehicles outside render distance at a lower - frequency which saves ~0.1 ms per frame on my PC. - - 2020-11-26 experimented with dispatching all vehicle updates from C# in VehicleManager because they make up - a significant portion of the MonoBehaviour Update, but the savings on my PC with 24 vehicles on PEI was - minor. Not worth the potential troubles. + Should this item/value be shown in the list of vendor currency items? + Useful to hide modded item stacks e.g. a stack of 100x $20 bills. - + - Nelson 2025-04-22: it hopefully goes without saying the bicycle pedals are janky as heck, I'm just separating - out the Update method to make profiling it easier. + String to format value {0} into. - + - Nelson 2025-04-22: this should ideally be moved into FixedUpdate, incorrect to run in Update. + String to format value {0} of total {1} into if not otherwise specified in NPC condition. - + - Nelson 2025-04-22: this should ideally be moved into FixedUpdate, incorrect to run in Update. + Sum up value of each currency item in player's inventory. - + - Update whether this vehicle is inside a safezone. - If a certain option is enabled, unlock after time threshold is passed. + Does player have access to items covering certain value? - + - Can be called without calling init. + Add items to player's inventory to reward value. - + - Called after initializing vehicle. + Remove items from player's inventory to pay required value. - + - Makes the collision detection system ignore all collisions between this vehicle and the given colliders. - Used to prevent vehicle from colliding with attached items. + Sort currency entries by value. - - - Used to disable collision between skycrane and held vehicle. - + + + Valid when opened in Begin or End mode. + + If the quest is ready to complete the UI is opened in End mode to allow + the player to see what rewards they will receive after clicking continue. + Otherwise, in Begin mode the UI is opened to allow the player to review + the conditions before accepting or declining the request. + + If the player cancels the pending response is NOT chosen. + - + - Transform used for exit physics queries. + Valid when opened in Begin or End mode. + The player clicked pendingResponse in this dialogue to open the quest UI. - + - Find collider with the largest volume to use for exit physics queries. + Absolute path to project directory, e.g. C:/U3 - + - Set material on DepthMask child renderer responsible for hiding water when interior of vehicle is submerged. + Returning an Asset rather than the older IDs allows GUIDs to be used. + legacyTargetAssetType is required for compatibility with spawn tables using legacy 16-bit IDs. If set to + None and the spawn asset uses legacy IDs a warning is logged explaining GUIDs are necessary. + - + - Skin material does not always need to be destroyed, so this is only valid if it should be destroyed. + Doesn't support spawn assets with legacy 16-bit IDs. - + - Materials that should be destroyed when this vehicle is destroyed. + For backwards compatibility with features that still need a legacy ID rather than asset. - + - Handles to unregister from DynamicWaterTransparentSort. + For backwards compatibility with features that still need a legacy ID rather than asset. - + - Materials to set _PaintColor on. + For backwards compatibility with features that still need a legacy ID rather than asset. - + - Materials to move UVs in sync with wheels. + Search loaded assets for blueprints that output a single structure item and are + available on the current map. - + - Time.time decayTimer was last updated. + Update status of all relevant blueprints. - + - Seconds since vehicle was interacted with. + Currently saved craftableBlueprint for asset may have become uncraftable, + in which case we try finding a craftable replacement. - + - Fractional damage counter. + Get a blank status from the pool or construct a new one. - + - transform.position used to test whether vehicle is moving. + Search inventory for housing items, count the quantity of each, and remove + duplicate entries from the list because it is used for the UI. - + - Text from *.dat localization file. + Stripped-down version of structure prefab for previewing where the structure will be spawned. - + - Older *.content asset bundle reference. + Whether preview object is currently highlighted positively. - + - Newer *.masterbundle reference. + Position the item should be spawned at. - + - Optional URL to open in web browser. + Rotation the item should be spawned at. - + - Whether audio source should loop. + Interpolated toward customRotationOffset. - + - Append suffix to name, or if name contains a '.' insert it before. + Allows players to flip walls. - + - Vendor asset that owns this buy/sell record. + Vertical offset using scroll wheel. - + - If not null, replaces item/vehicle description. + Box in the HUD with selected item name and quantity. - + - Allows Unity events to startle nearby animals and zombies. + Blueprints which create a structure item. - + - Transform to spawn the alert at. - If unset, this game object's transform will be used instead. + One craftable blueprint per potential structure item. - + - If true, find the nearest player within ScanForPlayersRadius, and use the player's position as the alert - origin. + Recycled blueprint statuses. - + - If UseScanForPlayers is enabled and this is true, an alert is broadcast even if no nearby player was found. - Otherwise, alert is ignored if no nearby player was found. + Hashes for Windows, Linux, and Mac asset bundles. + Only loaded on the dedicated server. Null otherwise. - + - Used in a test scene to quickly test whether pooled components are cleaned up. + Does given hash match any of the platform hashes? - + - Invoked after any player's stance changes (not including loading). + Compares client asset bundle hash with server known hashes. - + - Stance to fit available space when loading in. + Called by asset startup to cache which bundles are eligible for hashing. - - Distance zombies can detect this player within. - - + - Older, cached version of areEyesUnderwater. + Position to place players outside visible range. + Defaults to as far away as supported by default clamped Vector3 precision. + Doesn't use world origin because that would potentially increase rendering cost for clients near the origin. - + - Return false if there are any external restrictions (e.g. reloading, handcuffed) preventing climbing. + Whether local client is currently penalized for potentially using a lag switch. Server has an equivalent check which reduces + damage dealt, whereas the clientside check stops shooting in order to prevent abuse of inbound-only lagswitches. For example, + if a cheater freezes enemy positions by dropping inbound traffic while still sending movement and shooting outbound traffic. - + + + Will test player be culled for viewer at a given position? + + Members of the same group are always visible to each other. (Used by map and HUD name overlay.) + + Admins with the Spectator Overlay enabled are able to see all clients. + Similarly, plugins can set ServerAllowKnowledgeOfAllClientPositions to show all clients. + + Players in vehicles: + VehicleManager notifies all clients when a player enters a vehicle, so a client may know the player's + position even if this method suggests otherwise. When exiting the vehicle, CulledPosition is sent + instead of the real exit position to clients who should cull the new position. + + + + True if it's a new claim flag. + + - Test whether bottom of controller is currently inside a water volume. + If true, PopulateAsset can modify data. For example, to replace deprecated properties. + Only true if asset re-saving and asset metadata parsing are enabled, and asset origin allows re-saving. + Modifications are not saved if asset has any errors in order to avoid losing data. - + - Test whether viewpoint is currently inside a water volume. + If true, an asset with the same ID or GUID has been added to the current asset mapping, replacing this one. - + - Test whether body is currently inside a water volume. - Enters the swimming stance while true. + If true, errors related to this asset were reported during loading. - + - Draw debug capsule matching the player size. + Null or empty if created at runtime, otherwise set by when loading. - + - Draw standing-height debug capsule matching the player size. + Contents of file this asset was loaded from. Only kept if data re-saving is enabled. (So that this memory + is collected after populating the asset.) - + - Is there enough height for our capsule at a position? + Translation data associated with this asset. Only kept if per-asset property + "Keep_Localization_Loaded" is true. + (Otherwise, memory is collected after populating the asset.) + Nelson 2025-11-07: hacking this in so that NPC hints replicated from the server don't + use the server's language. - + - Could a standing player capsule fit at the given position? + Master bundle this asset loaded from. - + - Could a crouching player capsule fit at the given position? + Were this asset's shaders set to Standard and/or consolidated? + Needed for vehicle rotors special case. - + - Could a prone player capsule fit at the given position? + Should texture non-power-of-two warnings be ignored? + Unfortunately some third party assets have odd setups. - + - Could a standing player capsule teleport to the given position? + Should read/write texture warnings be ignored? - + - Is there any compatible stance that can fit at position? + Hash of the original input file. - + - Using our capsule's current height would there be enough space at a given position? + Maybe temporary? Used when something in-game changes the asset so that it shouldn't be useable on the server anymore. - + - Does capsule have appropriate clearance for a pending height change? + Most asset classes end in "Asset", so in debug strings if asset is clear from context we can remove the unnecessary suffix. - + - Replicate stance to clients. + Remove "Asset" suffix and convert to title case. - + - Regular interact ray still hits the ladder, but we only allow climbing within a smaller range to make its - teleport less powerful. + e.g. Canned Beans (Consumeable Item) - + - Ladder forward ray is 0.75m, so we move slightly less than that away from the ladder. + Perform any initialization required when PopulateAsset won't be called. - + - Export JSON report of Unturned's assets for economy usage. + Planning ahead to potentially convert the game to use Unity's newer Addressables feature. - + - If true, contains child transform named Effect for mythical attachment. + Nelson 2024-12-16: This menu and ESteamUGCType are far from ideal, but I'm just trying to hack in a new tag for + server browser curation assets before the update. :P - + - Attachment item IDs that get skinned specially. + Nelson 2025-02-20: Hacking this in to address duplicate buttons when onPublishedAdded is called for a second + page of published files. (public issue #4882) - + - Is there a fallback material for attachments that respects their main metallic areas? + Crossover from Dying Light. Only spawns during night. Explodes into fire at dawn. - + - Is there a fallback material without any special features? + Crossover from Dying Light. Only spawns during night. Explodes into fire at dawn. - + - Is there a replacement mesh? + Elver endgame boss with reduced bullet damage and wind zombie stomping attacks. - + - Dawn and dusk skins pull per-lighting colors. + Kuwait final boss with increased rock throwing, damage players inside vehicle (turrets), and flashbangs. - + - Pool lists to avoid loopback re-using an existing list. - Callers do not need to manually return lists because they are reset before each frame. + Buak boss types have a red-eyed flashbang effect. - + - Exit button only needs to wait for timer in certain conditions. + Is this one of the Dying Light volatile zombies? Only spawns during night. Explodes into fire at dawn. - + - Does the item being placed count as a "trap" for the purposes of vehicle placement restrictions? + Does this have the BOSS_* prefix? - + - Should placement ghost material change be done recursively? - e.g. Sentry has a deep hierarchy of meshes. + Same as FindChildRecursive, but skip specific child. - + - Given path to a workshop map, try to find its /Bundles folder. + Flag in case levelObject is destroyed. - + - Given path to a workshop map, try to find its /Content folder. + When placing structures that snap to grid multiple requests can come + in to the server at the same time, and checking overlaps against structures + can be problematic, so as a backup we track pending build requests + and cancel ones which conflict. - + - Maps on the workshop are a root folder named after the published file id, containing - the map folder itself with the level name. In order to load the map's bundles and content - properly we need to find the nested Bundles and Content folders. + Register a location as having something built there soon. + Unique handle to later finish the request. - + - 2023-02-28: note order is important because BarricadeManager saves as a byte! + Is a location available to build at (i.e. no pending builds)? + False if there are any outstanding build requests for given location. - + - Invoked after tellGesture is called with the new gesture. + Notify that a previously registered build has been completed. + Unique handle. - + - Empty transform created at the world origin. - The first-person Viewmodel transform is re-parented to this. + Allows Unity events to print messages to the log file for debugging. - + - Child of the first-person skull transform. + Text to use when PrintInfo is invoked. - + - Camera near world origin masking the first-person arms and weapon. + Disables Unity native systems unused by Unturned. - + - Used by gun to hide viewmodel arms while aiming 2D scope, and by chainsaw to shake the viewmodel. + Is client UTC time within this time range? - + - Used to hide viewmodel arms while using a vehicle turret gun. + Is server UTC time within this time range? - + - Offsets main camera and aim rotation while aiming with a scoped gun. + If true, clients destroy Throwable prefab upon collision. Defaults to false. + Optional to ensure backwards compatibility for unexpected setups. - + - Animated toward viewmodelSwayMultiplier. + Broadcasts for plugins before applying consumeable stats to another player. - + - Small number (0.1) while aiming, 1 while not aiming. - Reduces viewmodel animation while aiming to make 3D sights more usable. + Broadcasts for plugins after applying consumeable stats to another player. - + - Animated toward viewmodelOffsetPreferenceMultiplier. + Broadcasts for plugins before applying consumeable stats to self. - + - 0 while aiming, 1 while not aiming. - Players can customize the 3D position of the viewmodel on screen, but this needs - to be blended out while aiming down sights otherwise it would not line up with - the center of the screen. + Broadcasts for plugins after applying consumeable stats to self. - + - If true, use the scope aim fov instead of non-scope fov. - Useful for players with high (e.g. 160) fov to be able to use scopes. + Called serverside when using consumeable on another player. - + - Animated toward viewmodelCameraLocalPositionOffset, recoil, and bayonet offsets. + Called by owner and server when using consumeable on self. - + - Abruptly offset when gun is fired, then animated back toward zero. + Static functions for creating monitor instance on server. - + - Abruptly offset when gun is fired, then animated back toward zero. - x = pitch, y = yaw, z = roll + Entry point called by dedicated server after loading level. - + - Abruptly offset when bayonet is used, then animated back toward zero. + Create vanilla update monitor that watches for changes to workshop level file and any other mods. - + - Animated while player is moving. + Helper to get updated timestamp from workshop items loaded by DedicatedUGC. - + - Blended from multiple viewmodel parameters and then applied to viewmodelCameraTransform. + Helper to create monitored item for use with default DedicatedWorkshopUpdateMonitor implementation. - + - Smoothing adds some initial blend-in which felt nicer for explosion rumble. + For use with default DedicatedWorkshopUpdateMonitor implementation. - + - Meshes are disabled until clothing is received. + Allows file name to be included in kick message that client would otherwise not know. - + - Target viewmodelCameraLocalPosition except while driving. + Actual max value is plus one because message never contains zero items. - + - Animated while playing is moving. - x = pitch, y = roll + Allow Unity events to apply damage in a sphere. (doesn't have any visual effects) + Intended to replace unsupported/unintentional use of "Grenade.cs" and "Rocket.cs" scripts. - + - Offset when player lands. + Zombie explosion types have slight variations e.g. lighting zombies on fire. - + - Used to measure change in pitch between frames. + If greater than -0.5, overrides default radius zombies and animals will be alerted within. - + - Used to measure change in yaw between frames. + If true, per-surface effects like blood splatter are created. - + - Animated according to change in pitch/yaw input between frames so that gun rolls slightly while turning. + If true, explosion damage passes through Barricades and Structures. - + - Animated according to change in item position between frames so that animations have more inertia. + Speed to launch players away from blast position. - + - Degrees per meter of item distance travelled. - Pitch is driven by vertical displacement, yaw and roll are driven by horizontal. - x = pitch, y = yaw, z = roll + Parses -X=Y from command-line. + Ideally we could do "where T : TryParse" but for the meantime there are specialized subclasses. - - - In third-person this delays leaning in case player only wanted - to switch camera side without leaning. - - - - If true, include current animation speed modifier. - - - - At this point camera is already being shook, we just add some of the same shake to viewmodel for secondary motion. - - - - - Called by clothing to make mesh renderers visible. - - - - - Event for server plugins to monitor whether player is in-inventory. - - - - - Rate limit is relatively high because this RPC handles open/close inventory notification. - - - - - Nelson 2024-03-20: Adding this method because (at the time of writing) first and third-person renderers - and skeletons are activated/enabled in InitializePlayer, onPerspectiveUpdated, and onLifeUpdated, and I - want them to be consistent with the addition of the new NPC Cutscene Mode option. - - - - - 2023-01-18: Viewmodel camera position was originally set during Update (and still is for compatibility), - but for aiming alignment that uses the previous frame's animation position, so we also modify during - LateUpdate to use this frame's animation position. - - - - - Factor e.g. 2 is a 2x multiplier. - Prior to 2022-04-11 this was the target field of view. (90/fov) - - - - - Determines how NPCFlagMathReward handles formatReward. - - - - - Use text as-is without formatting. For backwards compatibility. - - - - - Format flag A value into {0} and flag B value (or default) into {1}. - - - - - [0, 1] percentage whether a shot decreases ammo count. Defaults to 100%. - For example, 0.25 means 25% of shots will use a bullet, while the remaining 75% will be free. - - - - - [0, 1] percentage whether a shot decreases quality. Defaults to 100%. - Combined with the gun's chance of decreasing quality. - - - - - Players/zombies within this range are treated as potential targets while scanning. - - - - - Will not lose current target within this range. Prevents target from popping in and out of range. - - - + - If true, this sentry can attack players. Defaults to true. + Write header common to both static and instance methods, and return writer. - + - If true, this sentry can attack zombies. Defaults to true. + Essentially deprecated for now. - + - If true, this sentry can attack animals. Defaults to true. + Can be added to descendants of Vehicle GameObject to receive events. - + - If true, this sentry can attack vehicles. Defaults to true. + New code should not use this. Only intended for backwards compatibility. - + - If the file already exists when writing we will move it to this path. (public issue #4636) + Ideally the interactable components should have a reference to their barricade, but that will maybe happen + after the NetId rewrites. For the meantime this is to avoid calling FindBarricadeByRootTransform. If we go + the component route then FindBarricadeByRootTransform will do the same as this method. @@ -3526,17244 +3407,17747 @@ hasClipPrefab is false then client-supplied colliderTransform must be valid. - + - Can be added to any GameObject with a Trigger to receive events. - Ensure that Layer will detect player overlaps. Trap is a good candidate. + Windows-specific extensions of console input. + Uses the Win32 API to force a console to be created and destroyed. - + - Invoked when a player enters the trigger. - Called before OnFirstPlayerEnter. + Kept because lots of modders have been using this script in Unity, + so removing legacy effect id would break their content. - + - Invoked when a player exits the trigger. - Called before OnAllPlayersExit. + Implemented by "root" component of each entity type that can provide crafting tags to nearby players. + This allows overlap with a barricade attached to a vehicle to find the barricade from barricade collider and + vehicle from vehicle collider rather than using transform root. Any mod hook extensions to crafting tags will + be sibling components or descendants of this component. - + - Invoked when first player enters the trigger, and not again until all players have left. - Called after OnPlayerEnter. + Asset providing tags. For example, a barricade item. - + - Invoked when last player exits the trigger. - Called after OnPlayerExit. + True if GetAvailableTags can ever add any tags. + Used to skip unnecessary line-of-sight tests against (for example) ordinary structures and the like. - + - Nelson 2024-12-16: This menu and ESteamUGCType are far from ideal, but I'm just trying to hack in a new tag for - server browser curation assets before the update. :P + All tags added by this crafting tag provider. - + - Nelson 2025-02-20: Hacking this in to address duplicate buttons when onPublishedAdded is called for a second - page of published files. (public issue #4882) + Hints/messages are the pop-up texts below the interaction prompt, e.g. "reload" or "full moon rises". + Got a complaint that the item placement obstructed hint was shown if placing multiple signs. - + - Allows Unity events to spawn items. + Adjust screen positioning and visibility of player name widgets to match their world-space counterparts. - + - Called when the player clicks the cosmetic, visual or skin toggle buttons. + Update hitmarker visibility, and their world-space positions if user enabled that. - + - Invoked after any player's shirt values change (not including loading). + Disable hints and messages if no longer applicable. - + - Invoked after any player's shirt values change (not including loading). + Disable vote popup if enough time has passed. - + - Invoked after any player's hat values change (not including loading). + Pause the game if playing singleplayer and menu is open. - + - Invoked after any player's backpack values change (not including loading). + Many places checked that the cursor and chat were closed to see if a menu could be opened. Moved here to + also consider that useable might have a menu open. - + - Invoked after any player's backpack values change (not including loading). + Used for item placement in displays / holsters, and whether useable can be placed in primary/secondary slot. - + - Invoked after any player's backpack values change (not including loading). + Cannot be placed in primary nor secondary slots, but can be equipped from bag. - + - Invoked after any player's glasses values change (not including loading). + Can be placed in primary slot, but cannot be equipped in secondary or bag. - + - Null if not bookmarked. + Can be placed in primary or secondary slot, but cannot be equipped from bag. - + - DNS entry to use if adding a bookmark for this server. + Only used by NPCs. - + - Adjusts width and spacing of buttons along the bottom of the screen. - Favorite and bookmark buttons can be hidden depending whether the necessary server details are set. + Can be placed in primary, secondary, or equipped while in bag. - + - Sort items with lowest "amount" to front of list. + Before they became an official engine feature, I was obsessed with getting projected decals into Unturned. + I remember noticing them in so many games at the time like, for example, Overwatch. Aras P at Unity wrote + a blog post explaining how command buffers could be used to achieve them which set us on the right course: + https://unity.com/blog/engine-platform/extending-unity-5-rendering-pipeline-command-buffers - + - Sort items with highest "amount" to front of list. + True while fading in or fully transitioned in. - + - Sort items with lowest quality% to front of list. + True while fading in, but not at full intensity. - + - Sort items with highest quality% to front of list. + True while finished fading in. - + - Sum up number of items found, ignoring amount. - Default except as described in TotalAmount comment. + True while fading out, but not at zero intensity. - + - Sum up "amount" of each item. Optionally counting zero as one (ShouldCountEmptyAsOne). - Default for legacy "ammo type" blueprints and FillTargetItem operation. + True while finished fading out. - + - Note: if calling ItemRef.Get() please use FindItemAsset instead to avoid redundant asset lookups. + True while fading in or out. - + - If true, items with an "amount" of zero are included in eligible supplies as amount 1. - In practice (as of 2025-03-03), items with zero amount are empty containers such as magazines. + Read commands from standard input, and write logs to standard output. - + - Determines how totalAmount of each input is calculated. + Broadcast the inputCommited event. - + - If true, items with an "amount" of zero are included in eligible supplies. - Otherwise, they are ignored (default). + Synchronize console's title bar text. + Virtual because at one point Win32 SetTitleText was required. - + - If true, items with an "amount" >= their MaxAmount are ignored. Otherwise, they are eligible (default). + Intercept the Ctrl-C or Ctrl-Break termination. - + - If true, items with quality of 100% are eligible (default). Otherwise, they are ignored. + Handle Ctrl-C or Ctrl-Break on the game thread. - + - Controls which items are used first. For example, whether to use the lowest quality items first. + Has Ctrl-C or Ctrl-Break signal been received? - + - If true, delete input item. Defaults to true. - Replaces the "tool" blueprint option. + Is the Ctrl-C or Ctrl-Break signal being handled? - + - Does this blueprint input require the specified item? + Payload for the DamageTool.damagePlayer function. - + - Controls whether vehicle allows barricades to be attached to it. + Should armor worn on matching limb be factored in? - + - Vehicle does not override placement. This means, by default, that barricades can be placed on the vehicle - unless the barricade sets Allow_Placement_On_Vehicle to false. (e.g., beds and sentry guns) Note that - gameplay config Bypass_Buildable_Mobility, if true, takes priority. + Should game mode config damage multiplier be factored in? - + - Vehicle allows any barricade to be placed on it, regardless of the barricade's Allow_Placement_On_Vehicle - setting. The legacy option for this was the Supports_Mobile_Buildables flag. Vanilla trains originally - used this option, but it was exploited to move beds into tunnel walls. + If player dies should it count towards quests? - + - Vehicle prevents any barricade from being placed on it. Note that gameplay config Bypass_Buildable_Mobility, - if true, takes priority. + Effect to apply to ragdoll if dead. - + - Scene hierarchy path relative to vehicle root. + Marker for counting number of tips. - + - Index in renderer's materials array. + Camera used while transitioning between scenes to prevent the "no cameras rendering" warning. - + - If true, apply to every item in renderer's materials array. + Shown when game connection ping is significantly higher than server browser ping. At the time of writing + (2025-01-17) this is likely because the server is using an "anycast proxy" in front of Steam A2S cache. - + - Controls how vehicle's default paint color (if applicable) is chosen. + Set to Time.frameCount + 1 while loading. + In the past used realtime, but that was unreliable if an individual frame took too long. - + - Not configured. + Select a loading image while on the startup screen or a level without any images. - + - Pick from the DefaultPaintColors list. + Only RPCs from the server will be allowed to invoke this method. - + - Pick a random HSV using VehicleRandomPaintColorConfiguration. + RPCs are only allowed to invoke this method if we're running as server. - + - Wheel does not affect steering. + Only RPCs from the owner of the object will be allowed to invoke this method. - + - Set steering angle according to and . + Maximum number of calls per-second per-player. - + - Increase or decrease motor torque to rotate vehicle in-place. (Tanks) + Minimum seconds between calls per-player. + Initialized from ratelimitHz when gathering RPCs. - + - For , indicates how a positive motor torque (forward) rotates - the vehicle. + Index into per-connection rate limiting array. - + - Wheels on the left side are Clockwise and wheels on the right side are Counter-Clockwise. + Backwards compatibility for older invoke by name code e.g. plugins. - + - Positive motor torque on this wheel rotates the vehicle clockwise. + If changing header size remember to update PlayerManager and allocPlayerChannelId. - + - Positive motor torque on this wheel rotates the vehicle counter-clockwise. + How far to shift compressed voice data. - + - Controls whether wheel creates particle kickup effects for the ground surface material underneath. + If true, this object is owned by a locally-controlled player. + For example, some code is not run for "remote" players. + Always true in singleplayer. Always false on dedicated server. - + - Turn off motion effects. Default for wheels not using collider pose. + Use on server when invoking client methods on the owning player. - + - Enable motion effects. Default for wheels using collider pose. + Replacement for ESteamCall.NOT_OWNER. - + - Enable motion effects, but turn them off while moving backward. + Don't use this. Originally added so that Rocketmod didn't have to inject into the game's assembly. - + + True if the call succeeded, or false if the sender should be refused. + + - Enable motion effects, but turn them off while moving forward. + Don't use this. Originally added so that Rocketmod didn't have to inject into the game's assembly. - + - [0, 1] color will have zero saturation if random value is less than this. For example, 0.2 means 20% of - vehicles will be grayscale. + Calls array needs rebuilding the next time it is used. + Should be invoked when adding/removing components with RPCs. - + - If true, this configuration was created by . - Otherwise, this configuration was loaded from the vehicle asset file. + Does array of RPCs need to be rebuilt? - + - Transform path relative to Vehicle prefab with WheelCollider component. + Find methods with SteamCall attribute, and gather them into an array. - + - If true, WheelCollider's motorTorque is set according to accelerator input. + Encode byte array of voice data to send. - + - Transform path relative to Vehicle prefab. Animated to match WheelCollider state. + Decode voice parameters from byte array. - + - If true, model is animated according to steering input. - Only kept for backwards compatibility. Prior to wheel configurations, only certain WheelColliders actually - received steering input, while multiple models would appear to steer. For example, the APC's front 4 wheels - appeared to rotate but only the front 2 actually affected physics. + Overrides vehicle physics values in bulk without building asset bundles. - + - If true, model ignores isModelSteered and instead uses WheelCollider.GetWorldPose when simulating or the - replicated state from the server when not simulating. Defaults to false. + If true oxygen is restored while in this volume, otherwise if false oxygen is depleted. - + - If greater than zero, visual-only wheels (without a collider) like the extra wheels of the Snowmobile use - this radius to calculate their rolling speed. + Absolute path to *.log file. - + - If set, visual-only wheels without a collider (like the back wheels of the snowmobile) can copy RPM from - a wheel that does have a collider. Requires modelRadius to also be set. + Responsible for the per-process .log file in the Logs directory. + Kept multiple log files in the past, but now consolidates all information + into a single file named Client.log or Server_{Identifier}.log. - + - If set, wheel model uses this crawler track's speed (average RPM of wheels). Prevents wheel model from - spinning out of sync with overall track. + Should setup of the default *.log file be disabled? - + - Target steering angle is multiplied by this value. For example, can be set to a negative number for - rear-wheel steering. Defaults to 1. + If true, information like IP addresses and login tokens should be censored in vanilla logs. + (public issue #4740) - + - Vertical offset of model from simulated suspension position. + Text to replace with if is enabled. - + - How quickly to interpolate model toward suspension position in meters per second. - If negative, position teleports immediately. + *ATTEMPTS* to replace IPv4 address(es) with . + Should only be called if is enabled. + Case-by-case redaction should be preferred for performance reasons over using this function. This function + is intended for third-party messages (e.g., BattlEye) that we don't have control over. + True if message was modified. - + - Nelson 2024-12-06: Initially implemented as a minimum and maximum percentage of normalized forward velocity, - but think this is more practical. I can't think of why we would use values other than -1, 0, +1 for that, - and if we did we'd probably want some tuning for the angle particles are emitted at. + Get logging to path. - + - If true, wheel should fly off when vehicle explodes. Defaults to true. - Used to simplify destroying vehicles with crawler tracks. + Set path to log to. - + - Default. + Close current log file. - + - Set pitch and volume of a single clip according to engine RPM. + Set handles pivot point according to selection transform. + Doesn't apply if handle is currently being dragged. - + - Offsets a crawler track's material UV offset in sync with wheels rolling. + URL of a 64x64 image shown in the upper-left of the server lobby menu. - + - Scene hierarchy path relative to vehicle root. + URL of a 32x32 image shown in the server list. - + - Index in renderer's materials array. + Short description underneath the server name in the server lobby menu. - + - Indices of wheels to copy RPM from. + Long description in the lower-right of the server lobby menu. - + + + Short description underneath the server name in the server list. + + + + + Documentation: https://docs.smartlydressedgames.com/en/stable/servers/game-server-login-tokens.html + To generate a new token visit: https://steamcommunity.com/dev/managegameservers + + + - How far to travel to offset UV 1x. (1/x) + IP address, DNS name, or a web address (to perform GET request) to advertise. - You can calculate RepeatDistance by selecting an edge parallel to the crawler track and dividing the UV - distance by the physical 3D distance. For example, if the UV length is 2 and the 3D length is 1.5 m then - the texture repeats 1.33 UV/m. + Servers not using Fake IP can specify just a DNS entry. This way if server's IP changes clients can rejoin. + For example, if you own the "example.com" domain you could add an A record "myunturnedserver" pointing at + your game server IP and set that record here "myunturnedserver.example.com". + + Servers using Fake IP are assigned random ports at startup, but can implement a web API endpoint to return + the IP and port. Clients perform a GET request if this string starts with http:// or https://. The returned + text can be an IP address or DNS name with optional query port override. (e.g., "127.0.0.1:27015") + + Documentation: https://docs.smartlydressedgames.com/en/stable/servers/bookmark-host.html - + - UV mainTextureOffset per distance traveled. + If true, the server lobby warns that in-game ping may be higher than shown. - + - Please refer to: + How the server is monetized (if at all). - + - Please refer to: + Used to find overrides in json file. - - - Supports redirects by VehicleRedirectorAsset. - - "Shared Skins" were implemented when there were several asset variants of each vehicle. For example, - Off_Roader_Orange, Off_Roader_Purple, Off_Roader_Green, etc. Each vehicle had their "shared skin" set to - the same ID, and the skin asset had its target ID set to the shared ID. This isn't as necessary after - merging vanilla vehicle variants, but some mods may rely on it, and it needed GUID support now that the - target vehicle might not have a legacy ID. - - - + - Prevents calling getOrLoad redundantly if asset does not exist. + Buttons shown in the server lobby menu. For example: + ` Links + ` [ + ` { + ` Message Visit our website! + ` URL https://smartlydressedgames.com/ + ` } + ` ] - + - Clip.prefab + Whether to enable Valve Anti-Cheat. - + - Vehicle.prefab + Whether to enable BattlEye Anti-Cheat. - - - Nelson 2024-02-28: Prior to the VehicleWheelConfiguration class, most of the wheel configuration was - inferred during InteractableVehicle initialization from the children of the "Tires" and "Wheels" transforms. - Confusingly, "Tires" only contains WheelColliders and "Wheels" only contains the visual models. Rather than - keeping the old behavior in InteractableVehicle alongside the newer more configurable one, we match the old - behavior here to generate an equivalent configuration. - - Note that must be initialized before this is called (by loading model). - - - + - Maximum (negative) velocity to aim for while accelerating backward. + Players with a ping higher than this are kicked. - + - Maximum speed to aim for while accelerating backward. + Players in the pre-join queue we haven't heard from in this past number of seconds are kicked. - + - Maximum velocity to aim for while accelerating forward. + Players in the server we haven't heard from in this past number of seconds are kicked. - + - Maximum speed to aim for while accelerating forward. + If ready-to-connect messages are received more than twice from the same client in less than this many + seconds they will be kicked. - + - Steering angle range at target maximum speed (for the current forward/backward direction). - Reducing steering range at higher speeds keeps the vehicle controlable with digital (non-analog) input. + If bad packets (that *may* be legitimate) are received more than threshold times within this many seconds + of each other, reject the calling connection. - + - Steering angle range at zero speed (idle/parked). - For example, 45 means the wheels connected to steering can rotate ±45 degrees. + If more than this many bad packets (that *may* be legitimate) are received within window seconds of each + other, reject the calling connection. - + - Steering angle rotation change in degrees per second. + If a rate-limited method is called this many times within cooldown window the client will be kicked. + For example a value of 1 means the client will be kicked the first time they call the method off-cooldown. (not recommended) - + + + Only applicable when Fake IP is off. When a client is connecting, if their connection would push the number + of simultaneous connections from the same IP address past this number, they are prevented from joining. + + May be useful to prevent against fake join requests coming from a single source IP. (public issue #5001) + + Defaults to a high value because some regions will have many more clients with the same IPv4 address than + others. For example, due to Carrier-grade NAT (CGNAT). + + + - Added or subtracted from wheel motor torque in mode. + Whether rejections for Max_Clients_With_Same_IP_Address should log to command output. Useful for checking + if the limit is appropriate. - + - When a wheel is in mode and a steering input is applied the - stiffness is multiplied by this factor. This allows the vehicle - to rotate in-place with a lower steering torque, which helps prevent the vehicle from going out of control - while turning and accelerating. + Ordinarily the server should be receiving multiple input packets per second from a client. If more than this + amount of time passes between input packets we flag the client as potentially using a lag switch, and modify + their stats (e.g. reduce player damage) for a corresponding duration. - + - Multiplier for and - while at target maximum speed (for the current forward/backward direction). + Whether fake lag detection should log to command output. False positives are relatively likely when client + framerate hitches (e.g. loading dense region), so this is best used for tuning threshold rather than bans. - + - Torque on Z axis applied according to steering input for bikes and motorcycles. + PvP damage multiplier while under fake lag penalty. - + - If true, leaning force is multiplied by normalized speed to the power of steeringLeaningForceSpeedExponent. - Defaults to false. + Should we kick players after detecting spammed calls to askInput? - + - Refer to steeringLeaningForceShouldScaleWithSpeed. + Should we kick players if they do not submit inputs for a long time? - + - If true, explosion will damage nearby entities and kill passengers. + Should the server automatically shutdown at a configured time? - + - Only used if ShouldExplosionBurnMaterials. Optional. Allows specifying which renderers to burn. + When the server should shutdown if Enable_Scheduled_Shutdown is true. - + - When true the bicycle animation is used and extra speed is stamina powered. - Bad way to implement it. + Broadcast "shutting down for scheduled maintenance" warnings at these intervals. + Format is a list of hours:minutes:seconds, for example to warn only 5 seconds before: + ` Scheduled_Shutdown_Warnings + ` [ + ` 00:00:05 + ` ] + Default starts at 30 minutes and counts down. - + - Can this vehicle ever spawn with a charged battery? - Uses game mode battery stats when true, or overrides by preventing battery spawn when false. + Should the server automatically shutdown when a new version is detected? - + - Battery charge when first spawning in is multiplied by this [0, 1] number. + If Enable_Update_Shutdown is true, we check for updates to this branch of the game. + (Unfortunately the server does not have a way to automatically determine the current beta branch.) - + - Battery decrease per second. + Broadcast "shutting down for update" warnings at these intervals. + Refer to Scheduled_Shutdown_Warnings for an explanation of the format. + Default starts at 3 minutes and counts down. - + - Battery increase per second. + Should vanilla text chat messages always use rich text? + Servers with plugins may want to enable because IMGUI does not fade out rich text. + Kept because plugins might be setting this directly, but it no longer does anything. - + - Battery item given to the player when a specific battery hasn't been manually - installed yet. Defaults to the vanilla car battery (098b13be34a7411db7736b7f866ada69). + Should the EconInfo.json hash be checked by the server? - + - Fuel decrease per second. + Documentation: https://docs.smartlydressedgames.com/en/stable/servers/fake-ip.html - + - Client sends physics simulation results to server. If upward (+Y) speed exceeds this, mark the move invalid. + If greater than zero, vehicles with XZ position outside this threshold are saved in the center of the map. + By default, vehicles outside ±40 km are teleported into the map. + Intended to help with physics issues caused by vehicles far out in space. (public issue #4465) - + - Client sends physics simulation results to server. If downward (-Y) speed exceeds this, mark the move invalid. + Limit max queue timeout duration so that if server encounters an error or doesn't + process the request the client can timeout locally. - + - If distance between client-submitted hit position and vehicle pivot point is too high the hit will be - marked invalid. This multiplies the distance threshold, useful for very fast vehicles. + Longer than server timeout so that ideally more context is logged on the server + rather than just "client disconnected." - + - Vertical first-person view translation. + Percentage [0 to 1] of item spawns to use. + For example, if set to 0.2 and level has 100 item spawns, max 20 items will spawn at a time. - + - Vertical first-person view translation. + How long (in seconds) before an item dropped by a player is despawned. - + - Base damage to players when traveling at 1 m/s. Defaults to 10. + How long (in seconds) before a spawned item is despawned. + (For example, an item nobody wants to pick up.) - + - Base damage to zombies when traveling at 1 m/s. Defaults to 15. + When less than the target amount of items are dropped (determined by Spawn_Chance), a new + item is spawned approximately this often (in seconds). - + - Base damage to animals when traveling at 1 m/s. Defaults to 15. + Percentage [0 to 1] probability of item spawning at max quality. - + - Base damage to objects when traveling at 1 m/s. Defaults to 30. + When an item spawns without max quality, the random quality is scaled by this factor. + For example, 0.5 halves the initial quality. - + - Base damage to trees when traveling at 1 m/s. Defaults to 85. + Percentage [0 to 1] probability of gun spawning with full ammo. - + - If speed multiplied by is less than this, no damage is applied. - Defaults to 3. + When a gun spawns without full ammo, the random amount is scaled by this factor. - + - Multiplier for damage from crashing into things. - Not applicable if is false. - Defaults to 1. + Percentage [0 to 1] probability of magazines spawning with full ammo. - + - To non-explosions. + When a magazine spawns without full ammo, the random amount is scaled by this factor. - + - Mega zombie rocks, zombies, animals. + Percentage [0 to 1] probability of non-magazines spawning with full amount. + (E.g., ammo boxes.) - + - Crashing into stuff. + When a non-magazine spawns without full amount, the random amount is scaled by this factor. + (E.g., ammo boxes.) - + - Can this vehicle be repaired by a seated player? + Original option for disabling item quality. If false, items spawn at 100% quality and + their quality doesn't decrease. For backwards compatibility, the newer per-item-type + durability options are ignored if this is off. - + - Can mobile barricades e.g. bed or sentry guns be placed on this vehicle? + Food-specific replacement for Has_Durability. If true, food spawns at 100% quality. - + - Should capsule colliders be added to seat transforms? - Useful to prevent bikes from leaning into walls. + Water-specific replacement for Has_Durability. If true, water spawns at 100% quality. - + - Can players lock the vehicle to their clan/group? - True by default, but mods want to be able to disable. + Clothing-specific replacement for Has_Durability. If true, clothing spawns at 100% quality. - + - Can players steal the battery? + Weapon-specific replacement for Has_Durability. If true, weapons spawns at 100% quality. - + - Spawn table to drop items from on death. + Fallback used when spawning an item that doesn't fit into one of the other quality/durability settings. + If true, items spawn at 100% quality. - + - Minimum number of items to drop on death. + Clothing-specific replacement for Has_Durability. If false, clothing quality + doesn't decrease when damaged. - + - Maximum number of items to drop on death. + Melee and gun replacement for Has_Durability. If false, weapons quality + doesn't decrease when used. - + - Item ID of compatible tire. + Seconds vehicle can be neglected before it begins taking damage. - + - If greater than zero, torque is applied on the local Z axis multiplied by this factor. - Note that is critical for damping this force. + After vehicle has been neglected for more than Decay_Time seconds it will begin taking this much damage per second. - + - Exponent on the [0, 1] factor representing how aligned the vehicle is with the ground up vector. + Percentage [0 to 1] probability of spawning with a battery. - + - If greater than zero, an acceleration is applied to angular velocity on Z axis toward zero. + Percentage [0 to 1] minimum initial charge if spawning with a battery. - + - Indices of wheels using replicated collider pose (if any). - Null if not configured or no wheels using this feature. - Allows client and server to replicate only the suspension value without other context. + Percentage [0 to 1] maximum initial charge if spawning with a battery. - + - Indices of wheels with motor torque applied (if any). - Used for engine RPM calculation. + Percentage [0 to 1] probability of spawning with a tire per-wheel. - + - If this and UsesEngineRpmAndGears are true, HUD will show RPM and gear number. + How long (in seconds) after vehicle explodes or gets stuck underwater before it despawns. - + - When engine RPM dips below this value shift to the next lower gear if available. + How long (in seconds) a locked vehicle can sit empty in the safezone before it is + automatically unlocked. - + - When engine RPM exceeds this value shift to the next higher gear if available. + Scales the amount of damage taken by vehicles. + For example, 0.5 halves the amount of damage dealt to vehicles. - + - How long after changing gears before throttle is engaged again. + Scales damage to the vehicle when an attached barricade obstructions an explosion. + For example, 0.5 halves the explosion damage when blocked by a barricade. - + - How long between changing gears to allow another automatic gear change. + Scales the amount of damage taken by vehicles from non-"Heavy Weapon" guns. + For example, 2.0 doubles the amount of damage dealt to vehicles by non-"Heavy Weapon" guns. - + - Minimum engine RPM. + Scales the amount of damage taken by vehicles from "Heavy Weapon" guns. + For example, 2.0 doubles the amount of damage dealt to vehicles by "Heavy Weapon" guns. - + - Maximum engine RPM. + Scales the amount of damage taken by vehicles from melee weapons and fists. + For example, 2.0 doubles the amount of damage dealt to vehicles by melee. - + - How quickly RPM can increase in RPM/s. - e.g., 1000 will take 2 seconds to go from 2000 to 4000 RPM. - Defaults to -1 which instantly changes RPM. + Scales the amount of HP restored by melee items like the Blowtorch. + For example, 2.0 doubles the amount of health restored by melee items. - + - How quickly RPM can decrease in RPM/s. - e.g., 1000 will take 2 seconds to go from 4000 to 2000 RPM. - Defaults to -1 which instantly changes RPM. + Maximum number of naturally-spawned vehicles on "Tiny" size levels. - + - Maximum torque (multiplied by output of torque curve). + Maximum number of naturally-spawned vehicles on "Small" size levels. - + - Was a center of mass specified in the .dat? + Maximum number of naturally-spawned vehicles on "Medium" size levels. - + - If hasCenterOfMassOverride, use this value. + Maximum number of naturally-spawned vehicles on "Large" size levels. - + - Multiplier for otherwise not-yet-configurable plane/heli/boat forces. - Nelson 2024-03-06: Required for increasing mass of vehicles without significantly messing with behavior. + Maximum number of naturally-spawned vehicles on "Insane" size levels. - + - If set, override the wheel collider mass with this value. + Vehicles are considered "natural" if they were spawned by the level as opposed to players or vendors. + If less than this many natural vehicles exist in the level, more will be spawned. The minimum of this or + Max_Instances is used. (I.e., if this value is higher than max instances the max instances value is used + instead.) - + - Null if vehicle doesn't support paint color. + Percentage [0 to 1] of zombie spawns to use. + For example, if set to 0.2 and an area has 100 zombie spawns, max 20 zombies will spawn at a time. - + - List of transforms to register with DynamicWaterTransparentSort. + Percentage [0 to 1] chance of zombie dropping an item except when dropping more than one item. - + - Null if vehicle doesn't support paint color. + Percentage [0 to 1] chance of zombie spawning as a crawler. - + - Null if isn't . + Percentage [0 to 1] chance of zombie spawning as a sprinter. - + - Pick a random paint color according to . Null if unsupported or not configured. + Percentage [0 to 1] chance of zombie spawning as a flanker. - - - If true, Vehicle Paint items can be used on this vehicle. - Always false if is false. - - Certain vehicles may support paint colors without also being paintable by players. For example, the creator - of a vehicle may want to use color variants without also allowing players to make it bright pink. - + + + Percentage [0 to 1] chance of zombie spawning as a burner. + - + - Returns reverseGearRatio for negative gears, actual value for valid gear number, otherwise zero. - Exposed for plugin use. + Percentage [0 to 1] chance of zombie spawning as an acid spitter. - + - Get number of reverse gear ratios. - Exposed for plugin use. + Percentage [0 to 1] chance of zombie spawning as an electric boss. - + - Get number of forward gear ratios. - Exposed for plugin use. + Percentage [0 to 1] chance of zombie spawning as a ground-pounding boss. - + - Number of tire visuals to rotate with steering wheel. + Percentage [0 to 1] chance of zombie spawning as a fire-breathing boss. - + - If true then level should convert old terrain. + Percentage [0 to 1] chance of zombie spawning as a ghost. - + - If true, splatmap conversion should use weights as-is. + Percentage [0 to 1] chance of zombie spawning as a Dying Light Volatile (crossover). - + - Material guids converted by legacy asset bundle hash or texture names. + Percentage [0 to 1] chance of zombie spawning as a Dying Light Volatile (crossover). - + - Hash of Trees.dat, or zeroed if any assets were missing locally. - Should only be used if level is configured to, as many mod maps are typically missing assets. + Percentage [0 to 1] chance of zombie spawning as the Elver final boss. - + - Nelson 2025-06-10: replacement for _trees. Enables trees outside the "insane" level bounds. + Percentage [0 to 1] chance of zombie spawning as the Kuwait final boss. - + - Append all trees in the level to results list. + How long (in seconds) before a dead zombie respawns by default. - + - Game does not currently have a way to resave level's Config.json file, so instead we save a text file - indicating that the terrain auto conversion was performed. If there was a bug with auto conversion then - all of the old files are still present and can be re-converted. + How long (in seconds) before a dead zombie respawns during a full moon. - + - Stagger regional visibility across multiple frames. + How long (in seconds) before a dead zombie respawns during a horde beacon. - + - Caches uint16 ID to ID redirects. + Minimum seconds between boss zombie spawns for players doing quests. + Players were abusing the spawns to farm boss tier loot. - + - Manages lifetime and attachment of a mythical effect. Added by . - Was called `MythicLocker` with a paired `MythicLockee` prior to 2024-06-11. + Scales the amount of damage dealt by zombies. + For example, 2.0 doubles the amount of damage from zombie attacks. - + - URL of a 64x64 image shown in the upper-left of the server lobby menu. + Scales the amount of damage taken by zombies. + For example, 0.5 halves the amount of damage dealt to zombies. - + - URL of a 32x32 image shown in the server list. + Scales the amount of damage taken by zombies when attacked from behind. + Only certain weapons quality for this modifier. - + - Short description underneath the server name in the server lobby menu. + Weapon damage multiplier against body, arms, legs. Useful for headshot-only mode. - + - Long description in the lower-right of the server lobby menu. + Scales amount of XP gained for killing a zombie during a horde beacon. - + - Short description underneath the server name in the server list. + Scales amount of XP gained for killing a zombie during the full moon. - + - Documentation: https://docs.smartlydressedgames.com/en/stable/servers/game-server-login-tokens.html - To generate a new token visit: https://steamcommunity.com/dev/managegameservers + Minimum number of loot drops from non-mega non-boss zombies. + Loot_Chance applies if the rolled number of drops between [min, max] is one. - - - IP address, DNS name, or a web address (to perform GET request) to advertise. - - Servers not using Fake IP can specify just a DNS entry. This way if server's IP changes clients can rejoin. - For example, if you own the "example.com" domain you could add an A record "myunturnedserver" pointing at - your game server IP and set that record here "myunturnedserver.example.com". - - Servers using Fake IP are assigned random ports at startup, but can implement a web API endpoint to return - the IP and port. Clients perform a GET request if this string starts with http:// or https://. The returned - text can be an IP address or DNS name with optional query port override. (e.g., "127.0.0.1:27015") - - Documentation: https://docs.smartlydressedgames.com/en/stable/servers/bookmark-host.html - - - + - If true, the server lobby warns that in-game ping may be higher than shown. + Maximum number of loot drops from non-mega non-boss zombies. - + - How the server is monetized (if at all). + Minimum number of loot drops from non-boss mega zombies. + Loot_Chance applies if the rolled number of drops between [min, max] is one. - + - Used to find overrides in json file. + Maximum number of loot drops from non-boss mega zombies. - + - Buttons shown in the server lobby menu. For example: - ` Links - ` [ - ` { - ` Message Visit our website! - ` URL https://smartlydressedgames.com/ - ` } - ` ] + Minimum number of loot drops from boss zombies. + Loot_Chance applies if the rolled number of drops between [min, max] is one. - + - Whether to enable Valve Anti-Cheat. + Maximum number of loot drops from boss zombies. - + - Whether to enable BattlEye Anti-Cheat. + If true, all zombies are a bit slower, making it easier to escape them. - + - Players with a ping higher than this are kicked. + If false, nothing can stun zombies, making combat harder. - + - Players in the pre-join queue we haven't heard from in this past number of seconds are kicked. + If true, only certain weapons and attacks can stun zombie (e.g., backstabs). + Not applicable if Can_Stun is false. - + - Players in the server we haven't heard from in this past number of seconds are kicked. + If true, attacking a zombie uses the weapon's PvP damage values rather than zombie-specific damage. - + - If ready-to-connect messages are received more than twice from the same client in less than this many - seconds they will be kicked. + If true, zombies will attack barricades obstructing their movement. - + - If bad packets (that *may* be legitimate) are received more than threshold times within this many seconds - of each other, reject the calling connection. + If true, zombies will attack structures obstructing their movement. - + - If more than this many bad packets (that *may* be legitimate) are received within window seconds of each - other, reject the calling connection. + If true, zombies will attack vehicles obstructing their movement. - + - If a rate-limited method is called this many times within cooldown window the client will be kicked. - For example a value of 1 means the client will be kicked the first time they call the method off-cooldown. (not recommended) + If true, zombies will attack level objects (e.g., fences) obstructing their movement. - - - Only applicable when Fake IP is off. When a client is connecting, if their connection would push the number - of simultaneous connections from the same IP address past this number, they are prevented from joining. - - May be useful to prevent against fake join requests coming from a single source IP. (public issue #5001) - - Defaults to a high value because some regions will have many more clients with the same IPv4 address than - others. For example, due to Carrier-grade NAT (CGNAT). - + + + If greater than zero, maximum number of items a horde beacon can drop. + Useful to clamp the number of drops when a large number of players participate. + - + - Whether rejections for Max_Clients_With_Same_IP_Address should log to command output. Useful for checking - if the limit is appropriate. + If greater than zero, maximum player count for horde beacon loot scaling. + Useful to clamp the number of drops when a large number of players participate. - + - Ordinarily the server should be receiving multiple input packets per second from a client. If more than this - amount of time passes between input packets we flag the client as potentially using a lag switch, and modify - their stats (e.g. reduce player damage) for a corresponding duration. + Scales total number of horde beacon loot drops, applied before Beacon_Max_Rewards. - + - Whether fake lag detection should log to command output. False positives are relatively likely when client - framerate hitches (e.g. loading dense region), so this is best used for tuning threshold rather than bans. + How long (in seconds) before a dead animal respawns. - + - PvP damage multiplier while under fake lag penalty. + Scales the amount of damage dealt by animals. + For example, 2.0 doubles the amount of damage from animal attacks. - + - Should we kick players after detecting spammed calls to askInput? + Scales the amount of damage taken by animals. + For example, 0.5 halves the amount of damage dealt to animals. - + - Should we kick players if they do not submit inputs for a long time? + Maximum number of animals on "Tiny" size levels. - + - Should the server automatically shutdown at a configured time? + Maximum number of animals on "Small" size levels. - + - When the server should shutdown if Enable_Scheduled_Shutdown is true. + Maximum number of animals on "Medium" size levels. - + - Broadcast "shutting down for scheduled maintenance" warnings at these intervals. - Format is a list of hours:minutes:seconds, for example to warn only 5 seconds before: - ` Scheduled_Shutdown_Warnings - ` [ - ` 00:00:05 - ` ] - Default starts at 30 minutes and counts down. + Maximum number of animals on "Large" size levels. - + - Should the server automatically shutdown when a new version is detected? + Maximum number of animals on "Insane" size levels. - + - If Enable_Update_Shutdown is true, we check for updates to this branch of the game. - (Unfortunately the server does not have a way to automatically determine the current beta branch.) + If true, attacking an animal uses the weapon's PvP damage values rather than animal-specific damage. - + - Broadcast "shutting down for update" warnings at these intervals. - Refer to Scheduled_Shutdown_Warnings for an explanation of the format. - Default starts at 3 minutes and counts down. + How long (in seconds) since the barricade owner/group last played before the barricade won't be saved. + If the server is offline for more than half the Decay_Time, all decay timers are reset. - + - Should vanilla text chat messages always use rich text? - Servers with plugins may want to enable because IMGUI does not fade out rich text. - Kept because plugins might be setting this directly, but it no longer does anything. + Scales the amount of damage taken by "Armor Tier: Low" barricades. + For example, 0.5 halves the amount of damage dealt to barricades. - + - Should the EconInfo.json hash be checked by the server? + Scales the amount of damage taken by "Armor Tier: High" barricades. + For example, 0.5 halves the amount of damage dealt to barricades. - + - Documentation: https://docs.smartlydressedgames.com/en/stable/servers/fake-ip.html + Scales the amount of damage taken by barricades from non-"Heavy Weapon" guns. + For example, 2.0 doubles the amount of damage dealt to barricades by non-"Heavy Weapon" guns. - + - If greater than zero, vehicles with XZ position outside this threshold are saved in the center of the map. - By default, vehicles outside ±40 km are teleported into the map. - Intended to help with physics issues caused by vehicles far out in space. (public issue #4465) + Scales the amount of damage taken by barricades from "Heavy Weapon" guns. + For example, 2.0 doubles the amount of damage dealt to barricades by "Heavy Weapon" guns. - + - Limit max queue timeout duration so that if server encounters an error or doesn't - process the request the client can timeout locally. + Scales the amount of damage taken by barricades from melee weapons and fists. + For example, 2.0 doubles the amount of damage dealt to barricades by melee. - + - Longer than server timeout so that ideally more context is logged on the server - rather than just "client disconnected." + Scales the amount of HP restored by melee items like the Blowtorch. + For example, 2.0 doubles the amount of health restored by melee items. - + - Percentage [0 to 1] of item spawns to use. - For example, if set to 0.2 and level has 100 item spawns, max 20 items will spawn at a time. + Should players be allowed to build on their vehicles? - + - How long (in seconds) before an item dropped by a player is despawned. + Should players be allowed to build traps (e.g. barbed wire) on their vehicles? - + - How long (in seconds) before a spawned item is despawned. - (For example, an item nobody wants to pick up.) + Furthest away from colliders a player can build an item onto their vehicle. - + - When less than the target amount of items are dropped (determined by Spawn_Chance), a new - item is spawned approximately this often (in seconds). + Furthest away from colliders a player can build a trap (e.g. barbed wire) onto their vehicle. - + - Percentage [0 to 1] probability of item spawning at max quality. + How long (in seconds) since the structure owner/group last played before the structure won't be saved. + If the server is offline for more than half the Decay_Time, all decay timers are reset. - + - When an item spawns without max quality, the random quality is scaled by this factor. - For example, 0.5 halves the initial quality. + Scales the amount of damage taken by "Armor Tier: Low" structures. + For example, 0.5 halves the amount of damage dealt to structures. - + - Percentage [0 to 1] probability of gun spawning with full ammo. + Scales the amount of damage taken by "Armor Tier: High" structures. + For example, 0.5 halves the amount of damage dealt to structures. - + - When a gun spawns without full ammo, the random amount is scaled by this factor. + Scales the amount of damage taken by structures from non-"Heavy Weapon" guns. + For example, 2.0 doubles the amount of damage dealt to structures by non-"Heavy Weapon" guns. - + - Percentage [0 to 1] probability of magazines spawning with full ammo. + Scales the amount of damage taken by structures from "Heavy Weapon" guns. + For example, 2.0 doubles the amount of damage dealt to structures by "Heavy Weapon" guns. - + - When a magazine spawns without full ammo, the random amount is scaled by this factor. + Scales the amount of damage taken by structures from melee weapons and fists. + For example, 2.0 doubles the amount of damage dealt to structures by melee. - + - Percentage [0 to 1] probability of non-magazines spawning with full amount. - (E.g., ammo boxes.) + Scales the amount of HP restored by melee items like the Blowtorch. + For example, 2.0 doubles the amount of health restored by melee items. - + - When a non-magazine spawns without full amount, the random amount is scaled by this factor. - (E.g., ammo boxes.) + Amount of health players spawn with. [0 to 100] - + - Original option for disabling item quality. If false, items spawn at 100% quality and - their quality doesn't decrease. For backwards compatibility, the newer per-item-type - durability options are ignored if this is off. + Player must have more than this amount of food to begin regenerating health. - + - Food-specific replacement for Has_Durability. If true, food spawns at 100% quality. + Player must have more than this amount of water to begin regenerating health. - + - Water-specific replacement for Has_Durability. If true, water spawns at 100% quality. + How quickly players health regenerates with sufficient food and water. + Lower values regenerate health faster, higher values regenerate health slower. - + - Clothing-specific replacement for Has_Durability. If true, clothing spawns at 100% quality. + Amount of food players spawn with. [0 to 100] - + - Weapon-specific replacement for Has_Durability. If true, weapons spawns at 100% quality. + How quickly players food meter depletes. + Lower values burn food faster, higher values burn food slower. - + - Fallback used when spawning an item that doesn't fit into one of the other quality/durability settings. - If true, items spawn at 100% quality. + How quickly players starve to death. + Lower values kill the player faster, higher values kill the player slower. - + - Clothing-specific replacement for Has_Durability. If false, clothing quality - doesn't decrease when damaged. + Amount of water players spawn with. [0 to 100] - + - Melee and gun replacement for Has_Durability. If false, weapons quality - doesn't decrease when used. + How quickly players water meter depletes. + Lower values lose water faster, higher values lose water slower. - + - Seconds vehicle can be neglected before it begins taking damage. + How quickly players dehydrate to death. + Lower values kill the player faster, higher values kill the player slower. - + - After vehicle has been neglected for more than Decay_Time seconds it will begin taking this much damage per second. + Amount of immunity players spawn with. [0 to 100] - + - Percentage [0 to 1] probability of spawning with a battery. + When immunity is below this amount it will gradually begin depleting. - + - Percentage [0 to 1] minimum initial charge if spawning with a battery. + How quickly players immunity depletes when below Virus_Infect. + Lower values deplete faster, higher values deplete slower. - + - Percentage [0 to 1] maximum initial charge if spawning with a battery. + How quickly players die at zero immunity. + Lower values kill the player faster, higher values kill the player slower. - + - Percentage [0 to 1] probability of spawning with a tire per-wheel. + How quickly broken legs heal automatically. + Depends on Can_Fix_Legs. + Lower values heal faster, higher values heal slower. - + - How long (in seconds) after vehicle explodes or gets stuck underwater before it despawns. + How frequently players lose health while bleeding. + Lower values kill the player faster, higher values kill the player slower. - + - How long (in seconds) a locked vehicle can sit empty in the safezone before it is - automatically unlocked. + How quickly bleeding heals automatically. + Depends on Can_Stop_Bleeding. + Lower values heal faster, higher values heal slower. - + - Scales the amount of damage taken by vehicles. - For example, 0.5 halves the amount of damage dealt to vehicles. + Scales the amount of damage taken by players. + For example, 0.5 halves the amount of damage dealt to players. - + - Scales damage to the vehicle when an attached barricade obstructions an explosion. - For example, 0.5 halves the explosion damage when blocked by a barricade. + Scales the amount of XP gained from all activities. - + - Scales the amount of damage taken by vehicles from non-"Heavy Weapon" guns. - For example, 2.0 doubles the amount of damage dealt to vehicles by non-"Heavy Weapon" guns. + Scales the radius within zombies and animals will detect the player. - + - Scales the amount of damage taken by vehicles from "Heavy Weapon" guns. - For example, 2.0 doubles the amount of damage dealt to vehicles by "Heavy Weapon" guns. + How close an attack is to a player to be considered aggressive. + For example, when a bullet passes within this distance of a player the shooter is + considered the aggressor. - + - Scales the amount of damage taken by vehicles from melee weapons and fists. - For example, 2.0 doubles the amount of damage dealt to vehicles by melee. + Percentage [0 to 1] of skill levels to retain when killed by another player. - + - Scales the amount of HP restored by melee items like the Blowtorch. - For example, 2.0 doubles the amount of health restored by melee items. + Percentage [0 to 1] of skill levels to retain when killed by the environment (e.g., zombies). - + - Maximum number of naturally-spawned vehicles on "Tiny" size levels. + Number of skill levels to remove when killed by another player. - + - Maximum number of naturally-spawned vehicles on "Small" size levels. + Number of skill levels to remove when killed by the environment (e.g., zombies). - + - Maximum number of naturally-spawned vehicles on "Medium" size levels. + Percentage [0 to 1] of XP to retain when killed by another player. - + - Maximum number of naturally-spawned vehicles on "Large" size levels. + Percentage [0 to 1] of XP to retain when killed by the environment (e.g., zombies). - + - Maximum number of naturally-spawned vehicles on "Insane" size levels. + Percentage [0 to 1] chance to lose each inventory item when killed by another player. + Depends on Lose_Clothes_PvP because losing storage will drop contained items. - + - Vehicles are considered "natural" if they were spawned by the level as opposed to players or vendors. - If less than this many natural vehicles exist in the level, more will be spawned. The minimum of this or - Max_Instances is used. (I.e., if this value is higher than max instances the max instances value is used - instead.) + Percentage [0 to 1] chance to lose each inventory item when killed by the environment (e.g., zombies). + Depends on Lose_Clothes_PvE because losing storage will drop contained items. - + - Percentage [0 to 1] of zombie spawns to use. - For example, if set to 0.2 and an area has 100 zombie spawns, max 20 zombies will spawn at a time. + If true, drop all clothing items when killed by another player. - + - Percentage [0 to 1] chance of zombie dropping an item except when dropping more than one item. + If true, drop all clothing items when killed by the environment (e.g., zombies). - + - Percentage [0 to 1] chance of zombie spawning as a crawler. + If true, drop primary and secondary weapon when killed by another player. - + - Percentage [0 to 1] chance of zombie spawning as a sprinter. + If true, drop primary and secondary weapon when killed by the environment (e.g., zombies). - + - Percentage [0 to 1] chance of zombie spawning as a flanker. + If false, players have no health loss from falling long distances. - + - Percentage [0 to 1] chance of zombie spawning as a burner. + If false, players cannot break their leg when falling long distances. - + - Percentage [0 to 1] chance of zombie spawning as an acid spitter. + If false, broken legs cannot automatically heal themselves after Leg_Regen_Ticks. - + - Percentage [0 to 1] chance of zombie spawning as an electric boss. + If false, damage cannot cause players to bleed. - + - Percentage [0 to 1] chance of zombie spawning as a ground-pounding boss. + If false, bleeding cannot automatically heal itself after Bleed_Regen_Ticks. - + - Percentage [0 to 1] chance of zombie spawning as a fire-breathing boss. + Should all skills default to max level? - + - Percentage [0 to 1] chance of zombie spawning as a ghost. + Should cardio, diving, exercise, and parkour default to max level? - + - Percentage [0 to 1] chance of zombie spawning as a Dying Light Volatile (crossover). + If true, skills related to player's skillset/speciality are half cost. - + - Percentage [0 to 1] chance of zombie spawning as a Dying Light Volatile (crossover). + If true, skills related to player's skillset/speciality cannot lose levels on death. - + - Percentage [0 to 1] chance of zombie spawning as the Elver final boss. + Should guns with Instakill Headshots (snipers) bypass armor? - + - Percentage [0 to 1] chance of zombie spawning as the Kuwait final boss. + Should each character slot have separate savedata? - + - How long (in seconds) before a dead zombie respawns by default. + If true, players will be kicked if their skin color is too similar to one of the level's terrain colors. - + - How long (in seconds) before a dead zombie respawns during a full moon. + Scales how long before interactables like fridges automatically close. - + - How long (in seconds) before a dead zombie respawns during a horde beacon. + Scales how long before sources of fuel in the world are automatically partially refilled. - + - Minimum seconds between boss zombie spawns for players doing quests. - Players were abusing the spawns to farm boss tier loot. + Scales how long before sources of water in the world are automatically partially refilled. - + - Scales the amount of damage dealt by zombies. - For example, 2.0 doubles the amount of damage from zombie attacks. + Scales how long before trees, rocks, and bushes in the world grow back. - + - Scales the amount of damage taken by zombies. - For example, 0.5 halves the amount of damage dealt to zombies. + Scales number of items dropped by resources like trees and rocks. - + - Scales the amount of damage taken by zombies when attacked from behind. - Only certain weapons quality for this modifier. + Scales how long before destructible objects (e.g., fences) automatically repair. - + - Weapon damage multiplier against body, arms, legs. Useful for headshot-only mode. + Should holiday-specific objects be able to drop special items? + For example, whether christmas presents contain guns. - + - Scales amount of XP gained for killing a zombie during a horde beacon. + Should barricades placed on tree stumps prevent the tree from growing back + while the server is running? - + - Scales amount of XP gained for killing a zombie during the full moon. + Minimum number of in-game days between legacy rain events. + Only applicable for backwards compatibility with levels using the legacy weather features. - + - Minimum number of loot drops from non-mega non-boss zombies. - Loot_Chance applies if the rolled number of drops between [min, max] is one. + Maximum number of in-game days between legacy rain events. + Only applicable for backwards compatibility with levels using the legacy weather features. - + - Maximum number of loot drops from non-mega non-boss zombies. + Minimum number of in-game days a legacy rain event lasts. Zero turns off legacy rain. + Only applicable for backwards compatibility with levels using the legacy weather features. - + - Minimum number of loot drops from non-boss mega zombies. - Loot_Chance applies if the rolled number of drops between [min, max] is one. + Maximum number of in-game days a legacy rain event lasts. Zero turns off legacy rain. + Only applicable for backwards compatibility with levels using the legacy weather features. - + - Maximum number of loot drops from non-boss mega zombies. + Minimum number of in-game days between legacy snow events. + Only applicable for backwards compatibility with levels using the legacy weather features. - + - Minimum number of loot drops from boss zombies. - Loot_Chance applies if the rolled number of drops between [min, max] is one. + Maximum number of in-game days between legacy snow events. + Only applicable for backwards compatibility with levels using the legacy weather features. - + - Maximum number of loot drops from boss zombies. + Minimum number of in-game days a legacy snow event lasts. Zero turns off legacy snow. + Only applicable for backwards compatibility with levels using the legacy weather features. - + - If true, all zombies are a bit slower, making it easier to escape them. + Maximum number of in-game days a legacy snow event lasts. Zero turns off legacy snow. + Only applicable for backwards compatibility with levels using the legacy weather features. - + + + Scales number of in-game days between weather events. (Levels using the newer weather + features can have multiple weather types with different frequencies.) If this was + accidentally set to a high value you can use the "/weather 0" command to reschedule + the next weather event. + + Lower values cause more frequent weather, higher values cause less frequent weather. + (Misnomer, sorry!) + + + - If false, nothing can stun zombies, making combat harder. + Scales number of in-game days a weather event lasts. (Levels using the newer weather + features can have multiple weather types with different durations.) + Zero turns off weather entirely. - + - If true, only certain weapons and attacks can stun zombie (e.g., backstabs). - Not applicable if Can_Stun is false. + Minimum number of in-game days between airdrops. Depends on Use_Airdrops. - + - If true, attacking a zombie uses the weapon's PvP damage values rather than zombie-specific damage. + Maximum number of in-game days between airdrops. Depends on Use_Airdrops. - + - If true, zombies will attack barricades obstructing their movement. + How fast (in meters per second) the airdrop plane flies across the level. + Lower values give players more time to react and chase the airplane. - + - If true, zombies will attack structures obstructing their movement. + Amount of upward force applied to the carepackage, resisting gravity. + Higher values require players to wait longer for the carepackage. + (This isn't intuitive, sorry!) - + - If true, zombies will attack vehicles obstructing their movement. + Minimum number of teams needed to start an arena match. - + - If true, zombies will attack level objects (e.g., fences) obstructing their movement. + Base damage per second while standing outside the arena field. - + - If greater than zero, maximum number of items a horde beacon can drop. - Useful to clamp the number of drops when a large number of players participate. + Accumulating additional damage per second while standing outside the arena field. - + - If greater than zero, maximum player count for horde beacon loot scaling. - Useful to clamp the number of drops when a large number of players participate. + How long (in seconds) between match ready and teleporting players into the arena. - + - Scales total number of horde beacon loot drops, applied before Beacon_Max_Rewards. + How long (in seconds) after a winner is announced to wait before restarting. - + - How long (in seconds) before a dead animal respawns. + How long (in seconds) to wait in intermission before starting the next match. - + - Scales the amount of damage dealt by animals. - For example, 2.0 doubles the amount of damage from animal attacks. + How long (in seconds) before first arena circle starts shrinking. - + - Scales the amount of damage taken by animals. - For example, 0.5 halves the amount of damage dealt to animals. + How long (in seconds) after arena circle finishes shrinking to start shrinking again. - + - Maximum number of animals on "Tiny" size levels. + Should airplanes fly over the level dropping carepackages? - + - Maximum number of animals on "Small" size levels. + If true, arena selects multiple smaller circles within the initial circle. + Otherwise, arena cricle shrinks toward its initial center. - + - Maximum number of animals on "Medium" size levels. + How quickly (in meters per second) the arena radius shrinks on "Tiny" size levels. - + - Maximum number of animals on "Large" size levels. + How quickly (in meters per second) the arena radius shrinks on "Small" size levels. - + - Maximum number of animals on "Insane" size levels. + How quickly (in meters per second) the arena radius shrinks on "Medium" size levels. - + - If true, attacking an animal uses the weapon's PvP damage values rather than animal-specific damage. + How quickly (in meters per second) the arena radius shrinks on "Large" size levels. - + - How long (in seconds) since the barricade owner/group last played before the barricade won't be saved. - If the server is offline for more than half the Decay_Time, all decay timers are reset. + How quickly (in meters per second) the arena radius shrinks on "Insane" size levels. - + - Scales the amount of damage taken by "Armor Tier: Low" barricades. - For example, 0.5 halves the amount of damage dealt to barricades. + Percentage [0 to 1] of arena circle radius retained when selecting next smaller circle. + Depends on Arena_Use_Compactor_Pause. - + - Scales the amount of damage taken by "Armor Tier: High" barricades. - For example, 0.5 halves the amount of damage dealt to barricades. + Should ServerTextChatMessenger be allowed to broadcast? - + - Scales the amount of damage taken by barricades from non-"Heavy Weapon" guns. - For example, 2.0 doubles the amount of damage dealt to barricades by non-"Heavy Weapon" guns. + Should ServerTextChatMessenger be allowed to execute commands? - + - Scales the amount of damage taken by barricades from "Heavy Weapon" guns. - For example, 2.0 doubles the amount of damage dealt to barricades by "Heavy Weapon" guns. + Should ClientTextChatMessenger be allowed to broadcast? - + - Scales the amount of damage taken by barricades from melee weapons and fists. - For example, 2.0 doubles the amount of damage dealt to barricades by melee. + Should ClientTextChatMessenger be allowed to execute commands? - + - Scales the amount of HP restored by melee items like the Blowtorch. - For example, 2.0 doubles the amount of health restored by melee items. + Blueprints requiring a repair skill level higher than this cannot be crafted. + Restricts players from repairing higher-tier items. - + - Should players be allowed to build on their vehicles? + Should a hit confirmation be shown when players deal damage? - + - Should players be allowed to build traps (e.g. barbed wire) on their vehicles? + Should a crosshair be visible while holding a gun? - + - Furthest away from colliders a player can build an item onto their vehicle. + Should bullets be affected by gravity and travel time? - + - Furthest away from colliders a player can build a trap (e.g. barbed wire) onto their vehicle. + Should the player have permanent access to a "paper" map of the level even when they + don't have the associated in-game item? - + - How long (in seconds) since the structure owner/group last played before the structure won't be saved. - If the server is offline for more than half the Decay_Time, all decay timers are reset. + Should the player have permanent access to a GPS map of the level even when they + don't have the associated in-game item? - + - Scales the amount of damage taken by "Armor Tier: Low" structures. - For example, 0.5 halves the amount of damage dealt to structures. + Should the player have permanent access to their compass heading HUD even when they + don't have the associated in-game item? - + - Scales the amount of damage taken by "Armor Tier: High" structures. - For example, 0.5 halves the amount of damage dealt to structures. + Should group members and similar info be visible on the in-game map? - + - Scales the amount of damage taken by structures from non-"Heavy Weapon" guns. - For example, 2.0 doubles the amount of damage dealt to structures by non-"Heavy Weapon" guns. + Should group member names be visible through walls? - + - Scales the amount of damage taken by structures from "Heavy Weapon" guns. - For example, 2.0 doubles the amount of damage dealt to structures by "Heavy Weapon" guns. + Should group connections be shown on player list? - + - Scales the amount of damage taken by structures from melee weapons and fists. - For example, 2.0 doubles the amount of damage dealt to structures by melee. + Should Steam clans/groups be enables as in-game groups? - + - Scales the amount of HP restored by melee items like the Blowtorch. - For example, 2.0 doubles the amount of health restored by melee items. + Should players be allowed to create in-game groups and invite members of the server? - + - Amount of health players spawn with. [0 to 100] + If true, allow automatically creating an in-game group for members of your Steam lobby. + Requires Allow_Dynamic_Groups to be enabled as well. - + - Player must have more than this amount of food to begin regenerating health. + Should the third-person camera extend out to the side? + If false, the third-person camera is centered over your character. - + - Player must have more than this amount of water to begin regenerating health. + Should players be allowed to kill themselves from the pause menu? - + - How quickly players health regenerates with sufficient food and water. - Lower values regenerate health faster, higher values regenerate health slower. + Is friendly-fire within groups allowed? - + - Amount of food players spawn with. [0 to 100] + Are sentry guns and beds allowed on vehicles? - + - How quickly players food meter depletes. - Lower values burn food faster, higher values burn food slower. + Should holiday (Halloween and Christmas) content like NPC outfits and decorations be loaded? - + - How quickly players starve to death. - Lower values kill the player faster, higher values kill the player slower. + Can "freeform" barricades be placed in the world? - + - Amount of water players spawn with. [0 to 100] + Can "freeform" barricades be placed on vehicles? - + - How quickly players water meter depletes. - Lower values lose water faster, higher values lose water slower. + If true, aim flinches away from center when damaged. - + - How quickly players dehydrate to death. - Lower values kill the player faster, higher values kill the player slower. + If true, camera will shake near explosions. Can also be toned down client-side in Options menu. - + - Amount of immunity players spawn with. [0 to 100] + If true, crafting blueprints can require nearby workstations. + If false, only the backwards-compatibility "Heat Source" vanilla crafting tag can be required. This + functions identically to the cooking-skill-also-requires-heat behavior from before. - + - When immunity is below this amount it will gradually begin depleting. + If true, client-side options like damage flinch, explosion camera shake, viewmodel bob are ignored. - + - How quickly players immunity depletes when below Virus_Infect. - Lower values deplete faster, higher values deplete slower. + If true, hide viewmodel while aiming a dual-render scope and show a 2D overlay instead. + Useful for backwards compatibility with modded scopes that have a small enough + dual-render surface to zoom-*out* when aiming in. - + - How quickly players die at zero immunity. - Lower values kill the player faster, higher values kill the player slower. + How long (in seconds) before a player can leave the server through the pause menu. - + - How quickly broken legs heal automatically. - Depends on Can_Fix_Legs. - Lower values heal faster, higher values heal slower. + How long (in seconds) after death before a player can respawn. - + - How frequently players lose health while bleeding. - Lower values kill the player faster, higher values kill the player slower. + How long (in seconds) after death before a player can respawn at their bed. - + - How quickly bleeding heals automatically. - Depends on Can_Stop_Bleeding. - Lower values heal faster, higher values heal slower. + How long (in seconds) after a player requests to leave an in-game "dynamic" group + before they are actually removed. Gives group members time to take cover. - + - Scales the amount of damage taken by players. - For example, 0.5 halves the amount of damage dealt to players. + Maximum number of players invitable to an in-game "dynamic" group. + Depends on Allow_Dynamic_Groups. - + - Scales the amount of XP gained from all activities. + Scales velocity added to players by explosion knock-back. - + - Scales the radius within zombies and animals will detect the player. + Scales midair input change in player direction. - + - How close an attack is to a player to be considered aggressive. - For example, when a bullet passes within this distance of a player the shooter is - considered the aggressor. + Scales midair decrease in speed while faster than max walk speed. - + - Percentage [0 to 1] of skill levels to retain when killed by another player. + Scales magnitude of recoil while using first-person perspective. - + - Percentage [0 to 1] of skill levels to retain when killed by the environment (e.g., zombies). + Scales magnitude of recoil while aiming in first-person perspective. - + - Number of skill levels to remove when killed by another player. + Scales magnitude of recoil inversely with zoom level while aiming in first-person perspective. - + - Number of skill levels to remove when killed by the environment (e.g., zombies). + Scales magnitude of recoil while using third-person perspective. - + - Percentage [0 to 1] of XP to retain when killed by another player. + Scales magnitude of bullet inaccuracy while using third-person perspective. - + - Percentage [0 to 1] of XP to retain when killed by the environment (e.g., zombies). + [0 to 1] Scales how much the first-person move up and down while jumping/landing. - + - Percentage [0 to 1] chance to lose each inventory item when killed by another player. - Depends on Lose_Clothes_PvP because losing storage will drop contained items. + [0 to 1] Scales how much the first-person arms move while ADS. - + - Percentage [0 to 1] chance to lose each inventory item when killed by the environment (e.g., zombies). - Depends on Lose_Clothes_PvE because losing storage will drop contained items. + Each generated comment line is prefixed with this string. - + - If true, drop all clothing items when killed by another player. + Format absolute path to newer txt (UnturnedDat) config file. - + - If true, drop all clothing items when killed by the environment (e.g., zombies). + Format absolute path to older json serialized config file. - + - If true, drop primary and secondary weapon when killed by another player. + Config path used for new servers. - + - If true, drop primary and secondary weapon when killed by the environment (e.g., zombies). + Config path used for conversion from Config.json. - + - If false, players have no health loss from falling long distances. + Fill server-related sections of config from dat file. - + - If false, players cannot break their leg when falling long distances. + Fill mode-related sections of config from dat file and gather overrides. + (for servers and singleplayer) - + - If false, broken legs cannot automatically heal themselves after Leg_Regen_Ticks. + Parses dictionary keys according to reflected fields in targetObject. + If overrides is valid, gathers which values were set. (used for mode config) - + - If false, damage cannot cause players to bleed. + Attempt to parse user-supplied value from dat file according to field's reflected type. - + - If false, bleeding cannot automatically heal itself after Bleed_Regen_Ticks. + Attempt to parse user-supplied list from dat file according to field's reflected type. - + - Should all skills default to max level? + WARNING: This is called on a worker thread. + + Add empty dat values (if not yet added), and include code documentation + in their comments prefixed with COMMENT_PREFIX. User-supplied comments are preserved. - + - Should cardio, diving, exercise, and parkour default to max level? + Add empty dat values for every field in category (if not yet added), and include code documentation + in their comments prefixed with COMMENT_PREFIX. User-supplied comments are preserved. + + In categories without easy/normal/hard split (server config), only normalObject is set. - + - If true, skills related to player's skillset/speciality are half cost. + For conversion from json file. Server-only. - + - If true, skills related to player's skillset/speciality cannot lose levels on death. + For conversion from json file. - + - Should guns with Instakill Headshots (snipers) bypass armor? + Set dat values for every field in category that has an override specified. + (Will not add values if not overridden.) - + - Should each character slot have separate savedata? + For conversion from json file. Find fields different from default in the server-related categories. - + - If true, players will be kicked if their skin color is too similar to one of the level's terrain colors. + For conversion from json file. Find fields different from defaults in one of easy/normal/hard mode. - + - Scales how long before interactables like fridges automatically close. + Shows inspect buttons for each item mentioned in purchasable box or bundle's description text. - + - Scales how long before sources of fuel in the world are automatically partially refilled. + Expands upon Unity physics material properties for gameplay features. - + - Scales how long before sources of water in the world are automatically partially refilled. + Originally considered assets for each legacy material with fallback to main material, but the fallback + would mean a failed lookup for every property in the vast majority of cases. - + - Scales how long before trees, rocks, and bushes in the world grow back. + If true, crops can be planted on this material. - + - Scales number of items dropped by resources like trees and rocks. + If true, oil drills can be placed on this material. - + - Scales how long before destructible objects (e.g., fences) automatically repair. + For custom friction mode, multiplies character acceleration. - + - Should holiday-specific objects be able to drop special items? - For example, whether christmas presents contain guns. + For custom friction mode, multiplies character deceleration. - + - Should barricades placed on tree stumps prevent the tree from growing back - while the server is running? + For custom friction mode, multiplies character max speed. - + - Minimum number of in-game days between legacy rain events. - Only applicable for backwards compatibility with levels using the legacy weather features. + Last realtime a request was sent. + Used to rate-limit clientside. - + - Maximum number of in-game days between legacy rain events. - Only applicable for backwards compatibility with levels using the legacy weather features. + Perform rate limiting and update timestamp. + True if we can proceed with request. - + - Minimum number of in-game days a legacy rain event lasts. Zero turns off legacy rain. - Only applicable for backwards compatibility with levels using the legacy weather features. + Do we think the local player is eligible to send request? - + - Maximum number of in-game days a legacy rain event lasts. Zero turns off legacy rain. - Only applicable for backwards compatibility with levels using the legacy weather features. + If player gets too far away from this storage while using it, should we close out? + False by default for trunk storage because player is inside vehicle. + Plugins needed to be able to set this to false for "virtual storage" plugins, + so we default to false and set to true if asset enables it. - + - Minimum number of in-game days between legacy snow events. - Only applicable for backwards compatibility with levels using the legacy weather features. + Was redirected to HolidayUtil but kept for plugin backwards compatibility. + Refer to HolidayUtil for explanation of this weird situation. - + - Maximum number of in-game days between legacy snow events. - Only applicable for backwards compatibility with levels using the legacy weather features. + Was redirected to HolidayUtil but kept for plugin backwards compatibility. + Refer to HolidayUtil for explanation of this weird situation. - + - Minimum number of in-game days a legacy snow event lasts. Zero turns off legacy snow. - Only applicable for backwards compatibility with levels using the legacy weather features. + Other menus can modify DevkitSelectionToolOptions so we need to sync our menu when opened. - + - Maximum number of in-game days a legacy snow event lasts. Zero turns off legacy snow. - Only applicable for backwards compatibility with levels using the legacy weather features. + If set, takes priority over VehicleRedirectorAsset's paint color and over VehicleAsset's default paint color. - - - Scales number of in-game days between weather events. (Levels using the newer weather - features can have multiple weather types with different frequencies.) If this was - accidentally set to a high value you can use the "/weather 0" command to reschedule - the next weather event. - - Lower values cause more frequent weather, higher values cause less frequent weather. - (Misnomer, sorry!) - - - + - Scales number of in-game days a weather event lasts. (Levels using the newer weather - features can have multiple weather types with different durations.) - Zero turns off weather entirely. + Returned asset is not necessarily a vehicle asset yet: It can also be a VehicleRedirectorAsset which the + vehicle spawner requires to properly set paint color. - + - Minimum number of in-game days between airdrops. Depends on Use_Airdrops. + Windows-specific extensions of Windows console input. + Uses the Win32 API to force a console to be created and destroyed. - + - Maximum number of in-game days between airdrops. Depends on Use_Airdrops. + Workshop item does not have any IP restrictions in place. - + - How fast (in meters per second) the airdrop plane flies across the level. - Lower values give players more time to react and chase the airplane. + Workshop item has an IP whitelist, and server IP is not on it. - + - Amount of upward force applied to the carepackage, resisting gravity. - Higher values require players to wait longer for the carepackage. - (This isn't intuitive, sorry!) + Workshop item has an IP blacklist, and server IP is on it. - + - Minimum number of teams needed to start an arena match. + Workshop item does have IP restrictions, and server IP is allowed. - + - Base damage per second while standing outside the arena field. + Workshop item has been banned by an admin. - + - Accumulating additional damage per second while standing outside the arena field. + Workshop item is hidden from everyone. - + - How long (in seconds) between match ready and teleporting players into the arena. + Utilities for testing whether a particular server is allowed to download a workshop item. + Available from client and server side so that clients can help enforce restrictions. - + - How long (in seconds) after a winner is announced to wait before restarting. + Workshop item key-value tag storing IP whitelist and blacklist. - + - How long (in seconds) to wait in intermission before starting the next match. + Get ip restrictions value if set, otherwise null. + Can be called from client or server. - + - How long (in seconds) before first arena circle starts shrinking. + Test whether IP is whitelisted or blacklisted in filter. - + - How long (in seconds) after arena circle finishes shrinking to start shrinking again. + Split x,y-z format into whitelist [x, y] and blacklist [z]. - + - Should airplanes fly over the level dropping carepackages? + Split whitelist-blacklist format and parse string IPs into integer IPs. - + - If true, arena selects multiple smaller circles within the initial circle. - Otherwise, arena cricle shrinks toward its initial center. + Parse CIDR string IPs into integer IPs. - + - How quickly (in meters per second) the arena radius shrinks on "Tiny" size levels. + 2023-04-17: suggestion is to have a hardcoded list of hate speech that gets filtered + regardless of whether profanity filter is enabled. - + - How quickly (in meters per second) the arena radius shrinks on "Small" size levels. + Not using rate limit attribute because this is potentially called for hundreds of barricades at once, + and only admins will actually be allowed to apply the transform. - + - How quickly (in meters per second) the arena radius shrinks on "Medium" size levels. + Only used by plugins. - + - How quickly (in meters per second) the arena radius shrinks on "Large" size levels. + See BarricadeRegion.FindBarricadeByRootFast comment. - + - How quickly (in meters per second) the arena radius shrinks on "Insane" size levels. + For code which does not know whether transform exists and/or even is a barricade. + See BarricadeRegion.FindBarricadeByRootFast comment. - + - Percentage [0 to 1] of arena circle radius retained when selecting next smaller circle. - Depends on Arena_Use_Compactor_Pause. + Does the item being placed count as a "trap" for the purposes of vehicle placement restrictions? - + - Should ServerTextChatMessenger be allowed to broadcast? + Should placement ghost material change be done recursively? + e.g. Sentry has a deep hierarchy of meshes. - + - Should ServerTextChatMessenger be allowed to execute commands? + Internal struct menu uses to sort items in box. - + - Should ClientTextChatMessenger be allowed to broadcast? + Item definition id. - + - Should ClientTextChatMessenger be allowed to execute commands? + Rarity used to sort mythical > legendary > epic > rare. - + - Blueprints requiring a repair skill level higher than this cannot be crafted. - Restricts players from repairing higher-tier items. + [0, 1] calculated chance of this item being unboxed. + Shown to player in item tooltips. - + - Should a hit confirmation be shown when players deal damage? + Sorts box entries from highest to lowest rarity. - + - Should a crosshair be visible while holding a gun? + Format qualityRarities as ##.# + Does not use 'P' format because localized strings unfortunately already had % sign. - + - Should bullets be affected by gravity and travel time? + Items server told us we unboxed, but we wait for the animation to finish before showing. + Typically one, but some newer boxes have bonus items occassionally. - + - Should the player have permanent access to a "paper" map of the level even when they - don't have the associated in-game item? + Is one of the unboxed items mythical rarity? - + - Should the player have permanent access to a GPS map of the level even when they - don't have the associated in-game item? + Items in the box. - + - Should the player have permanent access to their compass heading HUD even when they - don't have the associated in-game item? + Skip unboxing animation. + Initial call rotates to just before the item, next call skips entirely. - + - Should group members and similar info be visible on the in-game map? + Does client know about all the granted items? + If not, either something is bad in the econ config (uh oh!) or client is out of date. - + - Should group member names be visible through walls? + Used by weather assets. - + - Should group connections be shown on player list? + Names of achievements that can be granted by NPC rewards. - + - Should Steam clans/groups be enables as in-game groups? + Name of promo level to additively load. - + - Should players be allowed to create in-game groups and invite members of the server? + UTC when to begin load promo level. - + - If true, allow automatically creating an in-game group for members of your Steam lobby. - Requires Allow_Dynamic_Groups to be enabled as well. + UTC when to stop loading promo level. - + - Should the third-person camera extend out to the side? - If false, the third-person camera is centered over your character. + Folder name of the map when it was in the game. - + - Should players be allowed to kill themselves from the pause menu? + Published steam id for the file after it was moved to the workshop. - + - Is friendly-fire within groups allowed? + Dependencies to subscribe to when subscribing through the in-game menu. + e.g. Hawaii's assets are stored separately on the workshop. - + - Are sentry guns and beds allowed on vehicles? + Only applies if player is not subscribed to the workshop file. + Should an advertisement be shown in the Menu > Singleplayer > Curated list? - + - Should holiday (Halloween and Christmas) content like NPC outfits and decorations be loaded? + Published steam id to subscribe to. - + - Can "freeform" barricades be placed in the world? + If logging in after this point, subscribe. - + - Can "freeform" barricades be placed on vehicles? + If logging in before this point, subscribe. - + - If true, aim flinches away from center when damaged. + Maps not installed by default, but recommended from maps list. - + - If true, camera will shake near explosions. Can also be toned down client-side in Options menu. + Maps to install to automatically. + Used early in startup to hopefully install before reaching main menu. - + - If true, crafting blueprints can require nearby workstations. - If false, only the backwards-compatibility "Heat Source" vanilla crafting tag can be required. This - functions identically to the cooking-skill-also-requires-heat behavior from before. + If set and gun is a Projectile launcher, overrides Projectile prefab. - + - If true, client-side options like damage flinch, explosion camera shake, viewmodel bob are ignored. + Multiplier for explosive projectile damage. - + - If true, hide viewmodel while aiming a dual-render scope and show a 2D overlay instead. - Useful for backwards compatibility with modded scopes that have a small enough - dual-render surface to zoom-*out* when aiming in. + Multiplier for explosive projectile's blast radius. - + - How long (in seconds) before a player can leave the server through the pause menu. + Multiplier for explosive projectile's initial force. - + - How long (in seconds) after death before a player can respawn. + Only applicable if Projectile prefab override is used. + Seconds before physics projectile is destroyed. - + - How long (in seconds) after death before a player can respawn at their bed. + If true, per-surface effects like blood splatter are created. + Defaults to true, but can be disabled particularly if a performance issue (e.g., an + explosive many-pellet shotgun shell). - + - How long (in seconds) after a player requests to leave an in-game "dynamic" group - before they are actually removed. Gives group members time to take cover. + Should amount be filled to capacity when detached? - + - Maximum number of players invitable to an in-game "dynamic" group. - Depends on Allow_Dynamic_Groups. + Set this item as the dragging preview. - + - Scales velocity added to players by explosion knock-back. + Number of alive zombies. - + - Scales midair input change in player direction. + Last time a quest boss was spawned. - + - Scales midair decrease in speed while faster than max walk speed. + Allow another quest to spawn a boss zombie immediately. - + - Scales magnitude of recoil while using first-person perspective. + Kills the boss zombie if nobody is around, if the boss was killed it calls UpdateBoss. - + - Scales magnitude of recoil while aiming in first-person perspective. + Checks for players in the area with quests and spawns boss zombies accordingly. - + - Scales magnitude of recoil inversely with zoom level while aiming in first-person perspective. + Apply shader name redirects until a final name is found, + and then load shader for compatible version of Unity. - + - Scales magnitude of recoil while using third-person perspective. + Apply shader name redirects until a final name is found. + Used to fix renamed shaders loaded from old asset bundles. - + - Scales magnitude of bullet inaccuracy while using third-person perspective. + Names of older shaders mapped to their renamed counterparts. + Used to fix shaders loaded from old asset bundles. - + - [0 to 1] Scales how much the first-person move up and down while jumping/landing. + Component for the tactical laser attachment's red dot. + Resizes itself per-camera to maintain a constant on-screen size. - + - [0 to 1] Scales how much the first-person arms move while ADS. + Used to tune the scale by distance so that far away laser is not quite as comically large. - + - Each generated comment line is prefixed with this string. + Combine two existing 20-byte hashes. - + - Format absolute path to newer txt (UnturnedDat) config file. + Utility to hash a stream of bytes over several frames. - + - Format absolute path to older json serialized config file. + [0, 1] percentage progress through the stream. - + - Config path used for new servers. + Advance 1MB further into the stream. + True if there is more data, false if complete. - + - Config path used for conversion from Config.json. + Get the computed hash after processing stream. - + - Fill server-related sections of config from dat file. + Gets barricades both attached to vehicles and not attached to vehicles. - + - Fill mode-related sections of config from dat file and gather overrides. - (for servers and singleplayer) + Nelson 2025-04-08: thank goodness that this didn't use the temperature system! (For some reason?) Makes it + relatively straightforward to convert campfires and ovens to Crafting Tags, and means vanilla has a test + case for the mod hook, too. (This method tests for CraftingHeatTag in radius.) - + - Parses dictionary keys according to reflected fields in targetObject. - If overrides is valid, gathers which values were set. (used for mode config) + Nelson 2025-06-10: new code should favor Vector2Int. We don't want to introduce further uint8 region usage. - + - Attempt to parse user-supplied value from dat file according to field's reflected type. + If true, spawn effect at player's position (rather than Spawnpoint). - + - Attempt to parse user-supplied list from dat file according to field's reflected type. + If true, only spawn effect on player's machine. (Singleplayer or client.) - + - WARNING: This is called on a worker thread. - - Add empty dat values (if not yet added), and include code documentation - in their comments prefixed with COMMENT_PREFIX. User-supplied comments are preserved. + Should the RPC be called in reliable mode? Unreliable effects might not be received. - + - Add empty dat values for every field in category (if not yet added), and include code documentation - in their comments prefixed with COMMENT_PREFIX. User-supplied comments are preserved. - - In categories without easy/normal/hard split (server config), only normalObject is set. + Applied if greater than zero. Defaults to 128. - + - For conversion from json file. Server-only. + Type the annotated class was generated for. - + - For conversion from json file. + Method the annotated method was generated for. - + - Set dat values for every field in category that has an override specified. - (Will not add values if not overridden.) + Ideally component Awake/Start order should not matter, but Unturned's menu does rely on it. + For most players the default order was fine, but it seems it was not deterministic so it would break for some players? - - - For conversion from json file. Find fields different from default in the server-related categories. - + + + Note: new official code should be using per-method rate limit attribute. + This is kept for backwards compatibility with plugins however. + + Timestamp for server-side rate limiting. + - + - For conversion from json file. Find fields different from defaults in one of easy/normal/hard mode. + Realtime this action was performed. - + - Center mythical effect hook horizontally, but maintain vertical placement. - Lots of hats/masks/glasses have off-center effects intentionally, but community - feedback suggests centering to make effects like circling atoms look better. + Realtime since performedRealtime. - + - Set mesh of all character mesh renderers. - Tries to match renderer index to mesh LOD index. + if(myRateLimit.throttle(1.0)) + return; // less than 1s passed - + - Set material of all character mesh renderers. + These server relay variables redirect the client to another server when the menu opens + similar to how Steam sets the +connect string on game startup. Allows plugin to redirect + player to another server on the same network. - + + If true the server is immediately joined, otherwise show server details beforehand. + + - Hack for previewing the "aura" cosmetic items. + Revive all trees in a specific region. - + - If true, this character is for capturing clothing icons. + Revive trees worldwide. Used between arena rounds. - + - Planar reflection component updates its culling distance and culling mask when this is incremented. + Map creator can specify a constant weather mode. - + - Overrides in-game UI scale setting. + Associates a train vehicle ID with the index of a road path to spawn it on. + The level only spawns the train if this vehicle ID isn't present in the map yet, so every train on the map has to be different. - + - Distance to use terrain shaders before fallback to a baked texture. + Should underwater bubble particles be activated? - + - Higher error reduces vertex density as distance increases. + Should positions underground be clamped above ground? + Underground volumes are used to whitelist valid positions. - + - Added for players who want to see if they can get better performance with a ridiculously low max draw distance. + If true, certain objects redirect to load others in-game. - + - Multiplier for far clip plane distance. - Clamped within [0, 1] range to prevent editing config files for an advantage. + If true, electric objects are always powered, and generators have no effect. - + - Multiplier for draw distance. - Clamped within [0, 1] range to prevent editing config files for an advantage. + Display version in the format "a.b.c.d". - + - Multiplier for draw distance of optional super-low LOD models. - Clamped within [0, 1] range to prevent editing config files for an advantage. + Version string packed into integer. - + - Vehicles outside this distance are not rendered. + Number of custom tips defined in per-level localization file. + Tip keys are read as Tip_# - + - Called after loading graphics settings from disk so that their values can be adjusted. + LevelBatching is currently only enabled if map creator has verified it works properly. - + - If default resolution is zero, try falling back to a higher one. - Used when restoring defaults and validating loaded settings. + Overrides maximum size of textures included in LevelBatching atlas. + When using this, be mindful the combined texture doesn't exceed some reasonable size (~4k?) - + - If true, make the game look as nice as possible. - Note: certain limits are imposed except in singleplayer to prevent this from being exploited. + If true, map creator has verified the clutter option works as-expected. - - If true, include current animation speed modifier. - - - True if an animation was found and started playing. - - + - Velocity is directly set to input velocity. + Can be null if not configured. - + - Velocity is affected by acceleration and deceleration. + Absolute path to the map folder. - + - Properties common to asset and extensions. For example both can specify sounds. + Only used for play menu categories at the moment. - + - Invokes an event a configured number of times. + SHA1 hash of the Level.dat file. - + - If true the event will only be invoked in offline mode and on the server. + Test whether this map's workshop file ID is in the curated maps list. - + - Invoked multiple times. + Web URL to map feedback discussions. - + - Sanity check all returned elements have a gameObject. + If true, this info is out-of-date and may have been renamed or deleted. - + - Create software cursor visual element. + Preview.png should be 320x180 - + - Create green label in the upper-left. + Get a random file path in the /Screenshots folder, or fallback to Level.png if it exists. - + - Create tooltip visual element. + Get a random file path in the /Screenshots folder - + - Update upper-left green text. + Invoked when door is opened/closed, but not when loaded. - + - Update software cursor visual element. + Exposed for Rocket transition to modules backwards compatibility. - + - Find hovered element and update tooltip visibility/text. + Remove structure instance on server and client. - + - Container for SleekWindow element. + Used by ownership change and damaged event to tell relevant clients the new health. - + - Container for top-level visual elements. + Legacy function for UseableStructure. - + - Element under the cursor on the previous frame. + Spawn a new structure and replicate it. - + - Duration in seconds the cursor has been over the element. + Not an instance method because structure might not exist yet, in which case we cancel instantiation. - + - EconInfo.json hash does not match. + Not ideal, but there was a problem because onLevelLoaded was not resetting these after disconnecting. - + - Master bundle hashes do not match. + Maps prefab unique id to inactive list. - + - Workshop usage advertised on server list does not match during connect. + Sending yaw only costs 1 bit (flag) plus yaw bits, so compared to the old 24-bit rotation we may as well + make it high-precision. Quaternion mode uses 1+27 bits! - + - Used by client transport to show a custom localized message. + +0 = StructureDrop + +1 = root transform - + - Server has not received an auth session response from Steam yet. + Multiplier for how quickly deadzones deplete a gasmask's filter quality. + e.g., 2 is faster (2x) and 0.5 is slower. - + - Server has not received an economy response from Steam yet. + Hack for previewing the "aura" cosmetic items. - + - Server has not received a groups response from Steam yet. + Exposed for Rocket transition to modules backwards compatibility. - + - Player nickname exceeds limit. + Exposed for Rocket transition to modules backwards compatibility. - + - Player nickname contains invalid characters. + Ideally in a future rewrite asset overload will become the default rather than the overload taking legacy ID. - + - Player nickname should not be a number. + If true, item has 100% quality. If false, item has a random quality. - + - Server did not respond to EServerMessage.Authenticate + Check volumes matching this ID. - + - Player resources folders don't match. + Compare number of players in volume to this number. - + - The network identity in the ticket does not match the server authenticating the ticket. - This can happen if server's Steam ID has changed from what the client thinks it is. - For example, joining a stale entry in the server list. (public issue #4101) + Invoked after any player's stance changes (not including loading). - + - Level name advertised on server list does not match during connect. + Stance to fit available space when loading in. - + + Distance zombies can detect this player within. + + - VAC status advertised on server list does not match during connect. + Older, cached version of areEyesUnderwater. - + - BattlEye status advertised on server list does not match during connect. + Return false if there are any external restrictions (e.g. reloading, handcuffed) preventing climbing. - + - Max players advertised on server list does not match during connect. + Test whether bottom of controller is currently inside a water volume. - + - Camera mode advertised on server list does not match during connect. + Test whether viewpoint is currently inside a water volume. - + - Combat mode advertised on server list does not match during connect. + Test whether body is currently inside a water volume. + Enters the swimming stance while true. - + - Player's skin color is too similar to one of . + Draw debug capsule matching the player size. - + - Steam ID reported by net transport doesn't match client's reported Steam ID. - This was exploited to fill the server queue with fake players. + Draw standing-height debug capsule matching the player size. - + - Received too many connection requests from player in a short window. + Is there enough height for our capsule at a position? - + - Received too many invalid messages from connection in a short window. + Could a standing player capsule fit at the given position? - + - Same as CUSTOM, but shows the "verify game files" prompt. + Could a crouching player capsule fit at the given position? - + - Server limits how many clients are joining from the same IP address. - (public issue #5001) + Could a prone player capsule fit at the given position? - + - Does this label fade out as the chat message gets older? + Could a standing player capsule teleport to the given position? - + - Chat message values to show. + Is there any compatible stance that can fit at position? - + - Invoked after state is first loaded, synced from server when entering relevancy, or reset. + Using our capsule's current height would there be enough space at a given position? - + - Invoked after interaction changes state. + Does capsule have appropriate clearance for a pending height change? - + - Number of event hooks monitoring or controlling this. - Used to allow client to control remote objects on server. + Replicate stance to clients. - + - Remove items that do not match search text. + Regular interact ray still hits the ladder, but we only allow climbing within a smaller range to make its + teleport less powerful. - + - Note SetListing also calls RefreshInCart. + Ladder forward ray is 0.75m, so we move slightly less than that away from the ladder. - + - Cannot be created until store data is available. + UITK implementation consists of a container element which respects the regular position and size + properties, and a child content element which fits itself in the container. - + - Toggle button to open/close advanced filters panel. + Called during startup and when returning to the main menu. - + - On/off checkbox for including already-owned items in filter. + Result is never null, but may be empty or out-of-date. - + - Container for advanced options. + Allows Unity events to spawn barricades. - + - Displays the current page number. + Finds an existing "{{Cargo/name" (if any), otherwise adds a new one. - + - Only visible when cart is not empty. + Adds a new "{{Cargo/name" even if one already exists. - + - [0, pageCount) + Helper for wiki writers to dump game data into a useful format. - + - If true, listings should be re-filtered when opening the menu. + Tests whether current or recent history contains point. - + - Collections of multiple items. + One second history at 50 tickrate. - + - Discounted items. + When adding or removing entries remember to update NetMessages size and regenerate NetCode! - + - Items marked as new in the Status.json file. + Client requesting workshop files to download. - + - Items marked as featured in the Status.json file. + Client has loaded the level. - + - Implemented by "root" component of each entity type that can provide crafting tags to nearby players. - This allows overlap with a barricade attached to a vehicle to find the barricade from barricade collider and - vehicle from vehicle collider rather than using transform root. Any mod hook extensions to crafting tags will - be sibling components or descendants of this component. + Client providing Steam login token. - + - Asset providing tags. For example, a barricade item. + Client sending BattlEye payload to server. - + - True if GetAvailableTags can ever add any tags. - Used to skip unnecessary line-of-sight tests against (for example) ordinary structures and the like. + Client sent a ping. - + - All tags added by this crafting tag provider. + Client responded to our ping. - + - Rewards to grant when quest is removed without completing. - Not granted when player finishes quest. + Client calling an RPC. - + - Configuration for DedicatedUGC. + Client providing asset GUIDs with their file hashes to check integrity. - + - Published workshop file IDs to download. + Client intends to disconnect. It is fine if server does not receive this message + because players are also removed for transport failure (e.g. timeout) and for expiry + of Steam authentication ticket. This message is useful to know the client instigated + the disconnection rather than an error. - + - Published workshop file IDs whose children (dependencies) should be skipped. - Useful if workshop author lists dependencies as a way of advertising. + Nelson 2024-08-19: This link has been checked with WebUtils.CanParseThirdPartyUrl, but is not the + potentially altered link to go through Steam's link filter. This way the UI shows the original link. - + - Controls SetAllowCachedResponse. Disabled when set to zero. - Balance between item change frequency and allowing cached results when query fails. + Handles VehicleRedirectorAsset (if any) and returns actual vehicle asset (if any). - + - Number of total times to try re-submitting failed workshop queries before aborting. + Handles VehicleRedirectorAsset returning load paint color override (if any) and returns actual vehicle asset (if any). - + - Should items already installed be loaded? + Handles VehicleRedirectorAsset returning spawn paint color override (if any) and returns actual vehicle asset (if any). - + - Should used items be monitored for updates? + Handles VehicleRedirectorAsset (if any) and returns actual vehicle asset (if any). - + - Seconds to wait before shutting down after an update is detected. + Handles VehicleRedirectorAsset returning load paint color override (if any) and returns actual vehicle asset (if any). - + - Message broadcasted when shutdown timer begins. + Handles VehicleRedirectorAsset returning spawn paint color override (if any) and returns actual vehicle asset (if any). - + - Message sent to players when shutdown timer completes. + Handles VehicleRedirectorAsset (if any) and returns actual vehicle asset (if any). - + - Get instance if loaded, but do not load. + Handles VehicleRedirectorAsset returning load paint color override (if any) and returns actual vehicle asset (if any). - + - Get instance, or load if not yet loaded. + Handles VehicleRedirectorAsset returning spawn paint color override (if any) and returns actual vehicle asset (if any). - + - Should only be used by . - For example: "Condition_##" where ## is an index. + Supports redirects by VehicleRedirectorAsset. If redirector's SpawnPaintColor is set, that color is used. - + - Nelson 2025-03-11: not *super* happy about having this in here. Needed for UI_Requirements. + Supports redirects by VehicleRedirectorAsset. If redirector's SpawnPaintColor is set, that color is used. + true if matching vehicle asset was found. (Not necessarily whether vehicle was spawned.) - + - Nelson 2025-03-11: not *super* happy about having this in here. Needed for UI_Requirements. + Kick players maybe trying to impersonate me. I guess nobody else named Nelson is allowed in the game! + 2023-09-19: relaxed this a bit by trimming names and using Equals/Starts/Ends rather than Contains + because there was a player with Nelson in their username. - - - If set, only show this condition in the UI when conditions with these indices are met. - For example don't show "arrest the criminal (name)" until "investigate crime" is completed. - + + Matches handle returned by request, or -1 if cached. - + - Is this condition influenced by a given quest flag? - Used by level objects to determine if local player's flag change may affect visibility. + Nelson 2025-06-19: using server-provided connection details is useful because + it can find its public IP (e.g., joining by LAN and sharing WAN IP), and/or + its fake IP (again when joining by LAN). - + - Replacement for isAssociatedWithFlag to fix quest conditions and somewhat improve perf. + Sorts higher rarity items into the front of the list. - + - Intended to replace filling data from constructor. + Sorts name alphabetically to the front of the list. - + - Intended to replace filling data from constructor. Legacy is for backwards compatibility with Condition_#_Key - format, whereas V2 uses the list and dictionary features. + Sorts type alphabetically to the front of the list. - + - Can be added to gun item game objects (including children) to receive events. + Should zombie(s) of the required type be spawned when player enters the area? - + - Which attachment type to monitor. + How many to spawn if spawning is enabled. - + - Optional. If set, only consider item matching this GUID. I.e., slot is considered empty if attached item - has a different asset GUID. + If greater than zero, find this zombie type configured in the level editor. For example, if the level editor + lists "0 Fire (4)", then 4 is the unique ID, and if assigned to this condition a zombie from the "Fire" + table will spawn. - + - If true, AssetGuidFilter passes when item in slot *doesn't* match GUID. + Navmesh index player must be within. If set to byte.MaxValue then anywhere on the map is eligible. - + - Invoked both when: - 1. Gun is first equipped and an item is already present in the slot. - 2. An item is added to the slot. + Only kills within this radius around the player are tracked. - + - Invoked both when: - 1. Gun is first equipped and the slot is empty. - 2. An item is removed from the slot. + Only kills outside this radius around the player are tracked. + NSTM requested this for a sniping zombies quest. - + - Controls whether events are invoked when asset in slot changes. + If spawning is enabled, whether to use the timer between spawns. - + - Nelson 2025-02-04: Gun attachment slots are currently hard-coded, but if that changes this could be updated - with a "custom" option. + Adds custom data to base physics material asset. + For example how a vanilla material should respond to custom laser guns. - + - If emptiness of slot doesn't change (attachment replaced), do nothing. + If set, audio clip associated with physics material will take priority. - + - In addition to regular Attached and Detached events, if the item asset in the slot changes invoke - Detached then Attached. + Collision with speed lower than this value will not play a sound. - + - State doesn't affect AI collision. + Currently triggers are only used for water. - + - AI collision is blocked when object state is ON. + Invoked after state is first loaded, synced from server when entering relevancy, or reset. - + - AI collision is blocked when object state is OFF. + Invoked after interaction changes state. - + - Controls how rubble affects Nav game object. + Number of event hooks monitoring or controlling this. + Used to allow client to control remote objects on server. - + - Default. Destruction of rubble sections does not affect whether Nav game object is active or not. + Nelson 2023-08-11: this probably should be rewritten a bit if used in the future + because the error context currently assumes this is an item reward for consumables. - + - AI collision is blocked when any sections are alive. Once all sections are dead AI collision is unblocked. + Resolve table as items and grant random number to player. - + - The game uses Process.Start to open web links when the Steam overlay is unavailable, which could be exploited - to e.g. download and execute files. To prevent this we only allow valid http or https urls. + Resolve table as items and grant random number to player. - If true, prefix with https:// if neither http:// or https:// is specified. - + - This version just doesn't return the parsed URL. + Enumerate random number of valid assetIDs. - + - Resolve spawn table asset if set, otherwise find asset by legacy in-editor ID configuration. - Returned asset is not necessarily a vehicle asset yet: It can also be a VehicleRedirectorAsset which the - vehicle spawner requires to properly set paint color. + Run hash algorithm for all data passing through a stream. - + - Used when spawn table asset is not assigned. Pick a random legacy ID using in-editor list of spawns. + If set, find a child meshrenderer with this name and change its material to the character hair material. - + - Multiplier for how quickly deadzones deplete a gasmask's filter quality. - e.g., 2 is faster (2x) and 0.5 is slower. + If set, find a child meshrenderer with this name and change its material to the character beard material. - + - Hack for previewing the "aura" cosmetic items. + Tag display name without rich text formatting. To use, for example, in logging, sorting, or with rich color override. - + - Was redirected to HolidayUtil but kept for plugin backwards compatibility. - Refer to HolidayUtil for explanation of this weird situation. + If true, tag requests name to be displayed in UI with NameColor label color override. - + - Was redirected to HolidayUtil but kept for plugin backwards compatibility. - Refer to HolidayUtil for explanation of this weird situation. + Color to use in UI when displaying name. - + + + If HasNameColor is enabled, this is PlainTextName wrapped with NameColor rich text color tags. + If unset, falls back to PlainTextName. + + Nelson 2025-05-02: initially, we allowed enabling any rich text tags in names. But, considering that we + are also using PlainTextName for other color overrides (e.g. "bad" when missing), this will be disappointing + if tags are displayed inconsistently. + + + - The base transform does not rotate, instead a child transform is created with the pivot in the center. + If true, icon should be tinted according to player's foreground color preference. - + - To work around a uGUI bug we always a sign a texture, even if desiredTexture is null. + Wrap PlainTextName with color rich text tag. - + - Broadcasts after dedicated server name changes. - Command IO interface binds to this rather than having a title-specific method. + Wrap PlainTextName with player's font color preference. - + - Should the default console I/O handler be created? - Plugins can disable on the command line when overriding handler. + If HasNameColor, get RichTextName. Otherwise, get PlainTextNameWithPreferredFontColor. - + - Should the legacy blocking (game thread) console be created? + Get sleek color for UI. If HasNameColor, get NameColor. Otherwise, preferred font color. - + - Log white information. + Velocity is directly set to input velocity. - + - Log yellow warning. + Velocity is affected by acceleration and deceleration. - + - Log red error. + Properties common to asset and extensions. For example both can specify sounds. - + - Print white message to console. + Allows Unity events to execute commands from the server. + Messenger context is logged to help track down abusive assets. - + - Print yellow message to console. + Actual unfiltered text. + Kept because plugins might be referencing, and game should use directly once state byte array is refactored. - + - Print red message to console. + If profanity filter is enabled this filtered text is displayed on the 3D sign and in the note UI. + Null or empty on the dedicated server. - + - Cannot use UnturnedLog here because it may recursively call CommandWindow if another exception is thrown. + Legacy uGUI text on canvas. - + - Called during Unity Update loop. + Legacy uGUI text on canvas. - + - Called during OnApplicationQuit. + App version string packed into a 32-bit number for replication. - + - Helper for plugins that want to replace the default without the shouldCreateDefaultConsole flag. + Path to directory containing "Editor", "Menu", "Player", "Curse_Words.txt", etc files. - + - If true, the player can press Interact [F] when there are no responses - and the "next" dialogue will be opened. + Called clientside by BattlEye when it needs us to send a packet to the server. - + - Each dialogue message is separated into multiple pages. + Event for plugins when BattlEye wants to kick a player. - + - Current page localized text with name_npc and name_char formatted in. + Called serverside by BattlEye when it needs us to send a packet to a player. - + - Seconds elapsed while viewing current page not including pause timer. - Used to gradually show the message text. + Call whenever something impacting rich presence changes for example loading a server or changing lobbies. - + - Seconds to wait before resuming pageAnimationTime counting. + Only used on client. + Information about current game server retrieved through Steam's "A2S" query system. + Available when joining using the Steam server list API (in-game server browser) + or querying the Server's A2S port directly (connect by IP menu), but not when + joining by Steam ID. - + - Appends chars from pageFormattedText according to pageAnimationTime. + On client, is current server protected by VAC? + Set after initial response is received. - + - Rich text formatting tags to close those opened by visible text in animatedTextBuilder. - For example, if animatedTextBuilder includes an opening color=#, this includes the closing color markup. - Required depending on Glazier used. + On client, is current server protected by BattlEye? + Set after initial response is received. - + - Number of chars of pageFormattedText currently visible. + Counts "bad" packets per-connection. Bad packets *may* be legitimate, for example a delayed burst of ping + requests. Beyond a certain point, however, it's likely a cheater is trying to waste server processing time. - + - Added to animation visible chars to skip time on markup. + Exposed for Rocket transition to modules backwards compatibility. - + - Seconds elapsed since responses started becoming visible. - Used to gradually enable responses rather than all at once. + After client submits EServerMessage.Authenticate we are waiting + for the EClientMessage.Accepted response. - + - Animated toward total number of responses to make them gradually visible. + Realtime that client sent EServerMessage.Authenticate request. - + - If true, animation is finished and there is another page to show when Interact [F] is pressed. + File IDs the client thinks the server advertised it was using, or null if UGC response was pending. + Prevents the server from advertising a smaller or fake list of items. - + - If true, text on current page is in the process of gradually appearing. + Needed before loading level. - + - Used by quest UI to return to current dialogue. + Only safe to use serverside. + Get the list of workshop ids that a client needs to download when joining. - + - Update timers and UI for current page index. + Only safe to use serverside. + Lets clients know that this workshop id is being used on the server, and that they need to download it when joining. - + - Called when the player presses Interact [F] in dialogue screen. + Channel id was 32-bits, but now that it is in the RPC header it can be 8-bits since there never that many + players online. The "manager" components are on channel 1, and each player has a channel. - + - Show complete text for the current page and make responses visible. - Called if dialogue animation is disabled, and when the player presses Interact [F] during animation. + Should the network transport layer accept incoming connections? + If both the queue and connected slots are full then incoming connections are ignored. - + - Use "Interact" token from translation file. + includeQueuedPlayers ensures player won't be kicked because someone on the same IP joined after them. - + - If true, description should only be populated with contents from prior to the auto-layout UI changes. + Find player in the queue associated with a client connection. - + - BuildDescription implementations can use this to concatenate longer strings. + Find player associated with a client connection. - + - Which parent to use when attaching an equipped/useable item to the player. + Find net transport layer connection associated with a client steam id. This could be a pending player in the + queue, or a fully connected player. - + - Helper for plugins that want item prefabs server-side. - e.g. Allows item icons to be captured on dedicated server. + Find player steam id associated with connection, otherwise nil if not found. - + - Item name wrapped in color rich text tags according to rarity. + If there's space on the server, asks player at front of queue for their verification to begin playing. - + - Hack for Kuwait aura icons. + Called when determining spawnpoint during player login. - + - Useable subclass. + Is client waiting for response to ESteamPacket.CONNECT request? - + - Can this useable be equipped by players? - True for most items, but allows modders to create sentry-only weapons. + Realtime that client sent ESteamPacket.CONNECT request. - + - Can this useable be equipped while underwater? + Nelson 2023-08-09: adding because in some cases, namely workshop download and level loading, + we can't properly handle client transport failures because these loading systems don't + currently support cancelling partway through. (public issue #4036) - + - Vertical half size of icon camera. - Values less than zero are disabled. + Manages client to server communication. - + - Vertical half size of economy icon camera. + Manages server to client communication. - + - Should the newer automatic placement and orthographic size for axis-aligned icon cameras be used? - Enabled by default, but optionally disabled for manual adjustment. + Connect to server entry point on client. + Requests workshop details for download prior to loading level. + Once workshop is ready launch() is called. - + - Nelson 2025-04-10: adding this for semantics because amount isn't an obvious name. + Callback once client transport is ready to send messages. - + - If true, item should be removed when "amount" reaches zero. - Defaults to true except for magazines. + Callback when something goes wrong and client must disconnect. - + - Which parent to use when attaching an equipped/useable item to the player. + Multiplayer load level entry point on client. + Called once workshop downloads are finished, or we know the server is not using workshop. + Once level is loaded the connect packet is sent to the server. - + - If true, equipable prefab is a child of the left hand rather than the right. - Defaults to false. + Anticipating some hosts will prefer the old format. - + - Whether viewmodel should procedurally animate inertia of equipped item. - Useful for low-quality older animations, but modders may wish to disable for high-quality newer animations. + Remove empty strings, dictionaries, and lists. - + - Defaults to true. If false, the equipped item model is flipped to counteract the flipped character. + Remove generated comments. - + - If true, stats like damage, accuracy, health, etc. are automatically appended to the description. - Defaults to true. + Event for plugins prior to kicking players during shutdown. - + - Nelson 2024-12-11: This can now be null for cosmetic items (). For those items it wasn't - used outside of the main menu 3D item preview, in which case the clothing prefab is typically a better - visualization. + Set on the server when initializing Steam API. + Used to notify pending clients whether VAC is active. + Set on clients after initial response is received. - + - Optional alternative item prefab specifically for the PlayerEquipment prefab spawned. + Set on the server when initializing BattlEye API. + Used to notify pending clients whether BE is active. + Set on clients after initial response is received. - + - Name to use when instantiating item prefab. - By default the asset legacy id is used, but it can be overridden because some - modders rely on the name for Unity's legacy animation component. For example - in Toothy Deerryte's case there were a lot of duplicate animations to work - around the id naming, simplified by overriding name. + Client should call RequestDisconnect instead to ensure all disconnects have a logged reason. - + - Movement speed multiplier while the item is equipped in the hands. + Internet server callback when backend is ready. - + - Sound to play when inspecting the equipped item. + If missing map is a curated map then log information about how to install it. - + - Sound to play when moving or rotating the item in the inventory. + Was not able to find documentation for this unfortunately, + but it seems the max length is 127 characters as of 2022-09-12. - + - When a player dies with this item, should an item drop be spawned? + Set key/value tags on Steam server advertisement so that client can display text in browser. - + - Can player click the drop button on this item? + Set key/value tags on Steam server advertisement so that client can display server config in browser. - + - If this item is compatible with skins for another item, lookup that item's ID instead. + Primarily kept for backwards compatibility with plugins. Some RPCs that reply to sender also use this but + should be tidied up. - + - Defaults to true. If false, skin material and mesh are not applied when is - set. For example, a custom axe can transfer the kill counter and ragdoll effect from a vanilla item's skin - without also transferring the material and mesh. + Hack to deal with the oversight of reordering the ESteamPacket enum during net messaging rewrite causing + older plugins to send wrong packet type. - + - Should friendly-mode sentry guns target a player who has this item equipped? + Send to a connected client. - + - Kept in case any plugins refer to it. - Renamed to shouldFriendlySentryTargetUser. + The server ignores workshop info requests if it's been less than 30 seconds, + so we cache that info for 1 minute in-case we try to connect again right away. - + - Should players be allowed to start primary/secondary use of this item while inside given safezone? - If returns false the primary/secondary inputs are set to false. + This information is needed before the level is loaded. - + - Should this item be deleted when using and quality hits zero? - e.g. final melee hit shatters the weapon. + Advertised server name. e.g., "Nelson's Unturned Server" - + - Should the game destroy all child colliders on the item when requested? - Physics items in the world and on character preview don't request destroy, - but items attached to the character do. Mods might be using colliders - in unexpected ways (e.g., riot shield) so they can disable this default. + Name of map to load. - + - Are there any official skins for this item type? - Skips checking for base textures if item cannot have skins. + Legacy difficulty mode that should be removed eventually. - + - Find useableType by useable name. + Perspective settings. - + - V2 is for newer dat list features. + Server's IP from when we originally received response. + Used to test download restrictions. - + - Legacy is for backwards compatibility with Blueprint_# format. + Last realtime this cache was updated. - + - V2 is for newer dat list features. + Hacked-together initial implementation to refuse network messages from specific players. + On PC some cheats send garbage packets in which case those clients should be blocked. - + - Legacy is for backwards compatibility with Action_# format. + Close connection, and refuse all future connection attempts from a remote player. + Used when garbage messages are received from hacked clients to avoid wasting time on them. - - sortOrder values for description lines. - Difference in value greater than 100 creates an empty line. - - + - Properties common to Gun and Melee. + Record that a bad packet was received from connection and maybe kick them if rate limit is exceeded. - + - Properties common to Barricade and Structure. + Private to prevent plugins from changing the value. - + - Properties common to Gun, Consumable, and Throwable. + Should buffers used by plugin network events be read-only copies? - + - Properties common to Gun and Melee. + First four bytes of RPC messages are the channel id. - + - Properties common to Gun and Melee. + Should players be allowed to join this server regardless of whether their version number matches ours? + Useful to allow players to join debug mode servers. - + - Properties common to Gun and Melee. + Is version number supplied by client compatible with us? - + - Properties common to Gun and Melee. + Notify players waiting to join server if their position in the queue has changed. - + - Remaps asset load requests into a large asset bundle rather than small individual asset bundles. + Prevent any particular client from delaying the server connection queue process. - + - Config that contains the actual large AssetBundle. + Allows hosting providers to limit the configurable max players value from the command-line. - + - Asset path relative to the master AssetBundle. + Deprecated-ish IPv4 to bind listen socket to. Set by bind command. - + - Icon visible when this listing is in the cart. + Local address to bind listen socket to. Set by bind command. - + - "SALE" or "NEW" text visible when applicable. + Steam query port. - + - Tooltip text. + If hosting a server, get the game traffic port. - + - Holds tooltip text + Populated when parsing modeConfigData. Level overrides check whether a property is overridden here before applying. - + - Nelson 2025-01-28: This command reproduces a bug destroying the player gameObject if the vehicle is - destroyed on the same frame as the request to exit. - https://github.com/SmartlyDressedGames/Unturned-3.x-Community/issues/4760#issuecomment-2613090165 + Used to build packet about each existing player for new player, and then once to build a packet + for existing players about the new player. Note that in this second case forPlayer is null + because the packet is re-used. - + - Speaker writes compressed audio to this buffer. - Listener copies network buffer here for decompression. + Not exactly ideal, but this a few old "once per player" client->server RPCs. - + - Listener writes decompressed PCM data to this buffer. + Event for plugins when rejecting a player. - + - Seconds interval to wait between asking recording subsystem for voice data. - Rather than polling every frame we wait until data has accumulated to send. + Notify client that they were kicked. - + - Seconds to wait before playing back newly received data. - Allows a few samples to buffer up so that we don't stutter as more arrive. + Notify client that they were banned. - + - Seconds to wait after playback before stopping audio source. - We zero this portion of the clip to prevent pops. + Player left server by canceling their ticket, or we are disconnecting them without telling them. + Does not send any packets to the disconnecting player. - + - Max calls to askVoice server will allow per second before blocking their voice data. - Prevents spamming many tiny requests bogging down server output. + Number of transport connection failures on this frame. - + - Max compressed bytes server will allow per second before blocking their voice data. - When logging compressed size they averaged 3000-5000 per second, so this affords some wiggle-room. + Callback when a pending player or existing player unexpectedly loses connection at the transport level. - + - Internal value managed by isTalking. + Check whether a server is one of our favorites or not. - + - Is this player broadcasting their voice? - Used in the menus to show an indicator who's talking. - Locally set when recording starts/stops, and remotely when voice data starts/stops being received. + Set whether a server is one of our favorites or not. - + - Broadcasts after isTalking changes. + Open URL in the steam overlay, or if disabled use the default browser instead. + Warning: any third party url should be checked by WebUtils.ParseThirdPartyUrl. - + - Can this player currently hear global (radio) voice chat? + Steam's favorites list requires that we know the server's IPv4 address and port, + so we can't favorite when joining by Steam ID. - + - Is the player wearing an earpiece? - Allows global (radio) voice chat to be heard without equipping the walkie-talkie item. + Toggle whether we've favorited the server we're currently playing on. - + - Is a UseableWalkieTalkie currently equipped? - Set by useable's equip and dequip events. + Toggle whether we've bookmarked the server we're currently playing on. - + - Was the most recent voice data we received sent using walkie talkie? + Ping from client to server, measured in milliseconds. - + - Has voice data recently been received, but we're waiting slightly to begin playback? - Important to give clip a chance to buffer up so that we don't stutter as more samples arrive. + Number of seconds since January 1st, 1970 GMT as reported by backend servers. - + - AudioSource.isPlaying is not trustworthy. + Current UTC as reported by backend servers. + Used by holiday events to keep timing somewhat synced between players. - + - Timer counting down to begin playback of recently received voice data. - We use a timer rather than availableSamples.Count because a very short phrase could be less than threshold. + Has the initial backend realtime been queried yet? + Not available immediately on servers because SteamGameServerUtils cannot be used until the actual Steam instance is available. - + - Timer counting down to end playback. + Invoked after backend realtime becomes available. - + - Accumulated realtime since we last polled data from voice subsystem. + In here because we want to call this very early in startup after initializing provider, + but with plenty of time to hopefully install maps prior to reaching the main menu. - + - Last time askVoiceChat was invoked over network. + This file is of particular importance to the dedicated server because otherwise Steam networking sockets + will say the certificate is for the wrong app. When launching the game outside Steam this sets the app. - + - Number of times askVoiceChat has been called recently, to prevent calling it many times - with tiny durations getting server to relay many packets to clients. + Hackily exposed as an easy way for editor code to check the verison number. - + - Total of recent compressed voice payload lengths. + Has the onApplicationQuitting callback been invoked? - + - Realtime since this recent conversation began. + Moved from OnApplicationQuit when that was deprecated. - + - Only used by plugins. - Called on server to allow plugins to override the default area and walkie-talkie voice channels. + Useful to load files from Steam install of the game while running in the editor. - + - Default culling handler when speaking over walkie-talkie. + Moved from OnApplicationQuit when Application.CancelQuit was deprecated. - + - Default culling handler when speaking in proximity. + A couple of players have reported the PRO_DESYNC kick because their client thinks they own the gold upgrade, + but the Steam backend thinks otherwise. This option is a bit of a hack to work around the problem for them. - + - Called by owner to relay voice data to clients. - Not using rate limit attribute because it internally tracks bytes per second. + If specified, all Steam achievements and stats progress is lost. - + - Called by server to relay voice data from clients. + If specified, all Steam achievements are unlocked during startup. - + - Set to true during OnDestroy to make sure we don't start recording again. + Render character with hair and skin otherwise it might be cyan. + (public issue #3615) - + - If true, SteamUser.StartVoiceRecording has been called without a corresponding call to - SteamUser.StopVoiceRecording yet. + Durstenfeld version of Fisher-Yates shuffle: + https://en.wikipedia.org/wiki/Fisher%E2%80%93Yates_shuffle#The_modern_algorithm - + - If true, voice toggle is in ON mode. + Same as above, but prevent the last clip from being shuffled to the front in order to prevent repeats. - + - Internal value managed by inputWantsToRecord. + Ensures we do not modify the asset in editor. - + - Set by updateInput based on whether voice is enabled, key is held, is alive, etc. - Reset to false during OnDestroy to stop recording. + Matches level with same file name AND workshop file ID. - + - Called during Update on owner client to start/stop recording. + Version before named version constants were introduced. (2023-11-08) - + - Called during Update on owner client to record voice data. + Moved into ServerListFilters. - + - Play walkie-talkie squawk at our position. + Can be added to any GameObject with a Trigger collider. + Ensure that Layer will detect player overlaps. Trap is a good candidate. - + - Start and stop playback of received audio stream. + Called once by Setup. - + - Will this component ever need to record voice data? + Extension method for Thread class. Plugins use this. - + - Will this component ever need to play voice data? - In release builds this is only true for remote clients, but in debug we may want to locally listen. + Throw an exception if current thread is not the game thread. - + - Player's voice audio source cached during Start. + Only on dedicated server: throw an exception if current thread is not the game thread. - + - Looping voice audio clip. + Data in common between list downloaded from a GET request and a ServerListCurationAsset. - + - Playback buffer. + Optional web image path if icon isn't included. - + - Steam does less work on the main thread if we request samples at the native decompresser sample rate, - so the re-sampling can be done on the Unity audio thread instead. + Incremented during server list refresh for each server blocked by this rule. - + - 1 / frequency + Displays a single random item. Placed under the other main menu buttons. - + - Number of samples to zero after writing new audio data. + Optional case-sensitive identifier in list of blueprints. + Added as an alternative to referencing blueprints by index. + Defaults to null. - + - Are any players standing on the mannequin? - Used to prevent exploiting pose switches to push through objects. + Index into Owner's blueprints list. - + - Amount of experience to reward harvesting player. + Operation replaces the special behavior for EBlueprintType.Ammo and EBlueprintType.Repair. - + - If true, harvesting has a chance to provide a second item. + Note: if resolving ref please use GetCategoryTag instead for caching. - + - If true, rain will finish growing the plant. + Category tag replaces the blueprint "Type" which acted as both category AND behaviour modifier. - + - NPC rewards to grant upon harvesting the crop. + Only applicable for operations with a target item. + + Nelson 2025-04-11: initially, this was implemented as the last item in supplies list. However, there are a + lot of checks for special handling of target item, so I think it makes sense to separate. - + - Represents an item the vendor is selling to players. + If not null, these tags must be provided by nearby objects to craft this blueprint. + Note: this is the list as-configured. It has not been filtered according to gameplay config. - + - Refer to NPCItemReward state. + Not shown in the UI. These tags are checked once per-level-startup. + For example, used to check for "singleplayer" tag or a map-specific tag. - + - Represents a vehicle the vendor is selling to players. + If true, and transferState is enabled, delete attached items. - + - Returned asset is not necessarily a vehicle asset yet: It can also be a VehicleRedirectorAsset which the - vehicle spawner requires to properly set paint color. + Must match conditions to craft. - + - If set, takes priority over VehicleRedirectorAsset's paint color and over VehicleAsset's default paint color. + Extra rewards given after crafting. Not displayed. - + - Added during the UI refactor to catch unhandled mouse clicks during drag. + Useful for hiding developer/debug internal blueprints that should not be visible when players search by name. - + - Contains inspect item box and invisible button. + Defaults to false. If true, blueprint can become visible in the crafting list even when NPC conditions + are not met. This should typically only be enabled if all conditions are configured to be visible in the + details panel. Otherwise, the default "conditions unmet" label isn't very informative for players. - + - Added during the UI refactor to catch mouse clicks outside the selection box. + Search output items (excluding target item) for specific item. - + - Annoying frustrating workaround for IMGUI. Disable inventory headers, grids and slots while selection is open - to prevent them from interfering with selection menu. + Unlike format, this returns null if key doesn't exist. - + - Was ConsumeEvent called during this frame? - This is a hack to prevent firing when clicking in the UI on the same frame it closes. - Moved from SleekWindow and Event.current.Use() during UI refactor. + Unlike format, this returns string.Empty if key doesn't exist. - + - Move item drag visual to the cursor's position. + List of all loaded blueprints potentially craftable by player. Updated when assets are refreshed. This + allows us to skip blueprints that will never be craftable (such as level-specific blueprints). - + - Backwards-Compatible Asset Reference with Caching - • Supports both GUID and legacy ID. - • Caches resolved asset and updates if asset has been reloaded. - • Parsing legacy ID without context requires "LegacyType:LegacyID" format. E.g., "Item:4" for the Eaglefire. - • See CachingAssetRef if legacy ID support is unnecessary. + Recycled list of assets with blueprints. - + - If true, doesn't reference anything. - Could also be called "IsZero" or "IsNull". + Subset of loadedBlueprints. - + - Opposite of IsEmpty. + Center column. - + - Assigned GUID, not the referenced asset's GUID. + Used by inventory item context menu to override which blueprints are shown. - + - Assigned legacy ID, not the referenced asset's legacy ID. + Left-hand column. - + - Assigned legacy type, not the referenced asset's legacy type. + Right-hand column. - + - Doesn't only check (Get() == asset) because a new asset may have loaded. - Rather, checks whether GUID or legacy ID (whichever is set) points at asset. - If asset is null, returns true if GUID and legacy ID are zero. + Returns true if all filtered blueprints are craftable. (hacked-in for item action menu) - + - Supports both GUID and legacy ID formats. - - If input string contains ':' the first part is EAssetType and the second part is legacy ID. - - If defaultLegacyType is not None the input string can be parsed as a legacy ID. - - Otherwise, parsed as GUID. + If asset mapping has changed, find all assets with blueprints and gather the ones that can ever be crafted + on this level. (I.e., excluding ones that we shouldn't waste time considering.) - + - Supports both GUID and legacy ID formats. - - If input string contains ':' the first part is EAssetType and the second part is legacy ID. - - Otherwise, parsed as GUID. + Accessible for UseableHousingPlanner. - + - Returns Empty if TryParse returns false. + Get a blank status from the pool or construct a new one. - + - Returns Empty if TryParse returns false. + Creating all these elements is a bit slow, so we only do it once the menu is first opened. - + - Enables assigning assetRef from an existing asset without manually calling constructor. + Exposed for plugins. Can be null. Please do not modify. - + - Enables assigning assetRef from an asset GUID without manually calling constructor. + This overload supports legacy Condition_# format. - + - Enables assigning assetRef from a non-backwards-compatible asset ref without manually calling constructor. + This overload doesn't support legacy Condition_# format. - + - Render character with hair and skin otherwise it might be cyan. - (public issue #3615) + Determines how to handle a server if it matches a rule. - + - If set, audio clip associated with physics material will take priority. + Apply label and continue processing rules. - + - Collision with speed lower than this value will not play a sound. + Show the server in the list. - + - Currently triggers are only used for water. + Hide the server from the list. - + - Sorts higher rarity items into the front of the list. + Note: Port (if set) refers to the Steam query port. - + - Sorts name alphabetically to the front of the list. + If true, negate whether this rule matches. i.e., binary NOT. - + - Sorts type alphabetically to the front of the list. + Incremented during server list refresh for each server blocked by this rule. - + - [0, 1] blends towards one while active regardless of local volume. + Optional image bundled alongside the asset file. - + - [0, 1] blends towards one if current volume bitwise AND with asset is non-zero. + Each quality tier has different rarities. + Legendary: 5% Epic: 20% Rare: 75% - + - Lesser of global or volume blend alphas. + Each item has an equal chance regardless of quality. - + - If blending was not ticket yet then local blend can use global value, e.g. loading into rain storm. + Can be added to any GameObject to receive text chat events. - + - Is blendAlpha at 100%? + Message can be in any chat channel. - + - [0, 1] Rain puddle alpha cutoff. + Message must be in Global channel. - + - [0, 1] Rain puddle ripples alpha. + Message must be in Local channel. - + - Optional parameter for error logging. + Filter to apply to message type. - + - Run hash algorithm for all data passing through a stream. + Sphere radius (squared) around this transform to detect player messages. + e.g. 16 is 4 meters - + - Repurposed from the Modules UI because it was unused. + Substring to search for in message. - - - Full argument string. Defaults to Environment.CommandLine. - - Nelson 2025-06-17: By default, Steam shows a warning nowadays when the game is launched with externally-provided - command-line arguments. For example, when joining a friend via rich presence. The solution is to use the arg - string provided by SteamApps.GetLaunchCommandLine, which also supports *changing* the arguments while the app is - running. If the environment-provided command-line doesn't contain it, the game will append Steam's launch options. - - Note: Steam override isn't applied until Steam is initialized. (after Dedicator and ModuleManager) Please refer to - Setup.cs for the full initialization order. - - - + - Nelson 2025-06-16: Steam doesn't handle "server code" connect URL, but we now support - it for rich presence joins via server code for easier inviting friends to private servers. - - When Steam parses a steam://connect/ip:port URL it requires the query port (e.g. 27015). + Message must start with phrase text. - - - Handles these cases: - key value -> value - key=value -> value - key = value -> value - key = value -> value - key "value with spaces" -> value with spaces - key "value with \" quotation marks" -> value with " quotation marks - - Tested in CommandLineTests.cs - - - + - Is the application running as a headless server? - Replacement for isDedicated property. The property could not be changed to const in dedicated-server-only - builds without potentially breaking plugins. Only development builds can be run as both client or server. + Message must contain phrase text. - + - Are we currently running the standalone dedicated server app? + Message must end with phrase text. - + - Should dedicated server disable requests to internet? - While in LAN mode skips the Steam backend connection and workshop item queries. - Needs a non-Steam networking implementation before it will be truly offline only. + Filter to apply to message text. - + - Hints/messages are the pop-up texts below the interaction prompt, e.g. "reload" or "full moon rises". - Got a complaint that the item placement obstructed hint was shown if placing multiple signs. + Invoked when a player message passes the filters. - + - Adjust screen positioning and visibility of player name widgets to match their world-space counterparts. + Switches between "legacy" (per-level road textures bundle) and "assets" (using RoadAsset). - + - Update hitmarker visibility, and their world-space positions if user enabled that. + Append suffix to name, or if name contains a '.' insert it before. - + - Disable hints and messages if no longer applicable. + Stockpile item definition id with rev-share for the level creators. + Randomly selected from associated items list. - + - Disable vote popup if enough time has passed. + Controls whether vehicle allows barricades to be attached to it. - + - Pause the game if playing singleplayer and menu is open. + Vehicle does not override placement. This means, by default, that barricades can be placed on the vehicle + unless the barricade sets Allow_Placement_On_Vehicle to false. (e.g., beds and sentry guns) Note that + gameplay config Bypass_Buildable_Mobility, if true, takes priority. - + - Many places checked that the cursor and chat were closed to see if a menu could be opened. Moved here to - also consider that useable might have a menu open. + Vehicle allows any barricade to be placed on it, regardless of the barricade's Allow_Placement_On_Vehicle + setting. The legacy option for this was the Supports_Mobile_Buildables flag. Vanilla trains originally + used this option, but it was exploited to move beds into tunnel walls. - + - Calculate damage multiplier for individual bullet. + Vehicle prevents any barricade from being placed on it. Note that gameplay config Bypass_Buildable_Mobility, + if true, takes priority. - + - Each shot has a percentage chance to hit the target. Higher values are more likely to hit. e.g., it - decreases from 1.0 at point blank to 0.0 at the weapon's maximum range. This chance is affected by the - gun's spread. + Scene hierarchy path relative to vehicle root. - + - Contains presetsScrollView which contains customPresetsContainer and defaultPresetsContainer. + Index in renderer's materials array. - + - Contains column buttons and server list itself. + If true, apply to every item in renderer's materials array. - + - Synchronize widgets with their values. + Controls how vehicle's default paint color (if applicable) is chosen. - + - Each level should have a 380x80 Icon.png file. - This class caches them so that the server list can show them quickly. + Not configured. - + - Time.time damage was last dealt so that damage is applied once per second. + Pick from the DefaultPaintColors list. - + - Timer increased while taking damage, and reset to zero while inside zone. + Pick a random HSV using VehicleRandomPaintColorConfiguration. - + - Current position. + Wheel does not affect steering. - + - Exposed for Rocket transition to modules backwards compatibility. + Set steering angle according to and . - + - Is the active level an Arena mode map? + Increase or decrease motor torque to rotate vehicle in-place. (Tanks) - + - Find a new smaller circle within the old circle and clamp it to the playable level area. + For , indicates how a positive motor torque (forward) rotates + the vehicle. - + - Pick a random airdrop node appropriate for the game mode. + Wheels on the left side are Clockwise and wheels on the right side are Counter-Clockwise. - + - Nelson 2025-04-01: default position intBitCount of 13 has range of [-4096, 4096), but on "insane" size maps - the aircraft starts 2 km outside that range. This causes the care package to spawn at the wrong position. - Bumping intBitCount to 14 enables a range of [-8192, 8192). (public issue #4972) + Positive motor torque on this wheel rotates the vehicle clockwise. - + - Seconds between weather event starting and reaching full intensity. + Positive motor torque on this wheel rotates the vehicle counter-clockwise. - + - Seconds between weather event ending and reaching zero intensity. + Controls whether wheel creates particle kickup effects for the ground surface material underneath. - + - Sound clip to play. Volume matches the intensity. + Turn off motion effects. Default for wheels not using collider pose. - + - Component to spawn for additional weather logic. + Enable motion effects. Default for wheels using collider pose. - + - If per-volume mask AND is non zero the weather will blend in. + Enable motion effects, but turn them off while moving backward. - + - Expands upon Unity physics material properties for gameplay features. + Enable motion effects, but turn them off while moving forward. - + - Originally considered assets for each legacy material with fallback to main material, but the fallback - would mean a failed lookup for every property in the vast majority of cases. + [0, 1] color will have zero saturation if random value is less than this. For example, 0.2 means 20% of + vehicles will be grayscale. - + - If true, crops can be planted on this material. + If true, this configuration was created by . + Otherwise, this configuration was loaded from the vehicle asset file. - + - If true, oil drills can be placed on this material. + Transform path relative to Vehicle prefab with WheelCollider component. - + - For custom friction mode, multiplies character acceleration. + If true, WheelCollider's motorTorque is set according to accelerator input. - + - For custom friction mode, multiplies character deceleration. + Transform path relative to Vehicle prefab. Animated to match WheelCollider state. - + - For custom friction mode, multiplies character max speed. + If true, model is animated according to steering input. + Only kept for backwards compatibility. Prior to wheel configurations, only certain WheelColliders actually + received steering input, while multiple models would appear to steer. For example, the APC's front 4 wheels + appeared to rotate but only the front 2 actually affected physics. - + - • Does not support legacy ID. - • Caches resolved asset and updates if asset has been reloaded. - • See CachingBcAssetRef if legacy ID support is necessary. + If true, model ignores isModelSteered and instead uses WheelCollider.GetWorldPose when simulating or the + replicated state from the server when not simulating. Defaults to false. - + - If true, doesn't reference anything. - Could also be called "IsZero" or "IsNull". + If greater than zero, visual-only wheels (without a collider) like the extra wheels of the Snowmobile use + this radius to calculate their rolling speed. - + - Opposite of IsEmpty. + If set, visual-only wheels without a collider (like the back wheels of the snowmobile) can copy RPM from + a wheel that does have a collider. Requires modelRadius to also be set. - + - Assigned GUID, not the referenced asset's GUID. + If set, wheel model uses this crawler track's speed (average RPM of wheels). Prevents wheel model from + spinning out of sync with overall track. - + - Doesn't only check (Get() == asset) because a new asset may have loaded. - Rather, checks whether GUID points at asset. - If asset is null, returns true if GUID and legacy ID are zero. + Target steering angle is multiplied by this value. For example, can be set to a negative number for + rear-wheel steering. Defaults to 1. - + - Returns Empty if TryParse returns false. + Vertical offset of model from simulated suspension position. - + - Enables assigning assetRef from an existing asset without manually calling constructor. + How quickly to interpolate model toward suspension position in meters per second. + If negative, position teleports immediately. - + - Enables assigning assetRef from an asset GUID without manually calling constructor. + Nelson 2024-12-06: Initially implemented as a minimum and maximum percentage of normalized forward velocity, + but think this is more practical. I can't think of why we would use values other than -1, 0, +1 for that, + and if we did we'd probably want some tuning for the angle particles are emitted at. - + - Internal so that CachingBcAssetRef can copy cachedAsset. + If true, wheel should fly off when vehicle explodes. Defaults to true. + Used to simplify destroying vehicles with crawler tracks. - + - Auto-registering list of volume manager subclasses for level editor. + Default. - + - Should calling InstantiateVolume create a new volume? - False for deprecated (landscape hole volume) types. + Set pitch and volume of a single clip according to engine RPM. - + - These are methods moved from the Data class which rely on core types and so cannot go in the UnturnedDat assembly. + Offsets a crawler track's material UV offset in sync with wheels rolling. - + - Intended as a drop-in replacement for existing assets with property uint16s. + Scene hierarchy path relative to vehicle root. - + - Intended as a drop-in replacement for existing assets with legacy IDs. + Index in renderer's materials array. - + - Enables builder pattern for dat edits. - Inclusion of asset type is optional for cases where it's not obvious from context. + Indices of wheels to copy RPM from. - - - Enables builder pattern for dat edits. - Inclusion of asset type is optional for cases where it's not obvious from context. + + + How far to travel to offset UV 1x. (1/x) - Legacy asset references are converted to GUID if the asset is available. If not available, type prefix - is only used if legacy type changed. + You can calculate RepeatDistance by selecting an edge parallel to the crawler track and dividing the UV + distance by the physical 3D distance. For example, if the UV length is 2 and the 3D length is 1.5 m then + the texture repeats 1.33 UV/m. + + + + + UV mainTextureOffset per distance traveled. - + - This overload assumes legacyType has not changed. This will usually be the case. Legacy type would only - change (for example) in cases like spawn tables where they can reference any asset type. + Please refer to: - + - Kept because lots of modders have been using this script in Unity, - so removing legacy effect id would break their content. + Please refer to: - + + + Supports redirects by VehicleRedirectorAsset. + + "Shared Skins" were implemented when there were several asset variants of each vehicle. For example, + Off_Roader_Orange, Off_Roader_Purple, Off_Roader_Green, etc. Each vehicle had their "shared skin" set to + the same ID, and the skin asset had its target ID set to the shared ID. This isn't as necessary after + merging vanilla vehicle variants, but some mods may rely on it, and it needed GUID support now that the + target vehicle might not have a legacy ID. + + + - Active while powered. + Prevents calling getOrLoad redundantly if asset does not exist. - + - This value is confusing because in the level editor it is the normalized radius, but in-game it is the square radius. + Clip.prefab - + - Far clip plane multiplier in-game. + Vehicle.prefab - + + + Nelson 2024-02-28: Prior to the VehicleWheelConfiguration class, most of the wheel configuration was + inferred during InteractableVehicle initialization from the children of the "Tires" and "Wheels" transforms. + Confusingly, "Tires" only contains WheelColliders and "Wheels" only contains the visual models. Rather than + keeping the old behavior in InteractableVehicle alongside the newer more configurable one, we match the old + behavior here to generate an equivalent configuration. + + Note that must be initialized before this is called (by loading model). + + + - Far clip plane multiplier in level editor. + Maximum (negative) velocity to aim for while accelerating backward. - + - Essentially identical to ContentReference, but MasterBundle is more convenient. - Perhaps in the future all asset/content systems will be consolidated. + Maximum speed to aim for while accelerating backward. - + - Are name or path null or empty? + Maximum velocity to aim for while accelerating forward. - + - Are both name and path non-null and non-empty? + Maximum speed to aim for while accelerating forward. - + - Name of master bundle file. + Steering angle range at target maximum speed (for the current forward/backward direction). + Reducing steering range at higher speeds keeps the vehicle controlable with digital (non-analog) input. - + - Path to Unity asset within asset bundle. + Steering angle range at zero speed (idle/parked). + For example, 45 means the wheels connected to steering can rotate ±45 degrees. - + - Find client with given RPC channel ID. + Steering angle rotation change in degrees per second. - + - Workshop item does not have any IP restrictions in place. + Added or subtracted from wheel motor torque in mode. - + - Workshop item has an IP whitelist, and server IP is not on it. + When a wheel is in mode and a steering input is applied the + stiffness is multiplied by this factor. This allows the vehicle + to rotate in-place with a lower steering torque, which helps prevent the vehicle from going out of control + while turning and accelerating. - + - Workshop item has an IP blacklist, and server IP is on it. + Multiplier for and + while at target maximum speed (for the current forward/backward direction). - + - Workshop item does have IP restrictions, and server IP is allowed. + Torque on Z axis applied according to steering input for bikes and motorcycles. - + - Workshop item has been banned by an admin. + If true, leaning force is multiplied by normalized speed to the power of steeringLeaningForceSpeedExponent. + Defaults to false. - + - Workshop item is hidden from everyone. + Refer to steeringLeaningForceShouldScaleWithSpeed. - + - Utilities for testing whether a particular server is allowed to download a workshop item. - Available from client and server side so that clients can help enforce restrictions. + If true, explosion will damage nearby entities and kill passengers. - + - Workshop item key-value tag storing IP whitelist and blacklist. + Only used if ShouldExplosionBurnMaterials. Optional. Allows specifying which renderers to burn. - + - Get ip restrictions value if set, otherwise null. - Can be called from client or server. + When true the bicycle animation is used and extra speed is stamina powered. + Bad way to implement it. - + - Test whether IP is whitelisted or blacklisted in filter. + Can this vehicle ever spawn with a charged battery? + Uses game mode battery stats when true, or overrides by preventing battery spawn when false. - + - Split x,y-z format into whitelist [x, y] and blacklist [z]. + Battery charge when first spawning in is multiplied by this [0, 1] number. - + - Split whitelist-blacklist format and parse string IPs into integer IPs. + Battery decrease per second. - + - Parse CIDR string IPs into integer IPs. + Battery increase per second. - + - Added to player's food value. + Battery item given to the player when a specific battery hasn't been manually + installed yet. Defaults to the vanilla car battery (098b13be34a7411db7736b7f866ada69). - + - Added to player's water value. + Fuel decrease per second. - + - Added to player's virus value. + Client sends physics simulation results to server. If upward (+Y) speed exceeds this, mark the move invalid. - + - Added to player's hallucination value. + Client sends physics simulation results to server. If downward (-Y) speed exceeds this, mark the move invalid. - + - Get animal or player damage based on game mode config. + If distance between client-submitted hit position and vehicle pivot point is too high the hit will be + marked invalid. This multiplies the distance threshold, useful for very fast vehicles. - + - Get zombie or player damage based on game mode config. + Vertical first-person view translation. - + - Should player/animal/zombie surface be nulled on hit? - Requested by spyjack for a chainsaw-style shield that was overboard with the blood. + Vertical first-person view translation. - + - Should this weapon bypass the DamageTool.allowedToDamagePlayer test? - Used by weapons that heal players in PvE. + Base damage to players when traveling at 1 m/s. Defaults to 10. - + - Please refer to ItemWeaponAsset.BuildDescription for an explanation of why this is necessary. + Base damage to zombies when traveling at 1 m/s. Defaults to 15. - + - Please refer to ItemWeaponAsset.BuildDescription for an explanation of why this is necessary. + Base damage to animals when traveling at 1 m/s. Defaults to 15. - - - Utility for getting local hardware ID. - - One option for future improvement would be using Windows Management Infrastructure (WMI) API: - https://github.com/SmartlyDressedGames/Unturned-3.x/issues/1593 - - - + - Maximum number of HWIDs before server will reject connection request. + Base damage to objects when traveling at 1 m/s. Defaults to 30. - + - Get the local hardware ID(s). + Base damage to trees when traveling at 1 m/s. Defaults to 85. - + - Nelson 2025-05-28: keeping this a struct to simplify memory management (no pool needed). If making this more - generic in the future we probably do need to make it a class. + If speed multiplied by is less than this, no damage is applied. + Defaults to 3. - + - Only applicable to barricades. + Multiplier for damage from crashing into things. + Not applicable if is false. + Defaults to 1. - + - Preliminary sort order is provided by server, but this takes priority if camera is available. + To non-explosions. - + - Not ideal, but there was a problem because onLevelLoaded was not resetting these after disconnecting. + Mega zombie rocks, zombies, animals. - + - Instantiate at least this many items per frame even if we exceed our time budget. + Crashing into stuff. - + - Called once key/values can be set. + Can this vehicle be repaired by a seated player? - + - Lod group will be culled when screen size is smaller than this value. + Can mobile barricades e.g. bed or sentry guns be placed on this vehicle? - + - Clamp the culling screen percentage to be less than or equal to a maximum value. + Should capsule colliders be added to seat transforms? + Useful to prevent bikes from leaning into walls. - + - Prevent the lowest LOD from being culled. + Can players lock the vehicle to their clan/group? + True by default, but mods want to be able to disable. - + - Multiplier to incoming damage. Defaults to 1.0. + Can players steal the battery? - + - Multiplier to explosive damage. Defaults to value if Armor_Explosion isn't specified. + Spawn table to drop items from on death. - + - Armor against falling damage. Defaults to 1.0, i.e., take the normal amount of damage. + Minimum number of items to drop on death. - + - If true on any worn clothing item, bones never break when falling. - Defaults to false. + Maximum number of items to drop on death. - + - Left-handed character skeleton is mirrored, so most item models are mirrored again to preserve appearance. - Unfortunately this does not work well for some items e.g. the particle system on Elver/Dango glasses. + Item ID of compatible tire. - + - Sound to play when equipped. + If greater than zero, torque is applied on the local Z axis multiplied by this factor. + Note that is critical for damping this force. - + - If set, find a child meshrenderer with this name and change its material to the character skin material. + Exponent on the [0, 1] factor representing how aligned the vehicle is with the ground up vector. - + - The player can be wearing both a "real" in-game item and a cosmetic item in the same clothing slot. - If true, the real item is shown rather than the cosmetic item. For example, night vision goggles - are shown over any glasses cosmetic because of their gameplay-related green glow. + If greater than zero, an acceleration is applied to angular velocity on Z axis toward zero. - + - Overrides value of TakesPriorityOverCosmetic if is true. + Indices of wheels using replicated collider pose (if any). + Null if not configured or no wheels using this feature. + Allows client and server to replicate only the suspension value without other context. - + - If true, the value of is used rather than . - Defaults to false. True if is set. + Indices of wheels with motor torque applied (if any). + Used for engine RPM calculation. - + - For 3D clothes. Ideally, this wouldn't be type specific, but we have a separate prefab property for each - type of clothing at the moment. + If false, only grounded wheels are included when calculating wheel RPM. - + - The player can be wearing both a "real" in-game item and a cosmetic item in the same clothing slot. - This is called on the real item if has not been set. - If true, the real item is shown rather than the cosmetic item. If false, the cosmetic item can be seen. + If this and UsesEngineRpmAndGears are true, HUD will show RPM and gear number. - + - Durstenfeld version of Fisher-Yates shuffle: - https://en.wikipedia.org/wiki/Fisher%E2%80%93Yates_shuffle#The_modern_algorithm + When engine RPM dips below this value shift to the next lower gear if available. - + - Same as above, but prevent the last clip from being shuffled to the front in order to prevent repeats. + When engine RPM exceeds this value shift to the next higher gear if available. - + - Ensures we do not modify the asset in editor. + How long after changing gears before throttle is engaged again. - + - Optional case-sensitive identifier in list of blueprints. - Added as an alternative to referencing blueprints by index. - Defaults to null. + How long between changing gears to allow another automatic gear change. - + - Index into Owner's blueprints list. + If true, engine can skip from (for example) 1st to 3rd gear if it keeps RPM within + the acceptable range. - + - Operation replaces the special behavior for EBlueprintType.Ammo and EBlueprintType.Repair. + Minimum engine RPM. - + - Note: if resolving ref please use GetCategoryTag instead for caching. + Maximum engine RPM. - + - Category tag replaces the blueprint "Type" which acted as both category AND behaviour modifier. + How quickly RPM can increase in RPM/s. + e.g., 1000 will take 2 seconds to go from 2000 to 4000 RPM. + Defaults to -1 which instantly changes RPM. - + - Only applicable for operations with a target item. - - Nelson 2025-04-11: initially, this was implemented as the last item in supplies list. However, there are a - lot of checks for special handling of target item, so I think it makes sense to separate. + How quickly RPM can decrease in RPM/s. + e.g., 1000 will take 2 seconds to go from 4000 to 2000 RPM. + Defaults to -1 which instantly changes RPM. - + - If not null, these tags must be provided by nearby objects to craft this blueprint. - Note: this is the list as-configured. It has not been filtered according to gameplay config. + Maximum torque (multiplied by output of torque curve). - + - If true, and transferState is enabled, delete attached items. + If true, wheel RPM is reduced according to the difference between expected and actual + wheel RPM divided by torque reduction threshold. - + - Must match conditions to craft. + If torque reduction is enabled, torque is reduced to zero when difference between + expected and actual RPM is greater than this threshold. - + - Extra rewards given after crafting. Not displayed. + If true, prevent changing gears when the difference between expected and actual + wheel RPM exceeds threshold. - + + - 2023-05-27: requested by Renaxon because some Arid blueprints are debug-only and - should not be visible when players search by name. (the 3.23.7.0 update made - non-craftable blueprints searchable for Buak) + If prevent shifting is enabled, prevent changing gears up when the difference between + expected and actual wheel RPM is greater than this threshold. + I.e., if (expected - actual > max) it cannot shift up. - + + - Defaults to false. If true, blueprint can become visible in the crafting list even when NPC conditions - are not met. This should typically only be enabled if all conditions are configured to be visible in the - details panel. Otherwise, the default "conditions unmet" label isn't very informative for players. + If prevent shifting is enabled, prevent changing gears down when the difference between + expected and actual wheel RPM is greater than this threshold. + I.e., if (expected - actual > max) it cannot shift down. - + - Search output items (excluding target item) for specific item. + Was a center of mass specified in the .dat? - + - App version string packed into a 32-bit number for replication. + If hasCenterOfMassOverride, use this value. - + - Path to directory containing "Editor", "Menu", "Player", "Curse_Words.txt", etc files. + Multiplier for otherwise not-yet-configurable plane/heli/boat forces. + Nelson 2024-03-06: Required for increasing mass of vehicles without significantly messing with behavior. - + - Called clientside by BattlEye when it needs us to send a packet to the server. + If set, override the wheel collider mass with this value. - + - Event for plugins when BattlEye wants to kick a player. + Null if vehicle doesn't support paint color. - + - Called serverside by BattlEye when it needs us to send a packet to a player. + List of transforms to register with DynamicWaterTransparentSort. - + - Call whenever something impacting rich presence changes for example loading a server or changing lobbies. + Null if vehicle doesn't support paint color. - + - Only used on client. - Information about current game server retrieved through Steam's "A2S" query system. - Available when joining using the Steam server list API (in-game server browser) - or querying the Server's A2S port directly (connect by IP menu), but not when - joining by Steam ID. + Null if isn't . - + - On client, is current server protected by VAC? - Set after initial response is received. + Pick a random paint color according to . Null if unsupported or not configured. - + + + If true, Vehicle Paint items can be used on this vehicle. + Always false if is false. + + Certain vehicles may support paint colors without also being paintable by players. For example, the creator + of a vehicle may want to use color variants without also allowing players to make it bright pink. + + + - On client, is current server protected by BattlEye? - Set after initial response is received. + Returns reverseGearRatio for negative gears, actual value for valid gear number, otherwise zero. + Exposed for plugin use. - + - Counts "bad" packets per-connection. Bad packets *may* be legitimate, for example a delayed burst of ping - requests. Beyond a certain point, however, it's likely a cheater is trying to waste server processing time. + Get number of reverse gear ratios. + Exposed for plugin use. - + - Exposed for Rocket transition to modules backwards compatibility. + Get number of forward gear ratios. + Exposed for plugin use. - + - After client submits EServerMessage.Authenticate we are waiting - for the EClientMessage.Accepted response. + Number of tire visuals to rotate with steering wheel. - + - Realtime that client sent EServerMessage.Authenticate request. + This value is confusing because in the level editor it is the normalized radius, but in-game it is the square radius. - + - File IDs the client thinks the server advertised it was using, or null if UGC response was pending. - Prevents the server from advertising a smaller or fake list of items. + Kept because lots of modders have been using this script in Unity, + so removing legacy effect id would break their content. - + - Needed before loading level. + Hack for modders using grenade component as a way to deal radial damage. Not a good long term solution but + widely requested for the meantime until I get the chance to rewrite some of the health stuff. - + - Only safe to use serverside. - Get the list of workshop ids that a client needs to download when joining. + State doesn't affect AI collision. - + - Only safe to use serverside. - Lets clients know that this workshop id is being used on the server, and that they need to download it when joining. + AI collision is blocked when object state is ON. - + - Channel id was 32-bits, but now that it is in the RPC header it can be 8-bits since there never that many - players online. The "manager" components are on channel 1, and each player has a channel. + AI collision is blocked when object state is OFF. - + - Should the network transport layer accept incoming connections? - If both the queue and connected slots are full then incoming connections are ignored. + Controls how rubble affects Nav game object. - + - includeQueuedPlayers ensures player won't be kicked because someone on the same IP joined after them. + Default. Destruction of rubble sections does not affect whether Nav game object is active or not. - + - Find player in the queue associated with a client connection. + AI collision is blocked when any sections are alive. Once all sections are dead AI collision is unblocked. - + - Find player associated with a client connection. + Null if not bookmarked. - + - Find net transport layer connection associated with a client steam id. This could be a pending player in the - queue, or a fully connected player. + DNS entry to use if adding a bookmark for this server. - + - Find player steam id associated with connection, otherwise nil if not found. + Adjusts width and spacing of buttons along the bottom of the screen. + Favorite and bookmark buttons can be hidden depending whether the necessary server details are set. - + - If there's space on the server, asks player at front of queue for their verification to begin playing. + True if rubble is not applicable or all sections are alive. - + - Called when determining spawnpoint during player login. + Restricts which items can be crafted. - + - Is client waiting for response to ESteamPacket.CONNECT request? + Restrict blueprints that consume these items. - + - Realtime that client sent ESteamPacket.CONNECT request. + Restrict blueprints that generate these items. - + - Nelson 2023-08-09: adding because in some cases, namely workshop download and level loading, - we can't properly handle client transport failures because these loading systems don't - currently support cancelling partway through. (public issue #4036) + If false, blueprints on vanilla/core/built-in items are not allowed. Defaults to true. - + - Manages client to server communication. + If null, use index instead. - + - Manages server to client communication. + Restrict specific blueprints. - + - Connect to server entry point on client. - Requests workshop details for download prior to loading level. - Once workshop is ready launch() is called. + Interactable storage barricade to spawn at the drop position. - + - Callback once client transport is ready to send messages. + Prefab to spawn falling from the aircraft. - + - Callback when something goes wrong and client must disconnect. + Does this label fade out as the chat message gets older? - + - Multiplayer load level entry point on client. - Called once workshop downloads are finished, or we know the server is not using workshop. - Once level is loaded the connect packet is sent to the server. + Chat message values to show. - + - Anticipating some hosts will prefer the old format. + Kept because lots of modders have been these scripts in Unity, + so removing legacy effect id would break their content. + Note: unsure about this one because it is private and not serialized. - + - Remove empty strings, dictionaries, and lists. + Nelson 2025-05-13: replacing the "workshop request log" which used transport connection hash code with this + more recent IP address and Steam ID rate limiter. - + - Remove generated comments. + Can be added to any GameObject with a Dropper, Note, or Quest interactable object in its parents. - + - Event for plugins prior to kicking players during shutdown. + Invoked on authority when interactable object is used successfully. + Only invoked on clients if ShouldReplicate is true. - + - Set on the server when initializing Steam API. - Used to notify pending clients whether VAC is active. - Set on clients after initial response is received. + If true, the server will replicate the OnUsed event to clients as well. - + - Set on the server when initializing BattlEye API. - Used to notify pending clients whether BE is active. - Set on clients after initial response is received. + If ShouldReplicate is enabled, should the RPC be called in reliable mode? + Unreliable might not be received by clients. - + - Client should call RequestDisconnect instead to ensure all disconnects have a logged reason. + Applied if greater than zero. Defaults to 128. - + - Internet server callback when backend is ready. + True once per frame, false otherwise. - + - If missing map is a curated map then log information about how to install it. + Helper for drawing label outline/shadow so that we can easily change it. - + - Was not able to find documentation for this unfortunately, - but it seems the max length is 127 characters as of 2022-09-12. + Helper for drawing label outline/shadow so that we can easily change it. - + - Set key/value tags on Steam server advertisement so that client can display text in browser. + Payload for the DamageTool.damageAnimal function. - + - Set key/value tags on Steam server advertisement so that client can display server config in browser. + Should game mode config damage multiplier be factored in? - + - Primarily kept for backwards compatibility with plugins. Some RPCs that reply to sender also use this but - should be tidied up. + If not null and damage is applied, is called with this position. - + - Hack to deal with the oversight of reordering the ESteamPacket enum during net messaging rewrite causing - older plugins to send wrong packet type. + Object responsible for creating this AnimalDamageParameters. + However, can be null if calling code didn't assign one. + Example types as of 2025-10-30: + - Kill Volume + - Bumper (vehicle impact) + - Interactable Sentry + - Interactable Trap + - Barrier (legacy per-object kill volume) + - Player Equipment (punch) + - Useable Gun + - Useable Melee - + - Send to a connected client. + Do not replicate to clients. Run the event on the listen server (singleplayer) / dedicated server. + Equivalent to the `shouldReplicate = false` parameter. + Default. - + - The server ignores workshop info requests if it's been less than 30 seconds, - so we cache that info for 1 minute in-case we try to connect again right away. + Replicate to clients. Run the event everywhere. + Replaces the `shouldReplicate = true` parameter. - + - This information is needed before the level is loaded. + Only runs the event for the instigating player. - + - Advertised server name. e.g., "Nelson's Unturned Server" + Allows NPCs to trigger plugin or script events. - + - Name of map to load. + instigatingPlayer can be null. For example, if instigated by NpcGlobalEventMessenger. - + - Legacy difficulty mode that should be removed eventually. + Manages global post-process volumes. - + - Perspective settings. + Callback when in-game graphic settings change. - + - Server's IP from when we originally received response. - Used to test download restrictions. + Callback when player changes perspective. - + - Last realtime this cache was updated. + Worst case scenario, maybe shotgun hit or fast spray SMG. - + - Hacked-together initial implementation to refuse network messages from specific players. - On PC some cheats send garbage packets in which case those clients should be blocked. + Tags how client expects server to use a raycast input. + For example, client may think they fired a gun while server thinks they dequipped the gun, + so tagging the input prevents the server from handling it as a punch instead. - + - Close connection, and refuse all future connection attempts from a remote player. - Used when garbage messages are received from hacked clients to avoid wasting time on them. + Nelson 2025-09-09: changing to only require bounds test when usage will + apply damage because Detonator usage provides the barricade root transform + which may not have a collider. (Public issue #5202.) - + - Record that a bad packet was received from connection and maybe kick them if rate limit is exceeded. + Resulting transform.position immediately after movement.simulate was called. - + - Private to prevent plugins from changing the value. + Calls to UseableGun.tock per second. - + - Should buffers used by plugin network events be read-only copies? + Called for every input packet received allowing plugins to listen for a few special + keys they can display in chat/effect UIs. - + - First four bytes of RPC messages are the channel id. + Whether client is currently penalized for potentially using a lag switch. False positives are relatively + likely when client framerate hitches (e.g. loading dense region), so we only modify their stats (e.g. reduce + player damage) for a corresponding duration. - + - Should players be allowed to join this server regardless of whether their version number matches ours? - Useful to allow players to join debug mode servers. + Server tracks history of this player's bounding box to assist with validating hits. + Some padding is added to reduce false positives sliding against walls (substep) and + player movement inside vehicles. - + - Is version number supplied by client compatible with us? + Get the hit result of a raycast on the server. Until a generic way to address net objects is implemented + this is how legacy features specify which player/animal/zombie/vehicle/etc they want to interact with. - + - Notify players waiting to join server if their position in the queue has changed. + Ideally simulation frame number would be signed, but there is a lot of code expecting unsigned. - + - Prevent any particular client from delaying the server connection queue process. + Can be enabled in the unity inspector to test that discarding inputs recovers properly. - + - Allows hosting providers to limit the configurable max players value from the command-line. + askInput is always called the same number of times per second because it's run from FixedUpdate, + but the spacing between calls can vary depending on network and whether client FPS is low. - + - Deprecated-ish IPv4 to bind listen socket to. Set by bind command. + If average askInput calls per second exceeds this, we either ignore their request or flat-out kick them. - + - Local address to bind listen socket to. Set by bind command. + If average askInput calls per second exceeds this we silently kick them. - + - Steam query port. + Number of times askInput has been called by client. + Even with huge packet loss, we know that - + - If hosting a server, get the game traffic port. + Realtime that the first call to askInput was made by the client. - + - Populated when parsing modeConfigData. Level overrides check whether a property is overridden here before applying. + Realtime that the previous askInput kick test was performed. - + - Used to build packet about each existing player for new player, and then once to build a packet - for existing players about the new player. Note that in this second case forPlayer is null - because the packet is re-used. + Set rollingWindowIndex to newIndex, zeroing all input counts along the way. + Important to zero the intermediary indexes in-case server stalled for more than one second. - + - Not exactly ideal, but this a few old "once per player" client->server RPCs. + Notify client there has been a prediction error, so movement needs to be re-simulated. - + - Event for plugins when rejecting a player. + Notify client old inputs can be discarded because they were predicted correctly. - + - Notify client that they were kicked. + Not using rate limit attribute because it internally keeps a rolling window limit. - + - Notify client that they were banned. + Only bound on dedicated server. + When dieing in a vehicle this prevents delay handling packets. - + - Player left server by canceling their ticket, or we are disconnecting them without telling them. - Does not send any packets to the disconnecting player. + Counter of simulation frames before fake lag penalty is disabled. - + - Number of transport connection failures on this frame. + Player damage multiplier while under penalty for fake lag. (10%) - + - Callback when a pending player or existing player unexpectedly loses connection at the transport level. + If true the event will only be invoked in offline mode and on the server. - + - Check whether a server is one of our favorites or not. + July 7th! - + - Set whether a server is one of our favorites or not. + Context for the Assets.ReportError methods. + Nelson 2024-11-20: Converted from directly using asset to this interface so that asset-related features can + more easily log warnings to the in-game menu. - + - Open URL in the steam overlay, or if disabled use the default browser instead. - Warning: any third party url should be checked by WebUtils.ParseThirdPartyUrl. + Format text to prefix any errors reported in this context. (e.g., this asset's name and ID) - + - Steam's favorites list requires that we know the server's IPv4 address and port, - so we can't favorite when joining by Steam ID. + Used when damaging zombies to override in which situations they are stunned. - + - Toggle whether we've favorited the server we're currently playing on. + Default stun behaviour determined by damage dealt. - + - Toggle whether we've bookmarked the server we're currently playing on. + Don't stun even if damage is over threshold. - + - Ping from client to server, measured in milliseconds. + Stun regardless of damage. - + - Number of seconds since January 1st, 1970 GMT as reported by backend servers. + Overrides hat item from zombie table with a specific item ID. - + - Current UTC as reported by backend servers. - Used by holiday events to keep timing somewhat synced between players. + Overrides gear item from zombie table with a specific item ID. - + - Has the initial backend realtime been queried yet? - Not available immediately on servers because SteamGameServerUtils cannot be used until the actual Steam instance is available. + If zombie is stuck this was a nearby barricade potentially blocking our path. - + - Invoked after backend realtime becomes available. + If zombie is stuck this was a nearby structure potentially blocking our path. - + - In here because we want to call this very early in startup after initializing provider, - but with plenty of time to hopefully install maps prior to reaching the main menu. + If zombie is stuck this was a nearby vehicle potentially blocking our path. - + - This file is of particular importance to the dedicated server because otherwise Steam networking sockets - will say the certificate is for the wrong app. When launching the game outside Steam this sets the app. + If target player is passenger in a vehicle this is their vehicle. - + - Hackily exposed as an easy way for editor code to check the verison number. + If zombie is stuck this was a nearby object potentially blocking our path. - + - Has the onApplicationQuitting callback been invoked? + Incremented while stuck. Prevents doing overlap test too frequently. - + - Moved from OnApplicationQuit when that was deprecated. + Add or remove from ticking list if needed. + Separated from updateTicking in order to move once after first spawn. - + - Useful to load files from Steam install of the game while running in the editor. + Boss zombies are considered mega as well. - + - Moved from OnApplicationQuit when Application.CancelQuit was deprecated. + Yeah it seems kinda ugly to pollute all zombies with this code... zombie rewrite eventually please. - + - A couple of players have reported the PRO_DESYNC kick because their client thinks they own the gold upgrade, - but the Steam backend thinks otherwise. This option is a bit of a hack to work around the problem for them. + If damage exceeds this value, stun the zombie. - + - If specified, all Steam achievements and stats progress is lost. + Used to kill night-only zombies at dawn. - + - If specified, all Steam achievements are unlocked during startup. + Cache difficulty asset (if any) for this zombie's current type and bound. + Allows difficulty assets to override certain zombie behaviors. + Called after bound/type is initialized, and after type changes during respawn. - + - Host has not specified a value. + Called when zombie does not have a target, but has been stuck for a period. - + - Not an actual tag. Used for filtering. + Reduces frequency of UndergroundAllowlist checks because it can be expensive with lots of entities and volumes. - + - Host has specified that the server does not sell anything for real money. + Helper to prevent mistakes or plugins from breaking alive zombie count. - + - Host has specified that the server does have a real money shop, but does not sell anything which affects gameplay. + Helper to prevent mistakes or plugins from breaking alive boss zombie count. - + - Host has specified that the server does have a real money shop which sells benefits that affect gameplay. + 2023-01-31: set height to 2 rather than adjusting per-zombie-type. Tall zombies (megas) couldn't + get through doorways, and short zombies (crawlers) could get underneath objects they shouldn't + like gas tanks. Zombies were also stacking on top of eachother a bit too much. - + - Server list filter for plugin usage. + Very similar to . - + - Allows Unity events to send text chat messages from the client, for example to execute commands. + Very similar to . + True if sound played. - + - Text to use when SendDefaultTextChatMessage is invoked. + Is player already waiting to exit their group? - + - All players on the server will see the message. + Add player to exit queue if enabled, or immediately remove. - + - Only nearby players will see the message. + Remove player from queue if they're waiting to exit their group. - + - Chat mode to send request in. + Special asset type that isn't (shouldn't be) returned by asset Find methods. Instead, if found when resolving + an asset legacy ID or GUID, Find is called again with the target specified by this asset. - + - Corresponds to not active and not blending with new weather system. + Essentially identical to ContentReference, but MasterBundle is more convenient. + Perhaps in the future all asset/content systems will be consolidated. - + - Corresponds to transitioning in with new weather system. + Are name or path null or empty? - + - Corresponds to active with new weather system. + Are both name and path non-null and non-empty? - + - Corresponds to transitioning out with new weather system. + Name of master bundle file. - + - Corresponds to not active and not blending with new weather system. + Path to Unity asset within asset bundle. - + - Corresponds to transitioning in with new weather system. + Poorly named. Specific to InteractableObjectQuest. - + - Corresponds to active with new weather system. + Directly uses input string for custom message popups. - + - Corresponds to transitioning out with new weather system. + Player cannot build on a vehicle with occupied seats. - + - Kept for backwards compatibility with mod hooks, plugins, and events. + Horde beacon cannot be built here. - + - Kept for backwards compatibility with mod hooks, plugins, and events. + Item type is not allowed on vehicles. - + - [0, 1] used to avoid invoking BlendAlphaChanged every frame. - Compared against globalBlendAlpha not taking into account local volume. + Item must be placed closer to vehicle hull. - + - Hash of lighting config. - Prevents using the level editor to make night time look like day. + Player cannot build while seated in a vehicle because some vehicles are abusable to stick the camera through a wall. - + - Level designed target fog color. + Interacting with ladder. - + - Level designed target fog intensity. + Popup when equipping housing planner "press T to show items" - + - Level designed target atmospheric fog intensity. + Popup when structure is blocked by something named we can format into the message. - + - If global ocean plane is enabled then return the worldspace height, - otherwise return the optional default value. Default for volume based - water is -1024, but atmosphere measure uses a default of zero. + Notice that freeform buildables are blocked by Allow_Freeform_Buildables. - + - Nelson 2025-09-01: hacking this in to reset cloud particle systems when changing time - in the level editor. Otherwise, it's hard to tell how the intensity affects them. + Popup when structure is blocked by terrain. - + - Ticked on dedicated server as well as client so that server can listen for weather events. + Vehicle doesn't support spray paints. - On dedicated server this is always 0xFFFFFFFF. - + - Reset any global shader properties that may affect the main menu. + Explaining that some blueprints require workstations. - + - Source effect to group multiple volumes. + Barricades are allowed here but not structures. - + - Audio source added to AmbianceAudioGameObject. + Alternative to VOLUME_WATER or VOLUME_FUEL shown when object is destroyed. - + - Reset to false before updating volumes. + Helper wrapping Unturned's usage of AudioListener.volume, which is the master volume level. + This makes it easier to track what controls the master volume and avoid bugs. - + - Reset to false before updating volumes. + Is audio muted because this is a dedicated server? + + While dedicated server should not even be processing audio code, + older versions of Unity in particular have issues with headless audio. - + - Reset to zero before updating volumes. If any volume uses distance fadeout, this is the maximum alpha. + Is audio muted because loading screen is visible? - + - If any volume doesn't use distance fadeout, this is the alpha based on time spent inside.. + Player's volume multiplier from the options menu. - + - Highest priority of overlapping volumes. + Player's unfocused volume multiplier from the options menu. - + - If any volume doesn't use distance fadeout, this is the minimum of their audio fade-in time. + Mute or un-mute audio depending whether camera is valid. - + - If any volume doesn't use distance fadeout, this is the minimum of their audio fade-out time. - Only reset when created so that value is available after leaving all volumes. + Synchronize AudioListener.volume with Unturned's parameters. - + - Visualizes reverb zone in-game. + Vanilla maximum level. - + - Do not override zombie health. + If set, maximum skill level attainable through gameplay. - + - Per-speciality value is a multiplier for health configured in the level editor. + Multiplier for XP upgrade cost. - + - Per-speciality value is a multiplier for vanilla health value. + Get maximum level, or maxUnlockableLevel if set. + - + + - Per-speciality value replaces zombie's health. + Broadcasts after dedicated server name changes. + Command IO interface binds to this rather than having a title-specific method. - + - Can horde beacons be placed in the associated bounds? + Should the default console I/O handler be created? + Plugins can disable on the command line when overriding handler. - + - Can be null if not assigned. + Should the legacy blocking (game thread) console be created? - + - Overrides vehicle physics values in bulk without building asset bundles. + Log white information. - + - Only RPCs from the server will be allowed to invoke this method. + Log yellow warning. - + - RPCs are only allowed to invoke this method if we're running as server. + Log red error. - + - Only RPCs from the owner of the object will be allowed to invoke this method. + Print white message to console. - + - Maximum number of calls per-second per-player. + Print yellow message to console. - + - Minimum seconds between calls per-player. - Initialized from ratelimitHz when gathering RPCs. + Print red message to console. - + - Index into per-connection rate limiting array. + Cannot use UnturnedLog here because it may recursively call CommandWindow if another exception is thrown. - + - Backwards compatibility for older invoke by name code e.g. plugins. + Called during Unity Update loop. - + - If changing header size remember to update PlayerManager and allocPlayerChannelId. + Called during OnApplicationQuit. - + - How far to shift compressed voice data. + Helper for plugins that want to replace the default without the shouldCreateDefaultConsole flag. - + - If true, this object is owned by a locally-controlled player. - For example, some code is not run for "remote" players. - Always true in singleplayer. Always false on dedicated server. + Invoked after tellGesture is called with the new gesture. - + - Use on server when invoking client methods on the owning player. + Empty transform created at the world origin. + The first-person Viewmodel transform is re-parented to this. - + - Replacement for ESteamCall.NOT_OWNER. + Child of the first-person skull transform. - + - Don't use this. Originally added so that Rocketmod didn't have to inject into the game's assembly. + Camera near world origin masking the first-person arms and weapon. - - True if the call succeeded, or false if the sender should be refused. - - + - Don't use this. Originally added so that Rocketmod didn't have to inject into the game's assembly. + Used by gun to hide viewmodel arms while aiming 2D scope, and by chainsaw to shake the viewmodel. - + - Calls array needs rebuilding the next time it is used. - Should be invoked when adding/removing components with RPCs. + Used to hide viewmodel arms while using a vehicle turret gun. - + - Does array of RPCs need to be rebuilt? + Offsets main camera and aim rotation while aiming with a scoped gun. - + - Find methods with SteamCall attribute, and gather them into an array. + Animated toward viewmodelSwayMultiplier. - + - Encode byte array of voice data to send. + Small number (0.1) while aiming, 1 while not aiming. + Reduces viewmodel animation while aiming to make 3D sights more usable. - + - Decode voice parameters from byte array. + Animated toward viewmodelOffsetPreferenceMultiplier. - + - If true, light contributes to player spotlight. Defaults to true. - - Can be set to false for modders with a custom light setup. For example, this was added - for a modder who is using melee lights to toggle a lightsaber-style glow. + 0 while aiming, 1 while not aiming. + Players can customize the 3D position of the viewmodel on screen, but this needs + to be blended out while aiming down sights otherwise it would not line up with + the center of the screen. - + - 32-bit mask granting server plugins additional control over custom UIs. - Only replicated to owner. + If true, use the scope aim fov instead of non-scope fov. + Useful for players with high (e.g. 160) fov to be able to use scopes. - + - Enables cursor movement while not in a vanilla menu. + Animated toward viewmodelCameraLocalPositionOffset, recoil, and bayonet offsets. - + - Disable background blur regardless of other UI state. + Abruptly offset when gun is fired, then animated back toward zero. - + - Enable background blur regardless of other UI state. - Takes precedence over NoBlur. + Abruptly offset when gun is fired, then animated back toward zero. + x = pitch, y = yaw, z = roll - + - Enable title card while focusing a nearby player. + Abruptly offset when bayonet is used, then animated back toward zero. - + - Enable explanation and respawn buttons while dead. + Animated while player is moving. - + - Enable health meter in the HUD. + Blended from multiple viewmodel parameters and then applied to viewmodelCameraTransform. - + - Enable food meter in the HUD. + Smoothing adds some initial blend-in which felt nicer for explosion rumble. - + - Enable water meter in the HUD. + Meshes are disabled until clothing is received. - + - Enable virus/radiation/infection meter in the HUD. + Target viewmodelCameraLocalPosition except while driving. - + - Enable stamina meter in the HUD. + Animated while playing is moving. + x = pitch, y = roll - + - Enable oxygen meter in the HUD. + Offset when player lands. - + - Enable icons for bleeding, broken bones, temperature, starving, dehydrating, infected, drowning, full moon, - safezone, and arrested status. + Used to measure change in pitch between frames. - + - Enable UseableGun ammo and firemode in the HUD. + Used to measure change in yaw between frames. - + - Enable vehicle fuel, speed, health, battery charge, and locked status in the HUD. + Animated according to change in pitch/yaw input between frames so that gun rolls slightly while turning. - + - Enable center dot when guns are not equipped. + Animated according to change in item position between frames so that animations have more inertia. - + - Enable popup when in-game rep is increased/decreased. + Degrees per meter of item distance travelled. + Pitch is driven by vertical displacement, yaw and roll are driven by horizontal. + x = pitch, y = yaw, z = roll - + - Default flags set when player spawns. + In third-person this delays leaning in case player only wanted + to switch camera side without leaning. - + + If true, include current animation speed modifier. + + - 32-bit mask indicating to the server which admin powers are being used. - Does not control which admin powers are available. + At this point camera is already being shook, we just add some of the same shake to viewmodel for secondary motion. - + - Player is using spectator camera. + Called by clothing to make mesh renderers visible. - + - Player is using barricade/structure transform tools. + Event for server plugins to monitor whether player is in-inventory. - + - Player is using overlay showing player names and positions. + Rate limit is relatively high because this RPC handles open/close inventory notification. - + - Per-player event invoked when admin usage flags change. + Nelson 2024-03-20: Adding this method because (at the time of writing) first and third-person renderers + and skeletons are activated/enabled in InitializePlayer, onPerspectiveUpdated, and onLifeUpdated, and I + want them to be consistent with the addition of the new NPC Cutscene Mode option. - + - Event invoked when any player's admin usage flags change. + 2023-01-18: Viewmodel camera position was originally set during Update (and still is for compatibility), + but for aiming alignment that uses the previous frame's animation position, so we also modify during + LateUpdate to use this frame's animation position. - + + + Parameters for connecting to a game server. + + Admittedly there are other parameters to the Connect method, + but those are for detecting advertisement discrepencies and can be null. + + + - Used by plugins. + Server's public IP address of a Steam "Fake IP" address. - + - Invoked on client when a plugin changes the widget flags. + Port for Steam's "A2S" query system. This the port we refer to when + sharing a server's address (e.g., 127.0.0.1:queryport). - + - Exposed for Rocket transition to modules backwards compatibility. + Port for game traffic. i.e., Steam manages the query port socket while + we manage the connection port socket. The game assumes it's the query + port plus one. NOTE HOWEVER after the introduction of "Fake IP" support + (2023-12-07) the connection port is the same as the query port for fake + IPs. In keeping with the spirit of fake values to simplify existing code, + we act as if the connection port is plus one except in the appropriate + ClientTransport code when the fake IP is detected. - + - Not rate limited because server tracks number of expected screenshots. + Referred to as "Server Code" in menus. + Used if address is zero. - + - Request client to open a given URL. - Allows plugins to open web browser, but also gives client the chance to ignore it. + Called when the player clicks the cosmetic, visual or skin toggle buttons. - + - Tell client to join a specific server. - Disconnects client and sends them to the join server screen. - Only used by plugins. + Invoked after any player's shirt values change (not including loading). - + - Is this player currently in a plugin's modal dialog? - Enables cursor movement while not in a vanilla menu. + Invoked after any player's shirt values change (not including loading). - + - Tell the client whether to be in plugin modal mode or not. - Kept from prior to introduction of pluginWidgetFlags. + Invoked after any player's hat values change (not including loading). - + - If true, bypass player culling test as if freecam overlay were active. - Enables plugins to implement a custom admin culling bypass switch. (Was requested.) - Defaults to false. + Invoked after any player's backpack values change (not including loading). - + - Which admin powers are currently in use by the client. - Reported to the server by the client. - Does not control which admin powers are available. - Note: Hacks can prevent this notification from being sent. + Invoked after any player's backpack values change (not including loading). - + - Called on the client to notify the server of admin usage changes (if any). + Invoked after any player's backpack values change (not including loading). - + - Called on the client to notify the server of admin usage changes (if any). + Invoked after any player's glasses values change (not including loading). - + - Teleport to a random player spawn designated in the level. + Host has not specified a value. - + - Teleport to bed, if player has set one. + Not an actual tag. Used for filtering. - + - Teleport is always handled by owner and locally (loopback), but *not* by culled clients. + Host has specified that the server does not sell anything for real money. - + - How many calls to will succeed per second. + Host has specified that the server does have a real money shop, but does not sell anything which affects gameplay. - + - How many rate limited actions have been performed recently. - Increased after performing each rate limited action, and decreased over time. - Cannot perform actions when greater than one. + Host has specified that the server does have a real money shop which sells benefits that affect gameplay. - + - Note: new official code should be using per-method rate limit attribute. - This is kept for backwards compatibility with plugins however. + Event for plugins to be notified when a server update is detected. - Call this method before any requests the client can spam to the server. + Some hosts requested this because they run the game as a Windows service and need to shutdown + through their central management system rather than per-process. - Should your code proceed with the rate limited action? - + - Call every frame to cool down rate limiting. + Manages scheduled restart for dedicated server. - + - This code was in the Start message, and should happen before other initialization. + Sorted from low to high. - + - Hacky replacement for Start() that runs after net ids are assigned but before sending player state. + Sorted from low to high. - + - Nelson 2024-11-11: Added to help narrow down if player is destroyed outside of Provider.removePlayer. - (public issue #4760) + Find an item to apply stat tracker tool to. - + - Flag in case levelObject is destroyed. + Find an item with a stat tracker to remove. - + - Poorly named. Specific to InteractableObjectQuest. + Find an item with a ragdoll effect to remove. - + - Directly uses input string for custom message popups. + Find an item to apply ragdoll effect tool to. - + - Player cannot build on a vehicle with occupied seats. + Toggle button to open/close advanced filters panel. - + - Horde beacon cannot be built here. + On/off checkbox for including description text in filter. - + - Item type is not allowed on vehicles. + Switch between sort modes. - + - Item must be placed closer to vehicle hull. + On/off checkbox to reverse sort results. - + - Player cannot build while seated in a vehicle because some vehicles are abusable to stick the camera through a wall. + On/off checkbox to show only equipped items. - + - Interacting with ladder. + Container for advanced options. - + - Popup when equipping housing planner "press T to show items" + Whether to include description text in filter. - + - Popup when structure is blocked by something named we can format into the message. + How to sort filtered items. - + - Notice that freeform buildables are blocked by Allow_Freeform_Buildables. + Should sorted list be reversed? - + - Popup when structure is blocked by terrain. + Should only equipped items be shown? - + - Vehicle doesn't support spray paints. + Remove items that do not match search text. - + - Explaining that some blueprints require workstations. + Removed items that are not equipped. - + - Barricades are allowed here but not structures. + These are methods moved from the Data class which rely on core types and so cannot go in the UnturnedDat assembly. - + - Nelson 2024-11-29: Curious to put all the gun stats in one place for easier comparison. Rather rudimentary at - the moment so not including in the update. + Intended as a drop-in replacement for existing assets with property uint16s. - + - Controls how first-person arms are moved for turrets operated from the driver's seat. + Intended as a drop-in replacement for existing assets with legacy IDs. - + - Default. Pushes first-person arms off-screen while aiming. Originally implemented for the Fighter Jet where - it looks weird if your arms are still visible when the camera zooms in while "aiming." + Enables builder pattern for dat edits. + Inclusion of asset type is optional for cases where it's not obvious from context. - + - Push first-person arms off-screen when equipped. - - - + Enables builder pattern for dat edits. + Inclusion of asset type is optional for cases where it's not obvious from context. + + Legacy asset references are converted to GUID if the asset is available. If not available, type prefix + is only used if legacy type changed. + + + + + This overload assumes legacyType has not changed. This will usually be the case. Legacy type would only + change (for example) in cases like spawn tables where they can reference any asset type. + + + + + Uses the Win32 API to force a console to be created and destroyed. + + + + + Should we manually create and destroy a Win32 console? + Useful for IO on Windows desktop, but not as much for dedicated machines. + + + + + Allocate Windows console if enabled. + + + + + Free Windows console if enabled. + + + + + A CTRL+C signal was received, either from keyboard input or from a signal generated by the GenerateConsoleCtrlEvent function. + + + + + A CTRL+BREAK signal was received, either from keyboard input or from a signal generated by GenerateConsoleCtrlEvent. + + + + + A signal that the system sends to all processes attached to a console when the user closes the console + (either by clicking Close on the console window's window menu, or by clicking the End Task button command from Task Manager). + + + + + Use "Interact" token from translation file. + + + + True if primary action was started and stopPrimary should be called in the future. + Useful to allow input to be held until action executes. + + + True if secondary action was started and stopSecondary should be called in the future. + Useful to allow input to be held until action executes. + + + + Does useable have a menu open? + If so pause menu, dashboard, and other menus cannot be opened. + + + + + Added during the UI refactor to catch unhandled mouse clicks during drag. + + + + + Contains inspect item box and invisible button. + + + + + Added during the UI refactor to catch mouse clicks outside the selection box. + + + + + Workaround for IMGUI. Disable inventory headers, grids and slots while selection is open + to prevent them from interfering with selection menu. + + + + + Was ConsumeEvent called during this frame? + This is a hack to prevent firing when clicking in the UI on the same frame it closes. + Moved from SleekWindow and Event.current.Use() during UI refactor. + + + + + Move item drag visual to the cursor's position. + + + + + • Does not support legacy ID. + • Caches resolved asset and updates if asset has been reloaded. + • See CachingBcAssetRef if legacy ID support is necessary. + + + + + If true, doesn't reference anything. + Could also be called "IsZero" or "IsNull". + + + + + Opposite of IsEmpty. + + + + + Assigned GUID, not the referenced asset's GUID. + + + + + Doesn't only check (Get() == asset) because a new asset may have loaded. + Rather, checks whether GUID points at asset. + If asset is null, returns true if GUID and legacy ID are zero. + + + + + Returns Empty if TryParse returns false. + + + + + Enables assigning assetRef from an existing asset without manually calling constructor. + + + + + Enables assigning assetRef from an asset GUID without manually calling constructor. + + + + + Internal so that CachingBcAssetRef can copy cachedAsset. + + + + + Rather than creating all SleekItems as once we create a few per frame. + + + + + Reset all items hotkey label. + + + + + Replacement for enum origin. + + + + + Hardcoded built-in name, or name of workshop file if known. + + + + + Steam file ID if loaded from the workshop, zero otherwise. + + + + + If true, when added to asset mapping the new assets will override existing ones. + This ensures workshop files installed by servers take priority and disables warnings about overlapping IDs. + + + + + If true, we can re-save .dat/.asset files from this origin. + Defaults to false. Only true for assets in the game install folder. + + + + + Repurposed from the Modules UI because it was unused. + + + + + Pool lists to avoid loopback re-using an existing list. + Callers do not need to manually return lists because they are reset before each frame. + + + + + This value is confusing because in the level editor it is the normalized radius, but in-game it is the radius. + + + + + Base class for UIToolkit implementations of primitive building block widgets. + + + + + Set by child. + + + + + Synchronize control colors with background/text/image etc. colors. + Called when custom UI colors are changed, and after constructor. + + + + + Examine a store listing with description text. + + + + + Only visible when cart is not empty. + + + + + Calculate angle in radians the player would need to offset their aim upward + to hit a target a certain distance away. + + + + + Separate from isEnabled to hide markers when they are outside the scope. + + + + + Used to sync hasLabel visibility. + + + + + Create glazier implementation. Invoked early during startup. + + + + + Nelson 2025-08-20: changing this to affect both sentries and safezones. Some modded safezones allow + building but not weapons, so players were using charges to destroy houses. (public issue #5175) + + + + + It is useful to be able to reference transforms generically over the network, for example to attach a bullet + hole to a tree or vehicle without tagging it as a tree or vehicle, but most entities placed in the level do not + have unique IDs. To work around this we count downward from uint.MaxValue for level objects to avoid conflicts + with server-assigned net ids. + + + + + Nelson 2025-06-10: this is used by older level file formats, but with placement of trees outside legacy + bounds now supported we use only the index in that case with GetTreeNetIdV2. + + Each region can have ushort.MaxValue trees, and we reserve that entire block so that a region can be slightly + modified on the client or server without breaking all netids in the level. + + + + + Each region can have ushort.MaxValue objects, and we reserve that entire block so that a region can be slightly + modified on the client or server without breaking all netids in the level. + + + + + Devkit instance IDs should already be fairly stable. There is no way any level is using more than 30 bits + for the instance ID, so it should be safe to set those bits to prevent collisions with server net IDs. + + + + + Can be added to any GameObject with an interactable binary state in its parents. + + If players should not be allowed to interact with the object in the ordinary manner, + add the Interactability_Remote flag to its asset to indicate only mod hooks should control it. + + + + + When a state change is requested in singleplayer it should be treated as if running as a client on a server. + This is the default to match behavior from before this option was added. + + + + + When a state change is requested in singleplayer it should be treated as if running as a dedicated server. + + + + + Invoked when interactable object enters the Used / On / Enabled state. + + + + + Invoked when interactable object enters the Unused / Off / Disabled state. + + + + + Should the OnStateEnabled and OnStateDisabled events be invoked when the object is loaded, becomes relevant + in multiplayer, and is reset? True is useful when visuals need to be kept in sync with the state, whereas + false is useful for transient interactions. + + + + + If true, OnStateEnabled and OnStateDisabled are only invoked in singleplayer and on the server. + + + + + If true, calls to GotoEnabledState, GotoDisabledState, and ToggleState are only processed in singleplayer + and on the server. + + + + + Controls how state change requests are performed when running as both client and server ("listen server"). + On the dedicated server, requesting a state change overrides the current state without processing NPC + conditions, whereas when a client requests a state change NPC conditions apply. This option fixes the + inconsistency in singleplayer of whether to treat as server or client. (public issue #4298) + At the time of writing (2024-01-29) listen server only applies to singleplayer. + + + + + Set state to Enabled if currently Disabled. + + On dedicated server this directly changes the state, + but as client this will apply the usual conditions and rewards. + + + + + Set state to Disabled if currently Enabled. + + On dedicated server this directly changes the state, + but as client this will apply the usual conditions and rewards. + + + + + Toggle between the Enabled and Disabled states. + + On dedicated server this directly changes the state, + but as client this will apply the usual conditions and rewards. + + + + + Consolidates parameters for older, separate inventory search methods. + + The "player" part of the name refers to the PlayerInventory-specific parameters. It can still be used to search + the Items class, in which case those parameters do not apply. + + + + + List to populate with matching items. + + + + + If true, search player's primary and secondary weapon slots. + Only applicable when used with PlayerInventory class. (I.e., not Items class.) + + + + + If true, search storage container player is currently interacting with (if any). + Only applicable when used with PlayerInventory class. (I.e., not Items class.) + + + + + If greater than zero, search exits early once Results count meets MaxResultCount. + + + + + If set, item must be this type to match. + + + + + If set, AssetRef must be a reference to item's asset to match. + Replaces older "id" parameter which matched if item's legacy asset ID was the same. + + + + + If true, items with amount of zero can match. Otherwise, they are ignored. + Replaces older "findEmpty" parameter which matched if (findEmpty || amount > 0). + + + + + If true, items with an "amount" >= their MaxAmount are ignored. Otherwise, they can match (default). + + + + + + If set, item must be of type ItemCaliberAsset. Asset's caliber list must either: + • Contain this caliber ID. + • Or, if empty, IncludeUnspecifiedCaliber must be true. + Otherwise, item is ignored. + + + - No particular use in mind, but included for completeness. + If set, item must be of type ItemCaliberAsset. Asset's caliber list must either: + • Contain one of these caliber IDs. + • Or, if empty, IncludeUnspecifiedCaliber must be true. + Otherwise, item is ignored. - + - Default. Plays "Hammer" animation if ammo count was zero. + Only applicable if CaliberId or AnyCaliberIds is set. + If true, assets with an empty calibers list can match. Otherwise, they are ignore.d - + - Regardless of ammo, does not play "Hammer" animation after reloading. + If set, do not include this specific item instance in search results. + Kind of hacked-in for ignoring "target item" as a potential input item. - + - Regardless of ammo, will play "Hammer" animation after reloading. + Nearly identical to InventorySearch aside from: + • Struct instead of class to improve garbage collection performance in pooled lists. + • More understandable name. + • Provides reference to Items holding "Jar." Longer-term this should be preferred over the "Page" property. - + - Sound to play when input is pressed but weapon has a fire delay. + Serverside delete an amount of this item. + False for crafting where original item can be kept, true when selling to vendors. + Total amount deleted. - + - Maximum distance the gunshot can be heard. + -1 if no eligible item is found. + If includeMaxQuality is true an item with quality of 100 can be "lowest quality", otherwise item has to + be less than 100 quality. - + - Override Rangefinder attachment's maximum range. - Defaults to range value. + Please use PlayerInventorySearchResultV2 for better performance! - + - Can this weapon instantly kill players by headshots? - Only valid when game config also enables this. + Serverside delete an amount of this item. + Total amount deleted. - + - Can this weapon be fired without consuming ammo? - Some mods use this for turrets. + Reset to -1 when not chatting. If player presses up/down we get index 0 (most recent). - + - Ammo quantity to consume per shot fired. + Fill chat field with previous sent message. + Useful for repeating commands with minor changes. - + - Simulation steps to wait after input before firing. + Use the latest hotbar items in the UI. - + - Can magazine be changed by player? + Number of seconds to finish growing. - + - Can player ADS while sprinting and vice versa? + Item legacy ID to grant the player. - + - If true, the gun cannot shoot unless the player is aiming. - Note: String action overrides this. - Defaults to true for miniguns. + Uses unscaled time (realtime) because "planted" time is a timestamp. - + - If true, the gun will stop aiming regardless of player input. + Zero is treated as unset. - + - Seconds from pressing "aim" to fully aiming down sights. + Nelson 2025-05-28: keeping this a struct to simplify memory management (no pool needed). If making this more + generic in the future we probably do need to make it a class. - + - If true, Aim_Start and Aim_Stop animations are scaled according to actual aim duration. + Only applicable to barricades. - + - Selects a default magazine, following magazine replacements and spawn table resolution. + Preliminary sort order is provided by server, but this takes priority if camera is available. - + - Selects a default magazine, following magazine replacements and spawn table resolution. + Not ideal, but there was a problem because onLevelLoaded was not resetting these after disconnecting. - + - How long in seconds after firing to rechamber the gun by playing the Hammer animation. - Only applicable if RechamberAfterShotCount is >0. - Defaults to 0.25 seconds. + Instantiate at least this many items per frame even if we exceed our time budget. - + + Start Vertex + Start Vertex + Start Tangent + End Vertex + End Tangent + End Vertex + + + Start Vertex + Start Vertex + Start Tangent + End Vertex + End Tangent + End Vertex + + + Start Vertex + Start Vertex + Start Tangent + End Vertex + End Tangent + End Vertex + + + Start Vertex + Start Vertex + Start Tangent + End Vertex + End Tangent + End Vertex + World units length along curve. + Spacing between points. + Max estimate distance from uniform interval before we have to retry. + How many times to retry if the estimate is too far off. + If length is already known pass it in, otherwise it's recalculated. + Time along curve. [0-1] + + + Start Vertex + Start Vertex + Start Tangent + End Vertex + End Tangent + End Vertex + Spacing between points. + Max estimate distance from uniform interval before we have to retry. + How many times to retry if the estimate is too far off. + + - How long in seconds after hammering to eject a bullet casing. - Defaults to 0.45 seconds. + This prevents identical tag provider setups from listing in the UI. + For example, two workbenches providing the same tags shouldn't show two UI listings. - + - How long in seconds after reloading to eject bullet casings. - Only applicable if CasingEjectCountAfterReload is greater than zero. - Defaults to 0.5 seconds. + Player does not want to see this blueprint. - + - Defaults to false. If true, attachments must specify at least one non-zero caliber. - Requested by Great Hero J to block vanilla attachments in VGR. + Player wants to save this blueprint in a special category. - + - Determines whether "Hammer" animation plays after attaching a magazine. - Note: this happens when a magazine replaces another OR fills previously empty slot. + Find nearby crafting tag providers and query their tags. - + - Determines whether "Hammer" animation plays after detached a magazine. - Note: this happens when a magazine is removed from the gun without a replacement. + Tests whether nearby tags include specified tag. + Doesn't update nearby tags, so call UpdateAvailableCraftingTags if out-of-date. - + - Spread multiplier while sprinting. + Requested for plugin use. + Notifies owner they should refresh the crafting menu. - + - Spread multiplier while crouched. + Update anything that will not change as blueprint is invoked repeatedly on server. - + - Spread multiplier while prone. + Update anything that can change as blueprint is invoked repeatedly on server. - + - Spread multiplier while swimming. + Returns true if should exit early. + If updating behavior here please remember to update . - + - Spread multiplier while not grounded. + Find all item assets available to the player for crafting. + Used to more quickly identify blueprints that might be craftable, rather than testing all blueprints. + If updating behavior here please remember to update . - + - Recoil magnitude multiplier while the gun is aiming down sights. + Allows housing planner to craft without playing effect, without also allowing + cheaters to craft without playing effect. (if it were an RPC param) - + - Recoil magnitude while sprinting. + Get local player's per-blueprint preferences. - + - Recoil magnitude while crouched. + Set local player's per-blueprint preferences. + This is helpful both to prevent accidentally crafting certain blueprints (like blindfolds) when click to + craft is enabled, and to save frequently used blueprints. - + - Recoil magnitude while prone. + Why isn't tags list public visibility? Because if adding features to (for example) consume a resource when + crafting tag provider is used that will require an API change. - + - Recoil magnitude while swimming. + "Single-Render" scope as opposed to "Dual-Render" (rendering the scene a second time with a zoomed-in camera). + Blits middle square of the player's view into the viewmodel scope material's render target. - + - Recoil magnitude while not grounded. + Each level should have a 380x80 Icon.png file. + This class caches them so that the server list can show them quickly. - + + Matches handle returned by request, or -1 if cached. + + - [0, 1] percentage of maximum range where damage begins decreasing toward falloff multiplier. + Nelson 2025-01-28: This command reproduces a bug destroying the player gameObject if the vehicle is + destroyed on the same frame as the request to enter. + https://github.com/SmartlyDressedGames/Unturned-3.x-Community/issues/4760#issuecomment-2613090165 - + - [0, 1] percentage of maximum range where damage finishes decreasing toward falloff multiplier. + Reset dragging handle and register transformation. - + - [0, 1] percentage of damage to apply at damageFalloffMaxRange. + Sort servers by name A to Z. + + + + + Sort servers by name Z to A. + + + + + Sort servers by map name A to Z. + + + + + Sort servers by map name Z to A. - + - Seconds before physics projectile is destroyed. + Sort servers by player count high to low. - + - Is this gun setup to have a change of jamming? + Sort servers by player count low to high. - + - [0, 1] quality percentage that jamming will start happening. + Sort servers by max player count high to low. - + - [0, 1] percentage of the time that shots will jam the gun when at 0% quality. - Chance of jamming is blended between 0% at jamQualityThreshold and jamMaxChance% at 0% quality. + Sort servers by max player count low to high. - + - Name of the animation to play when unjamming chamber. + Sort servers by normalized player count high to low. - + - Movement speed multiplier while the gun is aiming down sights. + Sort servers by normalized player count low to high. - + - If >0, hammer animation plays after shooting this many shots after RechamberAfterShotDelay seconds pass. - Defaults to one for EAction.Pump and EAction.Bolt, zero otherwise. + Sort servers by ping low to high. - + - If >0, emit particles after hammer after EjectAfterHammerDelay seconds pass. - Only applicable if RechamberAfterShotCount is >0. - Defaults to 1. + Sort servers by ping high to low. - + - If >0, emit particles after reloading after EjectAfterReloadDelay seconds pass. - Defaults to ammoMax for EAction.Break. + Information about a game server retrieved through Steam's "A2S" query system. + Available when joining using the Steam server list API (in-game server browser) + or querying the Server's A2S port directly (connect by IP menu), but not when + joining by Steam ID. - + - If true, emit particles when a shot is fired. - Defaults to true for EAction.Trigger and EAction.Minigun. + Join server by IP. - + - Please refer to . + Server is not using an anycast proxy. - + - Please refer to . + Server host indicated an anycast proxy is in use. - - - The dialogue to go to when a message has no available responses. - If this is not specified the previous dialogue is used as a default. - If neither is available then a default "goodbye" response is added. - - For example, Chief_Police_Doughnuts_Accepted dialogue has a single message - "Let's just keep this between the two of us." shown with "prev" dialogue - set to the NPC's root dialogue asset. - - - - True if primary action was started and stopPrimary should be called in the future. - Useful to allow input to be held until action executes. - - - True if secondary action was started and stopSecondary should be called in the future. - Useful to allow input to be held until action executes. - - + - Does useable have a menu open? - If so pause menu, dashboard, and other menus cannot be opened. + Moderator flagged server as using an anycast proxy. (EHostBanFlags.QueryPingWarning) - + - Determines how the "Explosion" effect is spawned when a barricade or structure is destroyed. - - Nelson 2025-09-08: although explosion effect currently exists in Barricade and Structure - sub-classes I think it makes sense to share this option (and ideally more in future). + Ping time measured in milliseconds. - + - Legacy behavior. + ID of network transport implementation to use. - + - Effect spawns exactly at the model position without any offset. + Known plugin systems. - + - Effect spawns with same rotation as the model. + Probably just checks whether IP is link-local, but may as well use Steam's utility function. - + - Common base for barricades and structures. - 2023-01-16: not ideal to be adding this so late in development, but at least it is a step in the right direction. + Active player count divided by max player count. - + - If true, this item is eligible for zombies to detect and attack when stuck. - Defaults to true. + Nelson 2024-08-20: This score is intended to prioritize low ping without making it the be-all end-all. The + old default of sorting by ping could put near-empty servers at the top of the list, and encouraged using + anycast caching to make the server appear as low-ping as possible. - + - Item or spawn table recovered when picked up below 100% health. + Nelson 2024-08-20: This score is intended to prioritize servers around 75% capacity. My thought process is + that near-empty and near-full servers are already easy to find, but typically if you want to play online you + want a server with space for you and your friends. Unfortunately, servers with plenty of players but an even + higher max players make a 50% score plenty good. - + - Minimum number of items to recover when salvaged. + Nelson 2024-08-20: This score is intended to balance out the downside of the fullness score decreasing for + servers with very high max player counts, and over-scoring servers with low max players. - + - Maximum number of items to recover when salvaged. + Called before inserting to server list. - + - Minimum number of items to drop when destroyed. + Parses value between two keys thing would parse thing - + - Maximum number of items to drop when destroyed. + If set, this server was denied by a server curation list. - + - Item or spawn table dropped when destroyed. + Circular mask for 2D distances in meters on a 2D cell grid. + Includes a cell if the meters distance between the center cell + and the closest point on test cell is within radius. - + - If non-null, this asset provides the listed crafting tags to nearby players. + World space distance in meters. - + - Note: this assumes SalvageItemRef points to an ItemAsset. + Region cell size in meters. - + - By default a crafting ingredient is salvaged. + Called after lod bias may have changed. - + - Thanks to Glenn Fiedler for this RK4 implementation article: - https://gafferongames.com/post/integration_basics/ + Yes, this is silly. If present, Doppler effect won't be turned off on sibling audio sources. + Until 2025, Doppler effect scale was zero in project audio settings. Many audio sources + sound bad with Doppler effect enabled, so for backwards compatibility we need to turn off + Doppler effect per-audio-source unless it's marked with this component. - + - Higher values return to the target position faster. + Struct interface so that for transient asset bundles (older workshop mods) they can be preloaded + and retrieved as-needed, but for master bundles the asset loading can be deferred until needed. - + - Higher values reduce bounciness and settle at the target position faster. - e.g. a value of zero will bounce back and forth for a long time (indefinitely?) + Legacy implementation that preloads assets. - - - Nelson 2025-04-09: this acted as both category AND behaviour modifier, so I'm separating it into a custom tag - for categorization and a property for overriding how the blueprint processes input items. - - Nelson 2025-04-10: repair and ammo "types" had a variety of quirks I wanted to sort out: - • Moving amount between items required ammo type blueprint, but some modders expressed interest in non-ammo use. - (I.e., ideally better supporting amount on non-ammo items going forward.) - • Both types ignored output items. Output was used to represent the target item. Similarly, the UI added a fake - extra input item representing target item. - • PlayerCrafting and PlayerDashboardCraftingUI re-implemented some crafting item searching logic for finding - the item to refill or repair that can be converted into input item parameters. - The plan at the moment is to make the last input item the "target" item for operations. Legacy ammo/repair - blueprints will then default to no output item and add an extra input item. (And add a variety of parameters - needed to replicate the specialized item search behaviour.) - - - + - Controls what blueprint does with input items. - Separated from EBlueprintType which acted as both category AND operation. + Save a reference to an object in the asset bundle, but defer loading it until requested by game code. - + - No special modification to input items. + Other menus can modify DevkitSelectionToolOptions so we need to sync our menu when opened. - + - Restore target input item to full quality. + Resolve spawn table asset if set, otherwise find asset by legacy in-editor ID configuration. + Returned asset is not necessarily a vehicle asset yet: It can also be a VehicleRedirectorAsset which the + vehicle spawner requires to properly set paint color. - + - Transfer amount from input items to target item. + Used when spawn table asset is not assigned. Pick a random legacy ID using in-editor list of spawns. - + - Can be added to any GameObject with a Dropper, Note, or Quest interactable object in its parents. + Created when a chat entry is received from the server for display in the UI. - + - Invoked on authority when interactable object is used successfully. - Only invoked on clients if ShouldReplicate is true. + Player who sent the message, or null if it was a plugin broadcast. + Used to retrieve player avatar. - + - If true, the server will replicate the OnUsed event to clients as well. + Web address of a 32x32 .png to use rather than a platform avatar. + Only used if not null/empty. - + - If ShouldReplicate is enabled, should the RPC be called in reliable mode? - Unreliable might not be received by clients. + How the message was sent through global, local or group. + Mostly deprecated because that status isn't formatted into texts anymore. - + - Applied if greater than zero. Defaults to 128. + Default font color to use unless overridden by rich text formatting. - - True if it's a new claim flag. - - + - Player stealth radius cannot go below this value. + Whether this entry should enable rich text formatting. + False by default to prevent players including markup themselves. - + - Deal damage and break legs if speed is greater than this value. + Text to display for this message. - + - By default players in singleplayer and admins in multiplayer have a faster salvage time. - This option was requested for maps with entirely custom balanced salvage times. + When the entry was locally received from the server. - + - Cached result of finding all craftingBlacklists. + How many seconds ago this message was locally received from the server. - + - Determines which weather can naturally occur in this level. - Null if empty. + Report success or failure from game systems, conditionally compiled into the Windows 64-bit build. + + + + + Call when the server is done all loading without running into errors. + Ignored if not running in CI mode, otherwise exits the server successfully with error code 0. - + - If set, this weather will always be active and scheduled weather is disabled. + Call when the server encounters any error. + Ignored if not running in CI mode, otherwise exits the server with error code 1. - + - Audio clip to play in 2D when a player dies. + Replaced by ServerMethodHandle. - + - Defaults to false because some servers have rules and info on the loading screen. + Replaced by ClientInstanceMethod.InvokeAndLoopback or ClientStaticMethod.InvokeAndLoopback. - + - Volume weather mask used while not inside an ambience volume. + Replaced by ClientMethodHandle invoked with Provider.EnumerateClients_Remote. + Unlike ESteamCall.CLIENTS this is not loopback invoked. - + - If >= 0, overrides vanilla skill cost. - Defaults to -1. + Replaced by ClientMethodHandle invoked with SteamChannel.GetOwnerTransportConnection. - + - If >= 0, overrides vanilla increase in skill cost with each level. - For example, if the base cost is 10 and this is 15, the first level will cost 10 XP, - the second level 25 XP, the third 40 XP, so on and so forth. - Defaults to -1. + Replaced by ClientMethodHandle invoked with SteamChannel.EnumerateClients_RemoteNotOwner. - + - Allows level to override skill max levels. - Null if empty, otherwise matches 1:1 with PlayerSkills._skills. + Replaced by ClientMethodHandle invoked with Provider.EnumerateClients. + Unlike ESteamCall.OTHERS this will be loopback invoked in singleplayer or listen server. - + - If false, clouds are removed from the skybox. + May have been used by voice in early versions, but has been completely removed. - + - If set, instantiate this particle system and set its material color to cloud color. + Slightly interpolated copy of actual spread angle to smooth out sharp changes like crouch/prone. - + - Multiplier for CloudOverrideParticlesPrefab emission rate according to level's clouds intensity. + Allows interpolatedSpread to snap to target value when crosshair becomes visible. - + - Particle system's material instance will have these color properties set to the level's cloud color. - Defaults to _Color. + Represents an item the vendor is selling to players. - + - t passed into ParticleSystem.Simulate when clouds need an update. + Refer to NPCItemReward state. - + - If set, overrides the per-skillset items players spawn with. - Can be used to prevent skillset default items in singleplayer. - Server "Loadout" command takes priority over this option. - Defaults to null. + Represents a vehicle the vendor is selling to players. - + - Players are kicked from multiplayer if their skin color is within threshold of any of these rules. + Returned asset is not necessarily a vehicle asset yet: It can also be a VehicleRedirectorAsset which the + vehicle spawner requires to properly set paint color. - + - Optional Unturned extensions to the LOD Group component. + If set, takes priority over VehicleRedirectorAsset's paint color and over VehicleAsset's default paint color. - + - Could be extended, e.g. to clamp cull size separately from the per-LOD sizes. + Kept because lots of modders have been using this script in Unity, + so removing legacy effect id would break their content. - + - Unturned will adjust per-LOD sizes to counteract LOD bias. - Elver has carefully tuned LOD sizes for the interior of the mall, so LOD bias affecting them is undesirable. - Note that due to a Unity bug only LOD0 can be greater than 100%. + Active while powered. - + - Is player already waiting to exit their group? + Thanks to Glenn Fiedler for this RK4 implementation article: + https://gafferongames.com/post/integration_basics/ - + - Add player to exit queue if enabled, or immediately remove. + Higher values return to the target position faster. - + - Remove player from queue if they're waiting to exit their group. + Higher values reduce bounciness and settle at the target position faster. + e.g. a value of zero will bounce back and forth for a long time (indefinitely?) - + - Invoked immediately before Destroy vehicle. + Not extendable until transport API is better finalized. - + - Exposed for Rocket transition to modules backwards compatibility. + Add fuel to target. - + - If true, a vehicle asset has been replaced. + Remove fuel from target. - + - Find vehicle with matching replicated instance ID. + Note: If barricade is attached to a vehicle this is the local rotation. - + + Unturned_Data folder path + + - Supports redirects by VehicleRedirectorAsset. If redirector's SpawnPaintColor is set, that color is used. + Useful to check whether hashing is causing problems. - + - Supports redirects by VehicleRedirectorAsset. If paintColor is set that takes priority, otherwise if - redirector's SpawnPaintColor is set, that color is used, + Useful to narrow down why a player is getting kicked for modified resource files when joining a server. - + - Supports redirects by VehicleRedirectorAsset. If redirector's SpawnPaintColor is set, that color is used. + If true, visible in chart and satellite UIs. - + - Supports redirects by VehicleRedirectorAsset. If paintColor is set that takes priority, otherwise if - redirector's SpawnPaintColor is set, that color is used, + Should objects that failed to load due to missing assets be saved? + If true, a placeholder transform is created and used to save. + If false, objects without assets are zeroed during save. (old default) - + - Supports redirects by VehicleRedirectorAsset. If redirector's SpawnPaintColor is set, that color is used. + Hash of Objects.dat - + - Supports redirects by VehicleRedirectorAsset. If paintColor is set that takes priority, otherwise if - redirector's SpawnPaintColor is set, that color is used, + Note: refers to per-LevelObject unique ID, not Unity object instance ID. - + - Supports redirects by VehicleRedirectorAsset. If redirector's SpawnPaintColor is set, that color is used. + Called by navmesh baking to complete pending object changes that may affect which nav objects are enabled. - + - Supports redirects by VehicleRedirectorAsset. If paintColor is set that takes priority, otherwise if - redirector's SpawnPaintColor is set, that color is used, + Stagger regional visibility across multiple frames. - + - Added so that garage plugins do not need to invoke RPC manually. + Caches uint16 ID to ID redirects. - zero spawns without a battery, ushort.MaxValue indicates the battery should be randomly spawned according to asset configuration, other values force a battery to spawn. - + - For backwards compatibility. This older method spawns a vehicle with a random paint color. (set paintColor - to zero for a random paint color) + Server response to a non-rejected CONNECT request. Notifies client they are in the queue. - zero spawns without a battery, ushort.MaxValue indicates the battery should be randomly spawned according to asset configuration, other values force a battery to spawn. - + - Used by external spawn vehicle methods. - Supports redirects by VehicleRedirectorAsset. If redirector's SpawnPaintColor is set, that color is used, - unless preferredColor.a is byte.MaxValue. + If false, a deny rule matched the input. - Owner to lock vehicle for by default. Used to lock vehicles to the player who purchased them. - + - Client-side request server to toggle headlights. + If true, at least one rule matched the input. - + - As client request server to use bonus feature like towing hook or police sirens. + If set, this was the final match. - + - Helper for servers with huge numbers of vehicles. - Called with fixed span of indexes e.g. [0, 10), then [10, 20). This function then clamps the final span to the vehicle count. + Optional. If set, filled with any rules that matched. - + - Plugin devs: if you are using reflection to call this even though it's private, please use sendExitVehicle - instead which properly handles player culling. + If >0, this link was added by live config. - + - Does as few tests as possible while maintaining base game expectations. + Determines how a server that doesn't match any rules is handled. - + - Force remove player from vehicle they were in, if any. - Called when player disconnects to tidy up and run callbacks. + Include in the list. Default. - True if player was in a vehicle, false otherwise. - + - Remove player from vehicle and teleport them to an unchecked destination. + Exclude from list. (same as EServerListCurationDenyMode.Hide) - + - Handles culling if exit position is not visible to certain clients. - If adjusting how this works, PlayerLife.SendReviveTeleport may need revision. + Move to the bottom of the list. Similar to EServerListCurationDenyMode.MoveToBottom, but the server is + still clickable. I.e., low priority. - + - Is spawnpoint open for vehicle? + Called earlier during startup to try and have web lists ready by the time server browser is opened. - + - Try to find a random spawnpoint to spawn a vehicle while server is running. + Used to detect asset refresh. - + - Add a new vehicle at given spawnpoint. - Supports redirects by VehicleRedirectorAsset. If redirector's SpawnPaintColor is set, that color is used. + If true, list needs to be sorted. - + - Add a new vehicle at given spawnpoint and replicate to clients. - Supports redirects by VehicleRedirectorAsset. If redirector's SpawnPaintColor is set, that color is used. + If true, MergeRules should be called before doing any filtering. - + - Called when deciding whether to respawn a new vehicle, after gameplay has begun. + If false, LoadWebUrls still needs to be called. - + - Called during level load to determine how many vehicles to create. + Zero is treated as unset. - + - Called on server each frame to slowly damage abandoned vehicle. + Has a new announcement been posted by the developer? + If so, it is given priority over the featured workshop item. - + - +0 = InteractableVehicle - +1 = root transform - +X = VehicleBarricadeRegion - Asset does not know number of train cars, so we always reserve slack. + Called after newsResponse is updated from web request. - + - Speed is unsigned, so 8 bits allows a range of [0, 256). + Read News.txt file from Cloud directory to preview on main menu. - + - Velocity is signed, so 9 bits allows a range of [-256, 256). + Helper for handlePopularItemResults. + If player has not dismissed item at index then proceed with query and return true. - + - Cast a ray from the sky to find highest point. + Nelson 2024-04-23: A concerned player raised the issue that mature content could potentially be returned in + popular item results. Steam excludes certain mature content by default, but just in case, we check for these + words and hide if contained in title. - + - Cast a ray from slightly above point so indoor teleport nodes work. + Successfully queried popular workshop items. + Tries to decide on an item that player has not dismissed. - + - If set, we are responsible for destroying texture. + Response about the item we decided to display. - + - This is a bit of a hack in order to simplify the foliage menu when most of the time editors are either - manually placing foliage or automatically baking it. + Submit query for recently trending popular workshop items. - + - Get brush strength multiplier where strength decreases past falloff. Use this method so that different falloffs e.g. linear, curved can be added. + Entry point to deciding which workshop item is featured above recent announcements. - Percentage of . - + - Allows foreach loop to iterate Vector2Int within RegionBoundsInt. + Ensures workshop files are not refreshed more than once per main menu load. - + - Kept because lots of modders have been using this script in Unity, - so removing legacy effect id would break their content. + Represents whether a player can craft a provided blueprint. If yes, which items to use, if no, why not. + Previously, some of this data was (confusingly) stored in the blueprint definition. + For performance, caller should re-use a list of BlueprintStatus and *not* discard unused results. - + - Hack for modders using grenade component as a way to deal radial damage. Not a good long term solution but - widely requested for the meantime until I get the chance to rewrite some of the health stuff. + Total number of missing required nearby crafting tags. - + - Thanks to Glenn Fiedler for this RK4 implementation article: - https://gafferongames.com/post/integration_basics/ + Total required input item count minus available input item count. - + - Higher values return to the target position faster. + Currently only used by housing planner. + Doesn't work with NPC conditions / rewards. - + - Higher values reduce bounciness and settle at the target position faster. - e.g. a value of zero will bounce back and forth for a long time (indefinitely?) + Currently only used by housing planner. + Doesn't work with NPC conditions / rewards. - + - At low framerate deltaTime can be so high the spring explodes unless we use a fixed timestep. + Used to sort blueprints from "most craftable" (1) to "least craftable" (0). - + - Interactable storage barricade to spawn at the drop position. + Reset values set by PlayerCrafting.UpdateBlueprintDynamicStatus. - + - Prefab to spawn falling from the aircraft. + If not zero, use this amount instead of . + Used by as amount of ammo needed. - + - Initially these were structs so that they would be adjacent in memory and therefore faster to iterate lots of them, - but making them classes lets them reference each other which significantly simplifies finding adjactent housing parts. + If true, cancel updating status as soon as anything goes wrong. + False for client UI where all info about blueprint is needed for display. + True on server where extra processing is a waste. - + - Item along positive direction. - Can be multiple on existing saves or if players found an exploit. + If set, log errors here. - + - Item along negative direction. - Can be multiple on existing saves or if players found an exploit. + If true, SizeOffset_X and SizeOffset_Y are used when image is available. + Defaults to false. - + - Item between floors. - Can be multiple on existing saves or if players found an exploit. + If useImageDimensions is on and image width exceeds this value, scale down + respecting aspect ratio. - + - Is there a wall in this slot, and is it full height (not rampart)? + If useImageDimensions is on and image height exceeds this value, scale down + respecting aspect ratio. - - - This check prevents placing roof onto the upper edge of a rampart because ramparts - create an edge at full wall height even though they are short. - - Ideally in the future wall height will become configurable and remove - the need for this check. - - See public issue #3590. - - - + - Position at the base of the pillar. + Allows foreach loop to iterate Vector2Int within RegionBoundsInt. - + - Yaw if placing pillar at this vertex. + Not an actual Steam ID or BattlEye ID, instead this is used to map player references to and from BE. - + - Pillar or post currently occupying this slot. - Can be multiple on existing saves or if players found an exploit. + True for offline or listen server host. - + - Can be zero if pillar is floating, or up to six in the center of a triangular circle. + Next time method is allowed to be called. - + - Is there a pillar in this slot, and is it full height (not post)? + Number of times client has tried to invoke this method while rate-limited. - + - Floors must be placed touching the terrain, or a fake-terrain object like a grassy cliff model. + Get Steam item definition ID equipped for given vehicle. + True if a skin was available. - + - Pillars can be partly underground or inside a designated allowed underground area. Otherwise, - if the very top of the pillar is underground placement is blocked. (public issue #4250) + Build econ details struct from tags and dynamic_props. + Note that details cannot be modified because it's a struct and has copies of the data. - + - Side length of square and triangular floor/roof. - Walls can be slightly less, but we treat them as if they are the full length. + Add a recent ping sample to the average ping window. + Updates ping based on the average of several recent ping samples. + Most recent ping value. - + + True if both players exist, are both members of groups, and are both members of the same group. + + + True if both players exist, are both members of groups, and are both members of the same group. + + - Vertical distance from edge center to wall pivot. + Get real IPv4 address of remote player NOT the relay server. + True if address was available, and not flagged as a relay server. - + - Vertical distance from edge center to rampart pivot. + See above, returns zero if failed. - + - If position is nearly equal within this threshold then edges/vertices will connect. + Get real address of remote player NOT a relay server. + Null if address was unavailable. - + - Maximum distance from player's viewpoint to allow placement. + Get string representation of remote end point. + Null if address was unavailable. - + - How far to search for empty slot best match. + Players can set a "nickname" which is only shown to the members in their group. - + - Cosine of the angle between ray direction and direction toward slot must be greater than this. + Can be used by plugins to verify player is on a particular server. + + OnSteamAuthTicketForWebApiReceived will be invoked when the response is received. + Note that the client doesn't send anything if the request to Steam fails, so plugins may wish to kick + players if a certain amount of time passes. (e.g., if a cheat is canceling the request) - + - When validating item placement expand physics overlap this much. - Useful to ensure slightly-touching overlaps (e.g. pillar touching the pillar above) are handled properly. + Since this isn't accessible to plugins it isn't necessarily up-to-date. For example, when a player + teleports the culledPlayers list isn't updated until the next PlayerManager sync. If this becomes + publicly accessible in some way it should be kept in sync. - + - Ensure players, vehicles, zombies, animals, etc are not within this distance of pending placement. + Cast a ray from the sky to find highest point. - + - Distance from triangle pivot to apex of triangle. + Cast a ray from slightly above point so indoor teleport nodes work. - + - Radius of circle within triangle edges. + Recoil magnitude multiplier while the gun is aiming down sights. - + - Distance from triangle pivot to center of triangle. + Multiplier for gun's Aim_In_Duration. - + - Small threshold to allow placing even with existing barricades on the floor. + For backwards compatibility this is *subtracted* from the gun's firerate, so a positive number decreases + the time between shots and a negative number increases the time between shots. - + - House overlap is approximately the same size as the housing item's collider(s), and is intended to check whether - any pre-existing barricades or structural items are in the way. For example whether a wall cannot be placed because - there is a storage crate in the way, or if a foundation is blocked by another slightly rotated foundation. + Multiplier for normal bullet damage. - + - Character overlap is slightly larger than the house overlap, and checks whether any players, vehicles, animals, zombies, etc - are nearby. This is necessary because when house and characters were combined in a single physics query it was possible to - stand *just* close enough to step into the collider as it was spawned. + Multiplier for bullet acceleration due to gravity. - + - Called when a housing item is spawned or after moving an existing item. + Movement speed multiplier while the gun is aiming down sights. - + - Called before a housing item is destroyed or before moving a housing item. + If true, gun can damage entities with Invulnerable tag. Defaults to false. - + - Search grid for existing vertex at approximately equal position. - Considers adjacent grid cells if near cell boundary to avoid issues with floating point inaccuracy. + Name to use when instantiating attachment prefab. + By default the asset guid is used, but it can be overridden because some + modders rely on the name for Unity's legacy animation component. For example + in Toothy Deerryte's case there were a lot of duplicate animations to work + around the guid naming, simplified by overriding name. - + - Search grid for existing edge at approximately equal position. - Considers adjacent grid cells if near cell boundary to avoid issues with floating point inaccuracy. + Returns true if calibers list contains provided caliber ID. - + - Find existing edge and add connection, or add new empty edge. + Returns true if calibers list contains any of the provided caliber IDs. - + - Find existing vertex and add connection, or add new empty vertex. + If false this structure cannot take damage. - + - Find existing edge and set associated wall, or add an empty edge at wall's location. + Modded structures can disable pooling if they have custom incompatible logic. - + - Find slot occupied by wall and remove if no longer attached to anything. + Length of raycast downward from pivot to check floor is above terrain. + Vanilla floors can be placed a maximum of 10 meters above terrain. - + - Find existing vertex and set associated pillar, or add an empty vertex at pillar's location. + Optional alternative structure prefab specifically for the client preview spawned. - + - Find slot occupied by pillar and remove if no longer attached to anything. + Called on the dedicated server to optimize client prefab for server usage. - + - Hack to prevent ignoring floor which might be overlapping pending floor placement. - For example when placing a square floor on the opposite edge of a spot which has a triangular floor - we do not want to ignore the triangular floor during the physics query. + Invoked after any player's experience value changes (not including loading). - + - Used by triangular floor and roof validation to test for collisions. + Invoked after any player's reputation value changes (not including loading). - + - Ensure wall fits in an empty slot. + Hack to parse both the speciality enum and per-speciality skill enum given the name. - + - Ensure pillar fits in an empty slot. + Set every level to max and replicate. - + - Nelson 2024-06-26: With structure rotation replicated as a quaternion we need to be smarter about extracting - yaw from model transform. Quaternion.eulerAngles.y isn't necessarily the yaw anymore. + Serverside only. + Called when skills weren't loaded (no save, or in arena mode), as well as when reseting skills after death. - + - Working buffer for placement overlap tests. + Text from *.dat localization file. - + - Index of the context parameter, if not None. + Older *.content asset bundle reference. - + - Reflected attribute that was used to find this method. - Contains extra information about how to call it. + Newer *.masterbundle reference. - + - True once per frame, false otherwise. + Optional URL to open in web browser. - + - Item ID of barricade to spawn after landing. + Whether audio source should loop. - + - Barricade to spawn after landing. + Merges textures used in the level into an atlas to assist runtime draw call batching. - + - Cargo spawn table legacy ID. + Skip renderer children of these transforms, if any. + For example we skip lights with material instances and rubble debris. - + - Kill any players inside the spawned interactable box. - Uses hardcoded size of 4 x 4 x 4. + Most objects in Unturned use the standard shader without transparency/emissive/detail/etc. - + - Determines how to handle a server if it matches a rule. + Meshes we logged an explanation for as to why they can't be atlased. - + - Apply label and continue processing rules. + Textures we logged an explanation for as to why they can't be atlased. - + - Show the server in the list. + Materials we logged an explanation for as to why they can't be atlased. - + - Hide the server from the list. + Objects instantiated for the lifetime of the level that should be destroyed when exiting the level. - + - Note: Port (if set) refers to the Steam query port. + If true, don't assign texture atlas to material so batched materials are obvious. - + - If true, negate whether this rule matches. i.e., binary NOT. + If true, assign a red material to excluded meshes so they are obvious. - + - Incremented during server list refresh for each server blocked by this rule. + If true, replace each unique material with a colored one before static batching. - + - Optional image bundled alongside the asset file. + If true, log why texture/material can't be included in atlas. - + - If true the event will only be invoked in offline mode and on the server. + If true, log if mesh has UVs outside [0, 1] range. - + - Hack to prevent hitting volume rate limit because (at least as of 2022-05-24) we do not have an event for finished dragging. + We generate a 1x1 texture for materials without one. - + - Whether this animal was updated in this network tick and needs to be resent. + Tracks which mesh filters and skinned mesh renderers were referencing a given mesh. - + - Alert this animal that it was damaged from a given position. - Offensive animals investigate the position, whereas other animals run away. + Tracks which meshes and materials were referencing a given texture. - + - Alerts this animal that it needs to run away. + If true, UVs should be centered and overridden because original mesh was not textured. - The position to run away from. - + - Keep for plugin backwards compatibility. + Maps original mesh to any mesh filters using it. + When mesh's UVs are modified the mesh filters need to be pointed at the copied mesh. - + - Reduces frequency of UndergroundAllowlist checks because it can be expensive with lots of entities and volumes. + Renderers with a material using the texture. + After combining texture the renderers need to be pointed at the combined material. - - Unturned_Data folder path - - + - Useful to check whether hashing is causing problems. + Tracks which textures were referencing a given shader. - + - Useful to narrow down why a player is getting kicked for modified resource files when joining a server. + StaticBatchingUtility.Combine requires input renderers are enabled and active in hierarchy, + so we temporarily activate/enable them to keep this logic out of LevelObject/ResourceSpawnpoint. - + - Only set in play mode for determing if we should cache brute force lengths. + If -1, this region is finished activating/deactivating. + Otherwise, incremented once per frame until per-region count is reached. + + Per-region data is removed when isInsideMask is false and progressIndex is -1. - + - If set, road properties are taken from this asset instead of the older road properties editor. + If true, this region is within MaxDistance of current CameraCoord. - + - Checkered lines when occluded, solid lines when visible. + Tracks activation and deactivation of Regions as camera moves around the level. - + - Solid lines regardless of depth. + Mark all cells as finished loading and remove cells outside the camera view. + Used after teleporting or loading. - + - In-game debug drawing utility similar to Unity's editor Gizmos. + Caller passes an empty dictionary to be filled with update info. + Increments progressIndex for each returned region. + If region is finished updating, call NotifyRegionFinishedUpdating. - - Local space relative to matrix. - - + - Wireframe grid on the XZ plane. + Called when progressIndex has reached end of given region. - + - Center relative to matrix. + Fill output set with mask offsets applied to current camera coordinate. - + - Center relative to matrix. + Find changes between old and current coordinate sets to mark regions in/out of mask. - + - LateUpdate so that the most up-to-date gizmos and main camera position are used. + Reset region's progress counter and change inside/outside status. - + - Callback to draw in the Unity editor scene view. + If true, unlocking has failed. - + - Can be null if nothing has been added at position. + Called on barricade's Interactable after being placed into the world. (Not after loading or replication.) - + - Does not add new lists to empty cells. + Barricade asset's EBuild included in saves to fix state length problems. (public issue #3725) - + - Number of Lists to preallocate in batches. - (GRID_SIZE * GRID_SIZE) % LIST_POOL_SIZE should be zero leftover. - Reduces constructor performance cost. (public issue #4209) + Exposed for Rocket transition to modules backwards compatibility. - + - Matches the console behavior prior to command IO refactor. + Exposed for Rocket transition to modules backwards compatibility. - + - Add fuel to target. + Writable list of vehicle regions. Public add/remove methods should not be necessary. - + - Remove fuel from target. + Remove barricade instance on server and client. - + - Position to place players outside visible range. - Defaults to as far away as supported by default clamped Vector3 precision. - Doesn't use world origin because that would potentially increase rendering cost for clients near the origin. + Used by ownership change and damaged event to tell relevant clients the new health. - + - Whether local client is currently penalized for potentially using a lag switch. Server has an equivalent check which reduces - damage dealt, whereas the clientside check stops shooting in order to prevent abuse of inbound-only lagswitches. For example, - if a cheater freezes enemy positions by dropping inbound traffic while still sending movement and shooting outbound traffic. + Legacy function for UseableBarricade. - - - Will test player be culled for viewer at a given position? - - Members of the same group are always visible to each other. (Used by map and HUD name overlay.) - - Admins with the Spectator Overlay enabled are able to see all clients. - Similarly, plugins can set ServerAllowKnowledgeOfAllClientPositions to show all clients. - - Players in vehicles: - VehicleManager notifies all clients when a player enters a vehicle, so a client may know the player's - position even if this method suggests otherwise. When exiting the vehicle, CulledPosition is sent - instead of the real exit position to clients who should cull the new position. - - - + - Labels for named locations. + Common code between dropping barricade onto vehicle or into world. - + - Contains arena outer circle and inner target points. + Spawn a new barricade attached to a vehicle and replicate it. - + - Player avatars. + Spawn a new barricade and replicate it. - + - Arrow oriented with the local player. + Not an instance method because structure might not exist yet, in which case we cancel instantiation. - + - Convert level-space 3D position into normalized 2D position. + Destroy barricades whose pivots are within sphere. - + - Convert normalized 2D position into level-space 3D position. + Clean up before loading vehicles. - + - Temporary to unbind events because this class is static for now. (sigh) + Register a new vehicle as a valid parent for barricades. + Each train car is registered after the root of the train. + Note: why they are called "plants", refer to "only god and i" meme. - + - Manages render queue for transparent materials on non-stationary objects. - Updates one material per frame. + Called before destroying a vehicle GameObject because storage needed to be ManualDestroyed. - + - Callback when camera above/under water changes. + Send all vehicle-mounted barricades to client. + Called after sending vehicles so all plant indexes will be valid. - + - Material to use during the Christmas event instead. + Original server-only version that does not replicate changes to clients. - + - Material to use during the Halloween event instead. + Only used by plugins. Replicates state change to clients. - + - Material to use during the April Fools event instead. + Not ideal, but there was a problem because onLevelLoaded was not resetting these after disconnecting. - + - Nelson 2024-08-19: This link has been checked with WebUtils.CanParseThirdPartyUrl, but is not the - potentially altered link to go through Steam's link filter. This way the UI shows the original link. + Maps prefab unique id to inactive list. - + - Unturned wrapper for Debug.Log, Debug.LogWarning, Debug.LogError, etc. + Sending yaw only costs 1 bit (flag) plus yaw bits, so compared to the old 24-bit rotation we may as well + make it high-precision. Quaternion mode uses 1+27 bits! - + - Log an exception with message providing context. + +0 = BarricadeDrop + +1 = root transform + +2 = Interactable (if exists) - + + true if key existed and was removed. + + + true if key existed and was removed. + + - Recursively logs inner exception. - - Should only be called by itself and exception because notifications - to CommandWindow would otherwise get re-sent here as errors. + Unturned equivalent of unity's PlayerPrefs. + Convenient for saving one-off key-value pairs. - + - This is the ONLY place Unturned should be binding logMessageReceived. + Full argument string. Defaults to Environment.CommandLine. + + Nelson 2025-06-17: By default, Steam shows a warning nowadays when the game is launched with externally-provided + command-line arguments. For example, when joining a friend via rich presence. The solution is to use the arg + string provided by SteamApps.GetLaunchCommandLine, which also supports *changing* the arguments while the app is + running. If the environment-provided command-line doesn't contain it, the game will append Steam's launch options. - This gives us greater control over how logging is handled. In particular, Unity's - headless builds route logs (including stack traces) through stdout which is undesirable - for dedicated servers, so we only call Debug.Log* in the editor and development builds. + Note: Steam override isn't applied until Steam is initialized. (after Dedicator and ModuleManager) Please refer to + Setup.cs for the full initialization order. - + - Log an exception with message providing context. + Nelson 2025-06-16: Steam doesn't handle "server code" connect URL, but we now support + it for rich presence joins via server code for easier inviting friends to private servers. + + When Steam parses a steam://connect/ip:port URL it requires the query port (e.g. 27015). - + + + Handles these cases: + key value -> value + key=value -> value + key = value -> value + key = value -> value + key "value with spaces" -> value with spaces + key "value with \" quotation marks" -> value with " quotation marks + + Tested in CommandLineTests.cs + + + - Get SteamID of vehicle's driver, or nil if not driven. + Nelson 2025-04-08: newer code should probably use CachingAssetRef instead. (Or CachingLegacyAssetRef if legacy + ID support is necessary.) - + - Crashed into something, if applicable take self damage from collision. + Whether the asset has been assigned. Note that this doesn't mean an asset with exists. - + - Remove all color rich formatting so that shadow text displays correctly. + Is this asset not assigned? - + - Shadow text needs the color tags removed, otherwise the shadow uses those colors. + True if resolving this asset reference would get that asset. - + - Wrap text with color tags. + Resolve reference with asset manager. - + - Wrap text with color tags. + GUID of the asset this is referring to. - + - Wrap text with color tags. + Whether this animal was updated in this network tick and needs to be resent. - + - Replace br tags with newlines. + Alert this animal that it was damaged from a given position. + Offensive animals investigate the position, whereas other animals run away. - + - Should player be allowed to write given text on a sign? - Keep in mind that newer signs use TMP, whereas older signs use uGUI. + Alerts this animal that it needs to run away. + The position to run away from. - + - Disable style, align, and space because they make server list unfair. + Keep for plugin backwards compatibility. - + - 2023-01-25: fixing killing self with explosive to track kill under - the assumption that this is only used for tracking stats. (public issue #2692) + Reduces frequency of UndergroundAllowlist checks because it can be expensive with lots of entities and volumes. - + - "Single-Render" scope as opposed to "Dual-Render" (rendering the scene a second time with a zoomed-in camera). - Blits middle square of the player's view into the viewmodel scope material's render target. + Optional Unturned extensions to the LOD Group component. - + - Finds an existing "{{Cargo/name" (if any), otherwise adds a new one. + Could be extended, e.g. to clamp cull size separately from the per-LOD sizes. - + - Adds a new "{{Cargo/name" even if one already exists. + Unturned will adjust per-LOD sizes to counteract LOD bias. + Some maps have very carefully tuned LOD sizes, so LOD bias affecting them is undesirable. + Note that due to a Unity bug only LOD0 can be greater than 100%. - + - Helper for wiki writers to dump game data into a useful format. + Allows Unity events to spawn effects. - + - Non-item replacement for SleekJars. - Arranges children in an equally-spaced ring around the center. + GUID of effect asset to spawn when SpawnDefaultEffect is invoked. - + - Actual unfiltered text. - Kept because plugins might be referencing, and game should use directly once state byte array is refactored. + If true the server will spawn the effect and replicate it to clients, + otherwise clients will predict their own local copy. - + - If profanity filter is enabled this filtered text is displayed on the 3D sign and in the note UI. - Null or empty on the dedicated server. + Should the RPC be called in reliable mode? Unreliable effects might not be received. - + - Legacy uGUI text on canvas. + Transform to spawn the effect at. + If unset this game object's transform will be used instead. - + - Legacy uGUI text on canvas. + Applied if greater than zero. Defaults to 128. - + - Splits string and compares substrings ignoring case. - Tokens containing a colon ':' are ignored so that they can represent special filters like MasterBundleSearchFilter. + Invoked when web item is first loaded or reloaded. - + - If true, spawn effect at player's position (rather than Spawnpoint). + Spawns an animal into the world. + The ID of the animal. + Position to spawn the animal. + Angle to spawn the animal. + Whether the animal is dead or not. - + - Should the RPC be called in reliable mode? Unreliable effects might not be received. + Gets the animal at a specific index. + The index of the animal. + - + - Applied if greater than zero. Defaults to 128. + Find replacement spawnpoint for an animal and teleport it there. - + - Extra text added to tooltip. + Used in arena mode to reset all animals to dead. - + - Internal struct menu uses to sort items in box. + Exposed for Rocket transition to modules backwards compatibility. - + - Item definition id. + False if time since this was last called with same cooldownId is less than duration. + True otherwise. - + - Rarity used to sort mythical > legendary > epic > rare. + Find difficulty asset (if valid) for navigation bound index. - + - [0, 1] calculated chance of this item being unboxed. - Shown to player in item tooltips. + Allows level to override whether per-table or per-navmesh difficulty asset takes priority. - + - Sorts box entries from highest to lowest rarity. + Could potentially be reused generically. - + - Format qualityRarities as ##.# - Does not use 'P' format because localized strings unfortunately already had % sign. + When zombie falls outside the map it needs a replacement spawnpoint within the same navmesh area. - + - Items server told us we unboxed, but we wait for the animation to finish before showing. - Typically one, but some newer boxes have bonus items occassionally. + Find replacement spawnpoint for a zombie and teleport it there. - + - Is one of the unboxed items mythical rarity? + Kills night-only zombies at dawn. - + - Items in the box. + Checkered lines when occluded, solid lines when visible. - + - Skip unboxing animation. - Initial call rotates to just before the item, next call skips entirely. + Solid lines regardless of depth. - + - Does client know about all the granted items? - If not, either something is bad in the econ config (uh oh!) or client is out of date. + In-game debug drawing utility similar to Unity's editor Gizmos. - + + Local space relative to matrix. + + - Relatively efficiently find mesh components, and log an error if their mesh is missing, among other checks. + Wireframe grid on the XZ plane. - + - Unity warns about renderers registered with more than one LOD group, so we do our own validation as part of - asset loading to make it easier to find these. + Center relative to matrix. - + - Replaced by ServerMethodHandle. + Center relative to matrix. - + - Replaced by ClientInstanceMethod.InvokeAndLoopback or ClientStaticMethod.InvokeAndLoopback. + LateUpdate so that the most up-to-date gizmos and main camera position are used. - + - Replaced by ClientMethodHandle invoked with Provider.EnumerateClients_Remote. - Unlike ESteamCall.CLIENTS this is not loopback invoked. + Callback to draw in the Unity editor scene view. - + - Replaced by ClientMethodHandle invoked with SteamChannel.GetOwnerTransportConnection. + Determines how the "Explosion" effect is spawned when a barricade or structure is destroyed. + + Nelson 2025-09-08: although explosion effect currently exists in Barricade and Structure + sub-classes I think it makes sense to share this option (and ideally more in future). - + - Replaced by ClientMethodHandle invoked with SteamChannel.EnumerateClients_RemoteNotOwner. + Legacy behavior. - + - Replaced by ClientMethodHandle invoked with Provider.EnumerateClients. - Unlike ESteamCall.OTHERS this will be loopback invoked in singleplayer or listen server. + Effect spawns exactly at the model position without any offset. - + - May have been used by voice in early versions, but has been completely removed. + Effect spawns with same rotation as the model. - + - Parses -X=Y from command-line. - Ideally we could do "where T : TryParse" but for the meantime there are specialized subclasses. + Common base for barricades and structures. + 2023-01-16: not ideal to be adding this so late in development, but at least it is a step in the right direction. - + - Maps region coord to a list of sub-road renderers in that region. - Unlike older "region" features, coord can be outside of the old bounds. - Not used in the editor or the dedicated server. - - Nelson 2025-03-28: experimenting with this to see whether it reduces time spent culling far-away road - renderers on Rio de Janeiro Remastered. (Lots of roads on this map.) + If true, this item is eligible for zombies to detect and attack when stuck. + Defaults to true. - + - Max draw distance outside editor. + Item or spawn table recovered when picked up below 100% health. - + - Called by navmesh baking to complete pending object changes that may affect which nav objects are enabled. + Minimum number of items to recover when salvaged. - + - Allows Unity events to broadcast Event NPC rewards. + Maximum number of items to recover when salvaged. - + - Event ID to use when SendDefaultEventId is invoked. + Minimum number of items to drop when destroyed. - + - The event messenger can only be triggered on the authority (server). - If true, the server will replicate the event to clients. + Maximum number of items to drop when destroyed. - + - Interface between the dedicated server command I/O and per-platform console. + Item or spawn table dropped when destroyed. - + - Called when this implementation is setup by command window. + If non-null, this asset provides the listed crafting tags to nearby players. - + - Called when this implementation is deleted or application quits. + Note: this assumes SalvageItemRef points to an ItemAsset. - + - Called each Unity update. + By default a crafting ingredient is salvaged. - + - Broadcasts when the enter key is pressed. + Load {Language}.dat and/or English.dat from folder path. - + - Print white message. + Default. Create a material instance for child renderer of Toggle game object. + Downside of this is exclusion from level batching texture atlas. - + - Print yellow message. + Object does not have any toggleable emissive materials. - + - Print red message. + Prevents calling getOrLoad redundantly if asset does not exist. - + - July 7th! + If set, overrides model prefab in the level editor. - + - This is the only /required/ override of text writer. + Clip.prefab - + - Can be added to certain entities to modify which crafting tags they make available to players. - At the time of writing (2025-04-08) the compatible entities are: - • Barricade - • Structure - • Vehicle - • Resource - • Object + Object.prefab - + - Each specified component modifies tags. + If true, object will be hidden when rendering GPS/satellite view. + Defaults to true if is set. - + - If true then level should convert old node types to volumes. + If true, Nav game object will be instantiated in singleplayer and on dedicated server. Useful for objects + which need to affect navmesh baking without colliding with zombies during gameplay. + Defaults to true for "medium" and "large" objects. - + - If true then level should convert old non-volumes types to devkit objects. + If true, Nav game object will be instantiated in the level editor. Useful for objects which need collision + with zombies during gameplay without affecting navmesh baking. + Defaults to true for "medium" and "large" objects. - + - Hash of nodes file. - Prevents using the level editor to make noLight nodes visible. + Should landing on this object inflict fall damage? - + - Code common to and . + If true, object is not loaded when clutter is turned off in graphics menu. - + - Nelson 2025-05-13: replacing the "workshop request log" which used transport connection hash code with this - more recent IP address and Steam ID rate limiter. + Property is not exposed at the moment because interactability properties should really be moved into some + sort of sub-asset. - + - Manually placed from the asset browser or old editor. + Same as interactabilityDialogueRef, not public because it really needs to be cleaned up. :( - + - Spawned by foliage baking system. + If set, overrides objectName as character name in dialogue. - + - Brushed on with the foliage tool. + Effect played when single segment is destroyed. - + - Utilities for calling workshop functions without worrying about client/server. - This could be nicely refactored into a client and server interface, but not enough time for that right now. + Effect played when all segments are destroyed. - + - Client/server safe version of GetQueryUGCNumKeyValueTags. + Weapon must have matching blade ID to damage object. + Both weapons and objects default to zero so they can be damaged by default. - + - Client/server safe version of GetQueryUGCKeyValueTag. + [0, 1] probability of dropping any rewards. - + - Search for the value associated with a given key. + If true, zombies can attack this object if it's blocking them. Defaults to false. - - - Client/server safe version of GetQueryUGCResult. - + + + Multiplier for damage from zombies if RubbleCanZombiesDamage is true. + - + - Is file banned? + Controls how rubble affects Nav game object. - + - Originally this was only in the uGUI implementation, but plugins can create uGUI text fields - regardless of which glazier is used. + If set (>0), alerts nearby entities when an individual section is destroyed. - + - Stockpile item definition id with rev-share for the level creators. - Randomly selected from associated items list. + If set (>0), alerts nearby entities when all sections are destroyed. - + - Other menus can modify DevkitSelectionToolOptions so we need to sync our menu when opened. + If true, all sections respawn at the same time. - + - Exposed for Rocket transition to modules backwards compatibility. + Should colliders in the Triggers GameObject with "Kill" name kill players? + If Triggers GameObject is not set, searches Object instead. - + - Remove structure instance on server and client. + Should this object only be visible if gore is enabled? + Allows pre-placed blood splatters to be hidden for younger players. - + - Used by ownership change and damaged event to tell relevant clients the new health. + Only activated during this holiday. - + - Legacy function for UseableStructure. + Object to use during the Christmas event instead. - + - Spawn a new structure and replicate it. + Object to use during the Halloween event instead. - + - Not an instance method because structure might not exist yet, in which case we cancel instantiation. + Get asset ref to replace this one for holiday, or null if it should not be redirected. - + - Not ideal, but there was a problem because onLevelLoaded was not resetting these after disconnecting. + If any conditions use flags they will be added to a set, + otherwise null is returned. - + - Maps prefab unique id to inactive list. + Recursively change all children including root from oldTag to newTag. + Aborts if a child doesn't match the old tag because it might be something we shouldn't change the tag of. + True if tags were all successfully changed. - + - Sending yaw only costs 1 bit (flag) plus yaw bits, so compared to the old 24-bit rotation we may as well - make it high-precision. Quaternion mode uses 1+27 bits! + Recursively change all children including root from oldLayer to newLayer. + Aborts if a child doesn't match the old layer because it might be something we shouldn't change the layer of. + True if layers were all successfully changed. - + - +0 = StructureDrop - +1 = root transform + Called if we have a valid Nav GameObject. + Recast requires any meshes used on the Nav objects to be CPU readable, so we log errors here if they're not marked as such. - + - Invoked when askUseObjectQuest succeeds. + Calculate damage multiplier for individual bullet. - + - When a client method is called on a target object that does not exist yet this class is responsible for - deferring the invocation until the instance does exist. For example until finished async loading. + Each shot has a percentage chance to hit the target. Higher values are more likely to hit. e.g., it + decreases from 1.0 at point blank to 0.0 at the weapon's maximum range. This chance is affected by the + gun's spread. - + - Called by generated methods when target object does not exist. If target object has been marked deferred - then the method will be invoked after it exists. + Implemented by components to support taking damage from explosions. + Not intended for external use (yet?) and may need to change. - + - Add list of deferred invocations for key. Otherwise messages will be discarded assuming it was canceled. + Used to exclude dead entities from further evaluation. - + - Remove pending invocations. + Used to sort damage from nearest to furthest. - + - Invoke all deferred calls. + Intended for internal use only. - + - Invocations are grouped by net id block to ensure order is preserved between related objects. + Data that we pool to reduce allocations, but needs to be separate per-invocation of explosion in case it's + invoked recursively. (for example, by blowing up a vehicle) - + - Not a member of ClientMethodInfo because it does not need to be looked up using reflection. + Replacement for playerDamaged. - + - Called before loading level. + Replacement for zombieDamaged. - + - Update currency and owned items if inventory has changed and menu is open. + Replacement for animalDamaged. - + - Update currency or experience depending what the vendor accepts. + Refer to ExplosionPoolData for pooling explanation. - + - Nelson 2025-06-10: new code should favor Vector2Int. We don't want to introduce further uint8 region usage. + Was necessary when structures were children of level transform. - + - Get net ID only if transform is directly registered, not if transform is the child of a registered transform. + Was necessary when trees were children of ground transform. - + - Log every registered pairing. + Somewhat hacked-together to find owner of a vehicle, barricade, or structure descendant. + Checks each IOwnershipInfo up the hierarchy until one returns true. - + - Called before loading level. + Get average explosionArmor of player's equipped clothing. - + - Reverse pairing specifically for building net id + relative path name. + Refer to getPlayerExplosionArmor for explanation of total/average. - + - Write header common to both static and instance methods, and return writer. + Do damage to a zombie. - - - Valid when opened in Begin or End mode. - - If the quest is ready to complete the UI is opened in End mode to allow - the player to see what rewards they will receive after clicking continue. - Otherwise, in Begin mode the UI is opened to allow the player to review - the conditions before accepting or declining the request. - - If the player cancels the pending response is NOT chosen. - - - + - Valid when opened in Begin or End mode. - The player clicked pendingResponse in this dialogue to open the quest UI. + Legacy function replaced by damageZombie. - + - It is useful to be able to reference transforms generically over the network, for example to attach a bullet - hole to a tree or vehicle without tagging it as a tree or vehicle, but most entities placed in the level do not - have unique IDs. To work around this we count downward from uint.MaxValue for level objects to avoid conflicts - with server-assigned net ids. + Legacy function replaced by damageZombie. - + - Nelson 2025-06-10: this is used by older level file formats, but with placement of trees outside legacy - bounds now supported we use only the index in that case with GetTreeNetIdV2. - - Each region can have ushort.MaxValue trees, and we reserve that entire block so that a region can be slightly - modified on the client or server without breaking all netids in the level. + Do damage to an animal. - + - Each region can have ushort.MaxValue objects, and we reserve that entire block so that a region can be slightly - modified on the client or server without breaking all netids in the level. + Legacy function replaced by damageAnimal. - + - Devkit instance IDs should already be fairly stable. There is no way any level is using more than 30 bits - for the instance ID, so it should be safe to set those bits to prevent collisions with server net IDs. + Legacy function replaced by damageAnimal. - + - Struct interface so that for transient asset bundles (older workshop mods) they can be preloaded - and retrieved as-needed, but for master bundles the asset loading can be deferred until needed. + This unwieldy mess is the original explode function, but should be maintained for backwards compatibility with plugins. - + - Legacy implementation that preloads assets. + Used if explosion won't damage anything. - + - Save a reference to an object in the asset bundle, but defer loading it until requested by game code. + Do radial damage. - + - Has a new announcement been posted by the developer? - If so, it is given priority over the featured workshop item. + Server spawn impact effect for all players within range. - + - Called after newsResponse is updated from web request. + Server spawn impact effect for all players within range. Optional "spectator" receives effect regardless of distance. - + - Read News.txt file from Cloud directory to preview on main menu. + Server spawn effect by ID for all players within range. Optional "spectator" receives effect regardless of distance. - + - Helper for handlePopularItemResults. - If player has not dismissed item at index then proceed with query and return true. + Server spawn effect for all players within range and instigator receives effect regardless of distance. - + - Nelson 2024-04-23: A concerned player raised the issue that mature content could potentially be returned in - popular item results. Steam excludes certain mature content by default, but just in case, we check for these - words and hide if contained in title. + parent should only be set if that system also calls ClearAttachments, otherwise attachedEffects will leak memory. - + - Successfully queried popular workshop items. - Tries to decide on an item that player has not dismissed. + Used to test whether player can fit in a space. + Includes terrain because tested capsule could be slightly underground, and clip to prevent exploits at sky limit. - + - Response about the item we decided to display. + Used for third-person camera in vehicle. + Does not include resource layer because attached barricades are put on that layer. + Barricades layer itself is included to prevent looking inside player bases. - + - Submit query for recently trending popular workshop items. + Used to test whether player can enter a vehicle. + Does not include resource layer because attached barricades are put on that layer. - + - Entry point to deciding which workshop item is featured above recent announcements. + 2023-02-02: adding more layers since splatter can be attached to them now. + parent should only be set if that system also calls ClearAttachments, otherwise attachedEffects will leak memory. - + - Ensures workshop files are not refreshed more than once per main menu load. + Layer mask for CharacterController overlap test. - + - Synchronize widgets with their values. + Layer mask for CharacterController overlap test while inside landscape hole volume. - + - Represents an item the vendor is buying from players. + Lightning strike raycasts from sky to ground using this layer mask. - + - Zero is treated as unset. + If non-zero, NPC name is shown as ??? until bool flag is true. - + - Has the contained been animated into visibility on-screen? - Used to disable animating out if disabled. + Time.time damage was last dealt so that damage is applied once per second. - + - Allow Unity events to forcefully remove any barricades inside a sphere. + Timer increased while taking damage, and reset to zero while inside zone. - + - Prevents static member from being initialized during MonoBehaviour construction. (Unity warning) + Current position. - + - Mesh Replacement Details - .dat Flags: - Has_1P_Character_Mesh_Override True Bool - Character_Mesh_3P_Override_LODs # Int - Has_Character_Material_Override True Bool - Asset Bundle Objects: - Character_Mesh_1P_Override_# GameObject with MeshFilter (mesh set to a skinned mesh) - Character_Mesh_3P_Override_# GameObject with MeshFilter (mesh set to a skinned mesh) - Character_Material_Override Material + Exposed for Rocket transition to modules backwards compatibility. - + - Replacements for the main 1st-person character mesh. + Is the active level an Arena mode map? - + - Replacements for the main 3rd-person character mesh. + Find a new smaller circle within the old circle and clamp it to the playable level area. - + - Replacement for the main character material that typically has clothes and skin color. + Pick a random airdrop node appropriate for the game mode. - + - Sort servers by name A to Z. + Nelson 2025-04-01: default position intBitCount of 13 has range of [-4096, 4096), but on "insane" size maps + the aircraft starts 2 km outside that range. This causes the care package to spawn at the wrong position. + Bumping intBitCount to 14 enables a range of [-8192, 8192). (public issue #4972) - + - Sort servers by name Z to A. + Exit button only needs to wait for timer in certain conditions. - + - Sort servers by map name A to Z. + Should only be used by . + For example: "Condition_##" where ## is an index. - + - Sort servers by map name Z to A. + If >0 the game will start a coroutine to grant the reward after waiting. - + - Sort servers by player count high to low. + If true and player has this reward pending when they die or disconnect it will be granted. - + - Sort servers by player count low to high. + Intended to replace filling data from constructor. - + - Sort servers by max player count high to low. + Intended to replace filling data from constructor. Legacy is for backwards compatibility with Reward_#_Key + format, whereas V2 uses the list and dictionary features. - + - Sort servers by max player count low to high. + Allows Unity events to modify which crafting tags are provided by owning object. + Must be connected to a Crafting Tag Provider. - + - Sort servers by normalized player count high to low. + GUIDs of Unturned tag assets to modify. - + - Sort servers by normalized player count low to high. + Add listed tags to provided tags. - + - Sort servers by ping low to high. + Remove listed tags from provided tags. - + - Sort servers by ping high to low. + Apply only if this component is active and enabled. - + - Information about a game server retrieved through Steam's "A2S" query system. - Available when joining using the Steam server list API (in-game server browser) - or querying the Server's A2S port directly (connect by IP menu), but not when - joining by Steam ID. + Apply only if this component is inactive and/or disabled. - + - Join server by IP. + Always apply. - + - Server is not using an anycast proxy. + Get wrapper method rather than Awake because component might be inactive but should still apply modifiers. - + - Server host indicated an anycast proxy is in use. + Entry in the MenuPlayServerBookmarksUI list. - + - Moderator flagged server as using an anycast proxy. (EHostBanFlags.QueryPingWarning) + GUID of the asset this is referring to. - + - Ping time measured in milliseconds. + Whether the type has been asigned. Note that this doesn't mean an asset with exists. - + - ID of network transport implementation to use. + True if resovling this type reference would get that type. - + - Known plugin systems. + Get real IPv4 address of remote player NOT the relay server. + True if address was available, and not flagged as a relay server. - + - Probably just checks whether IP is link-local, but may as well use Steam's utility function. + See above, returns zero if failed. - + - Active player count divided by max player count. + Invoked when askUseObjectQuest succeeds. - + - Nelson 2024-08-20: This score is intended to prioritize low ping without making it the be-all end-all. The - old default of sorting by ping could put near-empty servers at the top of the list, and encouraged using - anycast caching to make the server appear as low-ping as possible. + Allows Unity events to startle nearby animals and zombies. - + - Nelson 2024-08-20: This score is intended to prioritize servers around 75% capacity. My thought process is - that near-empty and near-full servers are already easy to find, but typically if you want to play online you - want a server with space for you and your friends. Unfortunately, servers with plenty of players but an even - higher max players make a 50% score plenty good. + Transform to spawn the alert at. + If unset, this game object's transform will be used instead. - + - Nelson 2024-08-20: This score is intended to balance out the downside of the fullness score decreasing for - servers with very high max player counts, and over-scoring servers with low max players. + If true, find the nearest player within ScanForPlayersRadius, and use the player's position as the alert + origin. - + - Called before inserting to server list. + If UseScanForPlayers is enabled and this is true, an alert is broadcast even if no nearby player was found. + Otherwise, alert is ignored if no nearby player was found. - + - Parses value between two keys thing would parse thing + Index into per-connection rate limiting array. - + - If set, this server was denied by a server curation list. + Number of server methods with rate limits. - + - Disables Unity native systems unused by Unturned. + Log all known net methods. - + - Enabled for effects held by guns and sentries. + Useful debug check to ensure every built-in handle is claimed exactly once. - + - Listen for OnDestroy callback because mods may be destroying themselves in unexpected ways (e.g., Grenade - component) and still need to be cleaned up. + This class gets used from type initializers, so Unity's built-in log is not an option unfortunately. - + - Seconds after placement before damage can be dealt. + Not *really* supported but *might* probably work. Adding for public discussion #4176. - + - Seconds interval between damage dealt. - i.e., will not cause damage if less than this amount of time passed since the last damage. + Manages lifetime and attachment of a mythical effect. Added by . + Was called `MythicLocker` with a paired `MythicLockee` prior to 2024-06-11. - + - UITK implementation consists of a container element which respects the regular position and size - properties, and a child content element which fits itself in the container. + Every time the inventory changes this number is incremented. + While a little messy, the idea is to prevent inventory checks from happening every frame. - - Start Vertex - Start Vertex + Start Tangent - End Vertex + End Tangent - End Vertex - - - Start Vertex - Start Vertex + Start Tangent - End Vertex + End Tangent - End Vertex - - - Start Vertex - Start Vertex + Start Tangent - End Vertex + End Tangent - End Vertex - - - Start Vertex - Start Vertex + Start Tangent - End Vertex + End Tangent - End Vertex - World units length along curve. - Spacing between points. - Max estimate distance from uniform interval before we have to retry. - How many times to retry if the estimate is too far off. - If length is already known pass it in, otherwise it's recalculated. - Time along curve. [0-1] - - - Start Vertex - Start Vertex + Start Tangent - End Vertex + End Tangent - End Vertex - Spacing between points. - Max estimate distance from uniform interval before we have to retry. - How many times to retry if the estimate is too far off. - - + - Single percentage randomness with two outcomes. + Should be called every time something changes in the inventory. - + - If true the event will only be invoked in offline mode and on the server. + Helper to prevent checking the inventory every frame for systems that don't use events. - + - Percentage chance of event occurring. + Did owner call askInventory yet? + Prevents duplicate tell_X RPCs from being sent to owner prior to initial sync. + Ideally should be cleaned up with netcode refactor. (Client should not need to ask server for initial state.) - + - Invoked when random event occurs. + Intended as nearly a drop-in replacement for . - + - Invoked when random event does NOT occur. + Intended as nearly a drop-in replacement for . - + - Whether the pointer is currently in a spot that can be painted. + Intended as nearly a drop-in replacement for . - + - Get brush strength multiplier where strength decreases past falloff. Use this method so that different falloffs e.g. linear, curved can be added. + Intended as nearly a drop-in replacement for . - Percentage of . - + - Allows pooling elements. - If set, this is called rather than removing element from scroll view. + Intended as nearly a drop-in replacement for . - + - Kind of hacky... Used by player list for group connections. + Intended as nearly a drop-in replacement for . + This variant wraps FindFirstItemByAsset and manages the results list for you. + Only use result if true is returned, otherwise it's invalid. - + - Read commands from standard input, and write logs to standard output. + Intended as nearly a drop-in replacement for . + This variant wraps FindFirstItemByAsset and manages the results list for you. - + - Broadcast the inputCommited event. + Helper for tryAddItemAuto. - + - Synchronize console's title bar text. - Virtual because at one point Win32 SetTitleText was required. + Given an item coordinate (page, x, y) could a new item take the place of an old (existing) item without + overlapping other item(s) space? Always true for equipment slots (page less than SLOTS). + For example if oldSize is (1, 2) rot 0, and newSize is (2, 1) rot 1, then they can swap. - + - Intercept the Ctrl-C or Ctrl-Break termination. + Swap coordinates of two existing items. + Rotation is provided to handle differently shaped items e.g. a 1x2 item with a 2x1 item. - + - Handle Ctrl-C or Ctrl-Break on the game thread. + Swap coordinates of two existing items. + Rotation is provided to handle differently shaped items e.g. a 1x2 item with a 2x1 item. - + - Has Ctrl-C or Ctrl-Break signal been received? + Called from player movement to close storage that has moved away. - + - Is the Ctrl-C or Ctrl-Break signal being handled? + Serverside open a storage crate and notify client. - + - Names of achievements that can be granted by NPC rewards. + Serverside grant access to car trunk storage and notify client. - + - Name of promo level to additively load. + Serverside revoke trunk access and notify client. - + - UTC when to begin load promo level. + Called on both client and server, as well as by storage itself when destroyed. - + - UTC when to stop loading promo level. + Please use SearchContents instead! To perform an equivalent search: + • Set IncludeEquipmentSlots to false. + • Set IncludeActiveStorageContainer to false. + • Set ItemType to type. + • Set IncludeEmpty to false. + • Set IncludeMaxQuality to true. + OR use the nearly drop-in replacement FindItemsByType. - + - Folder name of the map when it was in the game. + Please use SearchContents instead! To perform an equivalent search: + • Set IncludeEquipmentSlots to false. + • Set IncludeActiveStorageContainer to false. + • Set ItemType to type. + • Set IncludeEmpty to false. + • Set IncludeMaxQuality to true. + • Set AnyCaliberIds to calibers. + • Set IncludeUnspecifiedCaliber to allowZeroCaliber. + OR use the nearly drop-in replacement FindAttachmentsByCaliber. - + - Published steam id for the file after it was moved to the workshop. + Please use SearchContents instead! To perform an equivalent search: + • Set IncludeEquipmentSlots to false. + • Set IncludeActiveStorageContainer to false. + • Set ItemType to type. + • Set IncludeEmpty to false. + • Set IncludeMaxQuality to true. + • Set CaliberId to caliber. + • Set IncludeUnspecifiedCaliber to allowZeroCaliber. + OR use the nearly drop-in replacement FindAttachmentsByCaliber. - + - Dependencies to subscribe to when subscribing through the in-game menu. - e.g. Hawaii's assets are stored separately on the workshop. + Please use SearchContents instead! To perform an equivalent search: + • Set IncludeEquipmentSlots to false. + • Set IncludeActiveStorageContainer to false. + • Set AssetRef to id. + • Set IncludeEmpty to findEmpty. + • Set IncludeMaxQuality to findHealthy. + OR use the nearly drop-in replacement FindItemsByAsset. - + - Only applies if player is not subscribed to the workshop file. - Should an advertisement be shown in the Menu > Singleplayer > Curated list? + Please use SearchContents instead! To perform an equivalent search: + • Set IncludeEquipmentSlots to true. + • Set IncludeActiveStorageContainer to true. + • Set MaxResultsCount to 1. + • Set AssetRef to id. + • Set IncludeEmpty to false. + • Set IncludeMaxQuality to true. + OR use the nearly drop-in replacements FindFirstItemByAsset or HasItemByAsset. - + - Published steam id to subscribe to. + Get index within bounds assuming list is not empty. - + - If logging in after this point, subscribe. + Add a new item using its default constructor. - + - If logging in before this point, subscribe. + In-game rich text does not support embedded YouTube videos, but they look great in the web browser, + so we simply remove them from the in-game text. - + - Maps not installed by default, but recommended from maps list. + Unfortunately in-game rich text does not have code formatting yet, so remove the tags while preserving text. - + - Maps to install to automatically. - Used early in startup to hopefully install before reaching main menu. + Multiplier to incoming damage. Defaults to 1.0. - + - When moving between physics materials we need to continue any previous tire kickup particles until they expire. - This class manages the individual effect per-physics-material. Each wheel can have multiple at once. When the - particles have despawned and the effect is no longer needed, the effect game object is returned to the effect - pool and this class is returned to . + Multiplier to explosive damage. Defaults to value if Armor_Explosion isn't specified. - + - Name from . + Armor against falling damage. Defaults to 1.0, i.e., take the normal amount of damage. - + - Instantiated effect. Null after returning to pool. + If true on any worn clothing item, bones never break when falling. + Defaults to false. - + - Effect's transform. Null after returning to pool. + Left-handed character skeleton is mirrored, so most item models are mirrored again to preserve appearance. + Unfortunately this does not work well for some items e.g. the particle system on Elver/Dango glasses. - + - Component on gameObject. Null after returning to pool. + Sound to play when equipped. - + - Whether this effect should be emitting particles. False stops the particle system immediately, whereas true - only starts playing on the next frame to avoid filling a gap between positions, e.g., after a jump. + If set, find a child meshrenderer with this name and change its material to the character skin material. - + - Prevents repeated lookups if asset is null, while allowing asset to be looked up each time this effect - becomes active so that it can be iterated on without restarting the game. + The player can be wearing both a "real" in-game item and a cosmetic item in the same clothing slot. + If true, the real item is shown rather than the cosmetic item. For example, night vision goggles + are shown over any glasses cosmetic because of their gameplay-related green glow. - + - Does this wheel affect brake torque? + Overrides value of TakesPriorityOverCosmetic if is true. - + - Turn on/off physics as needed. Overridden by isAlive. + If true, the value of is used rather than . + Defaults to false. True if is set. - + - [0.0, 1.0] normalized position of wheel along suspension. + For 3D clothes. Ideally, this wouldn't be type specific, but we have a separate prefab property for each + type of clothing at the moment. - + - [0.0, 1.0] normalized position animated toward replicatedSuspensionState. + The player can be wearing both a "real" in-game item and a cosmetic item in the same clothing slot. + This is called on the real item if has not been set. + If true, the real item is shown rather than the cosmetic item. If false, the cosmetic item can be seen. - + - Model position interpolated toward animatedSuspensionState according to modelSuspensionSpeed. + Payload for the DamageTool.damageZombie function. - + - [0, 360] angle of rotation around wheel axle. Measured in degrees because Quaternion.AngleAxis takes degrees. - - We track rather than using GetWorldPose so that we can alternate between using replicated and simulated - results without snapping transforms. + Should game mode config damage multiplier be factored in? - + - List is created if this wheel has a collider and uses collider pose. Null when vehicle is destroyed to - prevent creation of more effects. + Equivalent to the "armor" parameter of the legacy damage function. - + - Instance corresponding to current ground material. Doesn't necessarily mean the particle system is active. + Defaults to 1. - + - Called after construction and on all clients and server when a player stops driving. + If not null and damage is applied, is called with this position (startle: true). - + - Called when vehicles explodes. + Implemented by assets which gun supports checking for damage falloff. + When implemented, PopulateAsset should call PopulateArmorFalloff. - + - Called during FixedUpdate if vehicle is driven by the local player. + Ranged damage (guns) from greater than this distance finishes decreasing toward falloff multiplier. + Defaults to -1, in which case armor falloff is ignored. - + - Calculate suspension state from GetWorldPose result. - - Nelson 2024-03-25: Originally we used the result of GetWorldPose for the model transform and calculated - the suspension state from it because I thought Unity was internally using the spring position that isn't - (currently) exposed to the API. Whether or not it is, it seems fine to calculate the spring position using - the ground hit point instead. We switched entirely away from GetWorldPose so that the wheel can retain - its roll angle when transitioning between locally simulated and replicated. + Ranged damage (guns) from greater than this distance begins decreasing toward falloff multiplier. + Defaults to ArmorFalloffMaxRange. - + - Called during Update on dedicated server only if replicated suspension state is enabled. + [0, 1] normalized percentage of incoming damage to apply past IncomingDamageFalloffMaxRange. - + - Set replicated suspension state AND animated suspension state when vehicle is first received. + Should hitmarker be shown client-side for a given range? - - + - Supported when locally simulated and on remote clients. + Amount to multiply damage by at a given range. - + - Called during Update on client. + If true, button tooltip will be overridden with tooltip from states array. - + - Called during Update if vehicle is driven by the local player. + 2023-02-28: note order is important because BarricadeManager saves as a byte! - + - Called during Update on the server while vehicle is driven by player. + Camera does not rotate when the car rotates. - + - Seamlessly teleports player to an equivalent position at the destination upon contact. + Camera rotates when the car rotates. - + - Target position and rotation. + If hit from the left view rolls right, if hit from the right view rolls left. This may reduce motion + sickness for some players. - + - Only used in the Unity editor for visualization. + Rotate on all axes according to damage direction. This may induce motion sickness. - + - If true, PopulateAsset can modify data. For example, to replace deprecated properties. - Only true if asset re-saving and asset metadata parsing are enabled, and asset origin allows re-saving. - Modifications are not saved if asset has any errors in order to avoid losing data. + Unfortunately the version which added hitmarker style saved but didn't actually load (sigh). - + - If true, an asset with the same ID or GUID has been added to the current asset mapping, replacing this one. + Nelson 2023-12-28: this option was causing players to crash in the 3.23.14.0 update. Hopefully + it's resolved for the patch, but to be safe it will default to false. - + - If true, errors related to this asset were reported during loading. + Prior to 3.22.8.0 all scopes/optics had a base fov of 90 degrees. - + - Null or empty if created at runtime, otherwise set by when loading. + If false, call Start and Stop recording before and after push-to-talk key is pressed. This was the + original default behavior, but causes a hitch for some players. As a workaround we can always keep + the microphone rolling and only send data when the push-to-talk key is held. (public issue #4248) - + - Contents of file this asset was loaded from. Only kept if data re-saving is enabled. (So that this memory - is collected after populating the asset.) + If true, group member name labels fade out when near the center of the screen. + Defaults to true. - - - Master bundle this asset loaded from. - + + + If true, hide identifiable details of other multiplayer clients like avatars, player names, number of + players online, server name, etc. Live streamers may find this useful to help prevent stream sniping. + + Separated from the older "streamer mode" option. + - + + + If true, don't share details like "editing map X" or "join" with Steam. Useful for anyone who might be + targeted / followed into servers, or who has a project to keep secret. + + Separated from the older "streamer mode" option. + + + - Were this asset's shaders set to Standard and/or consolidated? - Needed for vehicle rotors special case. + Controls whether hitmarkers are animated outward (newer) or just a static image ("classic"). - + - Should texture non-power-of-two warnings be ignored? - Unfortunately some third party assets have odd setups. + Determines how camera follows vehicle in third-person view. - + - Should read/write texture warnings be ignored? + Determines how camera follows aircraft vehicle in third-person view. - + - Hash of the original input file. + [0, 1] Blend factor between black and flashbang's desired color. - + - Maybe temporary? Used when something in-game changes the asset so that it shouldn't be useable on the server anymore. + [0, 1] Multiplier for shake from . - + - Most asset classes end in "Asset", so in debug strings if asset is clear from context we can remove the unnecessary suffix. + Controls whether camera is constrained to roll-only or all axes. - + - Remove "Asset" suffix and convert to title case. + Multiplier for flinch away from damage source in . - + - e.g. Canned Beans (Consumeable Item) + [0, 1] Intensity of FOV boost while sprinting. - + - Perform any initialization required when PopulateAsset won't be called. + [0, 1] Intensity of first-person motion caused by walking. - + - Planning ahead to potentially convert the game to use Unity's newer Addressables feature. + Invoked when custom UI colors are set. - + - 2023-04-17: suggestion is to have a hardcoded list of hate speech that gets filtered - regardless of whether profanity filter is enabled. (https://forum.smartlydressedgames.com/t/22477) + Invoked when dark/light theme is set. - + - Special asset type that isn't (shouldn't be) returned by asset Find methods. Instead, if found when resolving - an asset legacy ID or GUID, Find is called again with the target specified by this asset. + Number of times the player has clicked "Proceed" in the online safety menu. - + - Enumerate elements that are not in the pool. + If true, "don't show again" is checked in the online safety menu. - + - Sanity check all returned elements have a gameObject. + Prevents menu from being shown twice without a restart. - + - Map creator can specify a constant weather mode. + Planar reflection component updates its culling distance and culling mask when this is incremented. - + - Associates a train vehicle ID with the index of a road path to spawn it on. - The level only spawns the train if this vehicle ID isn't present in the map yet, so every train on the map has to be different. + Overrides in-game UI scale setting. - + - Should underwater bubble particles be activated? + Distance to use terrain shaders before fallback to a baked texture. - + - Should positions underground be clamped above ground? - Underground volumes are used to whitelist valid positions. + Higher error reduces vertex density as distance increases. - + - If true, certain objects redirect to load others in-game. + Added for players who want to see if they can get better performance with a ridiculously low max draw distance. - + - If true, electric objects are always powered, and generators have no effect. + Multiplier for far clip plane distance. + Clamped within [0, 1] range to prevent editing config files for an advantage. - + - Display version in the format "a.b.c.d". + Multiplier for draw distance. + Clamped within [0, 1] range to prevent editing config files for an advantage. - + - Version string packed into integer. + Multiplier for draw distance of optional super-low LOD models. + Clamped within [0, 1] range to prevent editing config files for an advantage. - + - Number of custom tips defined in per-level localization file. - Tip keys are read as Tip_# + Vehicles outside this distance are not rendered. - + - LevelBatching is currently only enabled if map creator has verified it works properly. + Called after loading graphics settings from disk so that their values can be adjusted. - + - Overrides maximum size of textures included in LevelBatching atlas. - When using this, be mindful the combined texture doesn't exceed some reasonable size (~4k?) + If default resolution is zero, try falling back to a higher one. + Used when restoring defaults and validating loaded settings. - + - If true, map creator has verified the clutter option works as-expected. + If true, make the game look as nice as possible. + Note: certain limits are imposed except in singleplayer to prevent this from being exploited. - + - Absolute path to the map folder. + Index into Blueprints list. -1 means blueprint name is used instead. - + - Whether unity analytics should track this map's name. Don't want to burn all the analysis points! + Name to look for in Blueprints list. - + - Maps included with the game only, separate from category because arena maps are misc. - Category is set as part of the config file. This is only mainly used to enable unity analytics tracking for map name. + Icon visible when this listing is in the cart. - + - Only used for play menu categories at the moment. + "SALE" or "NEW" text visible when applicable. - + - SHA1 hash of the Level.dat file. + Register all built-in asset and useable types. - + - Test whether this map's workshop file ID is in the curated maps list. + Nelson 2024-02-06: when looking into resolving public issue #3703 I figured since there is a common behavior + between InteractableObjectQuest, InteractableObjectNote, and InteractableObjectDropper (in that they all + request the server to do X we may as well support a "mod hook" that works with all three. - + - Web URL to map feedback discussions. + Implemented by components the player can talk with using DialogeAssets. (e.g., InteractableObjectNPC) - + - If true, this info is out-of-date and may have been renamed or deleted. + Used to test whether player is within range. + Ideally, this should be removed in the future in favor of the server resetting speaker when out of range. - + - Preview.png should be 320x180 + Get a net ID that can be used with GetDialogueTargetFromNetId to resolve IDialogueTarget in multiplayer. - + - Get a random file path in the /Screenshots folder, or fallback to Level.png if it exists. + Called on server to test whether object conditions are met. - + - Get a random file path in the /Screenshots folder + Called on server to find the start of conversation dialogue asset. - + - When adding or removing entries remember to update NetMessages size and regenerate NetCode! + Used in error messages. - + - Client requesting workshop files to download. + Called on client to format in UI. - + - Client has loaded the level. + Should the buying and selling lists be alphabetically sorted? - + - Client providing Steam login token. + Kept because lots of modders have been using this script in Unity, + so removing legacy effect id would break their content. - + - Client sending BattlEye payload to server. + If the file already exists when writing we will move it to this path. (public issue #4636) + Appends '~' so that terminal autocomplete finds the original file first. + Use GetBackupFilePathV1 for the earlier "example-backup.dat" style. - + - Client sent a ping. + To assist with getting "example-backup.dat" path from prior to "example.dat~" change. - + - Client responded to our ping. + Allows map makers to create custom weather events. - + - Client calling an RPC. + Does this weather affect fog color and density? - + - Client providing asset GUIDs with their file hashes to check integrity. + Does this weather affect sky fog color? - + - Client intends to disconnect. It is fine if server does not receive this message - because players are also removed for transport failure (e.g. timeout) and for expiry - of Steam authentication ticket. This message is useful to know the client instigated - the disconnection rather than an error. + Does this weather affect cloud colors? - + - Error code that the server exited with. - 0 is succesful, anything else is an error. + Directional light shadow strength multiplier. - + - Empty if successful, - otherwise an explanation of the first error encountered. + Exponent applied to effect blend alpha. - + - Register all built-in asset and useable types. + Exponent applied to effect blend alpha. - + - Can be added to any GameObject to receive weather events for a specific custom weather asset. + SpeedTree wind strength for blizzard. Should be removed? - + - GUID of custom weather asset to listen for. + If specified level editor color can be used rather than a per-asset color. - + - Invoked when custom weather is activated, or immediately if weather is fading in when registered. + Remove all color rich formatting so that shadow text displays correctly. - + - Invoked when custom weather finishes fading in, or immediately if weather is already fully active when registered. + Shadow text needs the color tags removed, otherwise the shadow uses those colors. - + - Invoked when custom weather is deactivated and begins fading out. + Wrap text with color tags. - + - Invoked when custom weather finishes fading out and is destroyed. + Wrap text with color tags. - + - GUID parsed from WeatherAssetGuid parameter. + Wrap text with color tags. - + - Default. Create a material instance for child renderer of Toggle game object. - Downside of this is exclusion from level batching texture atlas. + Replace br tags with newlines. - + - Object does not have any toggleable emissive materials. + Should player be allowed to write given text on a sign? + Keep in mind that newer signs use TMP, whereas older signs use uGUI. - + - Prevents calling getOrLoad redundantly if asset does not exist. + Disable style, align, and space because they make server list unfair. - + - If set, overrides model prefab in the level editor. + Is the server this widget represents currently favorited? + Can be false on the favorites list. - + - Clip.prefab + Used in a test scene to quickly test all Glazier features. - + - Object.prefab + Reference type for testing SleekList. - + - If true, object will be hidden when rendering GPS/satellite view. - Defaults to true if is set. + Seconds between weather event starting and reaching full intensity. - + - If true, Nav game object will be instantiated in singleplayer and on dedicated server. Useful for objects - which need to affect navmesh baking without colliding with zombies during gameplay. - Defaults to true for "medium" and "large" objects. + Seconds between weather event ending and reaching zero intensity. - + - If true, Nav game object will be instantiated in the level editor. Useful for objects which need collision - with zombies during gameplay without affecting navmesh baking. - Defaults to true for "medium" and "large" objects. + Sound clip to play. Volume matches the intensity. - + - Should landing on this object inflict fall damage? + Component to spawn for additional weather logic. - + - If true, object is not loaded when clutter is turned off in graphics menu. + If per-volume mask AND is non zero the weather will blend in. - + - Property is not exposed at the moment because interactability properties should really be moved into some - sort of sub-asset. + Defines how instance methods handle invocation when the target instance does not exist yet, for example + if the target instance is async loading or has time sliced instantiation. - + - Same as interactabilityDialogueRef, not public because it really needs to be cleaned up. :( + Invocation should be ignored if the target instance does not exist. + This is the only applicable defer mode for static methods and server methods. - + - Effect played when single segment is destroyed. + Invocation will be queued up if the target instance does not exist. + Originally an "Overwrite" mode was considered for cases like SetHealth where only the newest value is + displayed, but this was potentially error-prone if multiple queued methods depended on values from each other. - + - Effect played when all segments are destroyed. + EconInfo.json hash does not match. - + - Weapon must have matching blade ID to damage object. - Both weapons and objects default to zero so they can be damaged by default. + Master bundle hashes do not match. - + - [0, 1] probability of dropping any rewards. + Workshop usage advertised on server list does not match during connect. - + - If true, zombies can attack this object if it's blocking them. Defaults to false. + Used by client transport to show a custom localized message. - + - Multiplier for damage from zombies if RubbleCanZombiesDamage is true. + Server has not received an auth session response from Steam yet. - + - Controls how rubble affects Nav game object. + Server has not received an economy response from Steam yet. - + - If set (>0), alerts nearby entities when an individual section is destroyed. + Server has not received a groups response from Steam yet. - + - If set (>0), alerts nearby entities when all sections are destroyed. + Player nickname exceeds limit. - + - If true, all sections respawn at the same time. + Player nickname contains invalid characters. - + - Should colliders in the Triggers GameObject with "Kill" name kill players? - If Triggers GameObject is not set, searches Object instead. + Player nickname should not be a number. - + - Should this object only be visible if gore is enabled? - Allows pre-placed blood splatters to be hidden for younger players. + Server did not respond to EServerMessage.Authenticate - + - Only activated during this holiday. + Player resources folders don't match. - + - Object to use during the Christmas event instead. + The network identity in the ticket does not match the server authenticating the ticket. + This can happen if server's Steam ID has changed from what the client thinks it is. + For example, joining a stale entry in the server list. (public issue #4101) - + - Object to use during the Halloween event instead. + Level name advertised on server list does not match during connect. - + - Get asset ref to replace this one for holiday, or null if it should not be redirected. + VAC status advertised on server list does not match during connect. - + - If any conditions use flags they will be added to a set, - otherwise null is returned. + BattlEye status advertised on server list does not match during connect. - + - Recursively change all children including root from oldTag to newTag. - Aborts if a child doesn't match the old tag because it might be something we shouldn't change the tag of. - True if tags were all successfully changed. + Max players advertised on server list does not match during connect. - + - Recursively change all children including root from oldLayer to newLayer. - Aborts if a child doesn't match the old layer because it might be something we shouldn't change the layer of. - True if layers were all successfully changed. + Camera mode advertised on server list does not match during connect. - + - Called if we have a valid Nav GameObject. - Recast requires any meshes used on the Nav objects to be CPU readable, so we log errors here if they're not marked as such. + Combat mode advertised on server list does not match during connect. - + - Should zombie(s) of the required type be spawned when player enters the area? + Player's skin color is too similar to one of . - + - How many to spawn if spawning is enabled. + Steam ID reported by net transport doesn't match client's reported Steam ID. + This was exploited to fill the server queue with fake players. - + - If greater than zero, find this zombie type configured in the level editor. For example, if the level editor - lists "0 Fire (4)", then 4 is the unique ID, and if assigned to this condition a zombie from the "Fire" - table will spawn. + Received too many connection requests from player in a short window. - + - Navmesh index player must be within. If set to byte.MaxValue then anywhere on the map is eligible. + Received too many invalid messages from connection in a short window. - + - Only kills within this radius around the player are tracked. + Same as CUSTOM, but shows the "verify game files" prompt. - + - Only kills outside this radius around the player are tracked. - NSTM requested this for a sniping zombies quest. + Server limits how many clients are joining from the same IP address. + (public issue #5001) - + - If spawning is enabled, whether to use the timer between spawns. + Nelson 2024-10-18: Moved to a constant because clients need this value for footsteps and they don't have the + character controller component. - + - Shows inspect buttons for each item mentioned in purchasable box or bundle's description text. + Jump speed = sqrt(2 * jump height * gravity) + Jump height = (jump speed ^ 2) / (2 * gravity) + With 7 speed and 9.81 * 3 gravity = apex height of 1.66496772 - + - Manages global post-process volumes. + Note: Only UpdateCharacterControllerEnabled should modify whether controller is enabled. + (turning off and back on is fine though) - + - Callback when in-game graphic settings change. + Valid while isRadiated. - + - Callback when player changes perspective. + Set according to volume or level global asset fallback. - + - Unfortunately EditorPrefs cannot be used in constructor. + Was set to true during teleport, and restored to false during the next movement tick. + + Server pauses movement when this is set until next client update that matches, + in order to prevent rubberbanding following a teleport. - + - Represents whether a player can craft a provided blueprint. If yes, which items to use, if no, why not. - Previously, some of this data was (confusingly) stored in the blueprint definition. - For performance, caller should re-use a list of BlueprintStatus and *not* discard unused results. + Used instead of actual position to avoid revealing admins in "vanish" mode. - + - Total number of missing required nearby crafting tags. + Flag for plugins to allow maintenance access underneath the map. - + - Total required input item count minus available input item count. + Get seat (if any), otherwise null. - + - Currently only used by housing planner. - Doesn't work with NPC conditions / rewards. + Serverside force player to exit vehicle regardless of safe exit points. + True if player was seated in vehicle. - + - Currently only used by housing planner. - Doesn't work with NPC conditions / rewards. + Dedicated server simulate while input queue is empty. + + + + + Dedicated server simulate driving input. - + - Used to sort blueprints from "most craftable" (1) to "least craftable" (0). + Client and dedicated server simulate walking input. - + + + In the future this can probably replace checkGround for locally simulated character? + (Unturned only started using OnControllerColliderHit on 2023-01-31) + + 2023-02-28: be careful with .gameObject property because it returns .collider.gameObject + which can cause a null reference exception. (public issue #3726) + + + - Reset values set by PlayerCrafting.UpdateBlueprintDynamicStatus. + Allows foreach loop to iterate renderers defined in lod group. - + - If not zero, use this amount instead of . - Used by as amount of ammo needed. + Center mythical effect hook horizontally, but maintain vertical placement. + Lots of hats/masks/glasses have off-center effects intentionally, but community + feedback suggests centering to make effects like circling atoms look better. - + - If true, cancel updating status as soon as anything goes wrong. - False for client UI where all info about blueprint is needed for display. - True on server where extra processing is a waste. + Set mesh of all character mesh renderers. + Tries to match renderer index to mesh LOD index. - + - If set, log errors here. + Set material of all character mesh renderers. - + - Is current UTC time within this time span, and player has not dismissed? + Hack for previewing the "aura" cosmetic items. - + - Has the current time span been dismissed? - For example, player may have dismissed a previous event but not this current one. + If true, this character is for capturing clothing icons. - + - Is current UTC time within this time span? + Speaker writes compressed audio to this buffer. + Listener copies network buffer here for decompression. - + - Allows file name to be included in kick message that client would otherwise not know. + Listener writes decompressed PCM data to this buffer. - + - Actual max value is plus one because message never contains zero items. + Seconds interval to wait between asking recording subsystem for voice data. + Rather than polling every frame we wait until data has accumulated to send. - + - Has player dismissed the given workshop item? + Seconds to wait before playing back newly received data. + Allows a few samples to buffer up so that we don't stutter as more arrive. - + - Track that the player has dismissed the given workshop item. + Seconds to wait after playback before stopping audio source. + We zero this portion of the clip to prevent pops. - + - Has player already auto-subscribed to the given workshop item? + Max calls to askVoice server will allow per second before blocking their voice data. + Prevents spamming many tiny requests bogging down server output. - + - Track that the player has auto-subscribed to the given workshop item. + Max compressed bytes server will allow per second before blocking their voice data. + When logging compressed size they averaged 3000-5000 per second, so this affords some wiggle-room. - + - Find colliders in gameObject and encapsulate their bounding boxes together. + Internal value managed by isTalking. - True if bounds were determined, false otherwise. - + - Find colliders in gameObject and the point closest to position, otherwise use gameObject position. + Is this player broadcasting their voice? + Used in the menus to show an indicator who's talking. + Locally set when recording starts/stops, and remotely when voice data starts/stops being received. - Collider is only included if its layer is enabled in layer mask. - + - Does sphere overlap anything? + Broadcasts after isTalking changes. - + - Allows foreach loop to iterate renderers defined in lod group. + Can this player currently hear global (radio) voice chat? - + - Counts hits per-IPv4 address (if available) and per-SteamID (if available). - Connection is blocked if more than "threshold" hits occur within category (IPv4/SteamID). - Hit count resets when "window" seconds have passed since last hit. + Is the player wearing an earpiece? + Allows global (radio) voice chat to be heard without equipping the walkie-talkie item. - + - If hit is within this many seconds of previous hit, it counts. Otherwise, counter is reset. + Is a UseableWalkieTalkie currently equipped? + Set by useable's equip and dequip events. - + - If more than this many hits occur the limit is reached. + Was the most recent voice data we received sent using walkie talkie? - + - Hack, we put this string on a newline for box probabilities. + Has voice data recently been received, but we're waiting slightly to begin playback? + Important to give clip a chance to buffer up so that we don't stutter as more samples arrive. - + - Called on the client after a new message is inserted to the front of the list. + AudioSource.isPlaying is not trustworthy. - + - Called on the server when preparing a message to be sent to a player. - Allows controlling how %SPEAKER% is formatted for the receiving player. + Timer counting down to begin playback of recently received voice data. + We use a timer rather than availableSamples.Count because a very short phrase could be less than threshold. - + - Called on the server when formatting a player's message before sending to anyone. - Allows structuring the message and where the player's name is, for example: '[CustomPluginRoleThing] %SPEAKER% - OriginalMessageText' + Timer counting down to end playback. - + - Exposed for Rocket transition to modules backwards compatibility. + Accumulated realtime since we last polled data from voice subsystem. - + - Add a newly received chat message to the front of the list, - and remove an old message if necessary. + Last time askVoiceChat was invoked over network. - + - Previous messages sent to server from this client. - Newest at the front, oldest at the back. Used to repeat chat commands. + Number of times askVoiceChat has been called recently, to prevent calling it many times + with tiny durations getting server to relay many packets to clients. - + - Send a request to chat from the client to the server. + Total of recent compressed voice payload lengths. - + - Allows Unity events to send text chat messages from the client, for example to execute commands. - Messenger context is logged to help track down abusive assets. + Realtime since this recent conversation began. - + - Allows Unity events to broadcast text chat messages from the server. - Messenger context is logged to help track down abusive assets. + Only used by plugins. + Called on server to allow plugins to override the default area and walkie-talkie voice channels. - + - Server send message to specific player. - Used in vanilla for the welcome message. - Should not be removed because plugins may depend on it. + Default culling handler when speaking over walkie-talkie. - + - Server send message to specific player. - Used in vanilla by help command to tell player about command options. - Should not be removed because plugins may depend on it. + Default culling handler when speaking in proximity. - + - Server send message to all players. - Used in vanilla by some alerts and broadcast command. - Should not be removed because plugins may depend on it. + Called by owner to relay voice data to clients. + Not using rate limit attribute because it internally tracks bytes per second. - + - Serverside send a chat message to all players, or a specific player. + Called by server to relay voice data from clients. - Contents to display. - Default text color unless rich formatting overrides it. - Player who sent the message (used for avatar), or null if send by a plugin. - Send message to only this player, or all players if null. - Mostly deprecated, but global/local/group may be displayed. - URL to a 32x32 .png to show rather than a player avatar, or null/empty. - Enable rich tags e.g., bold, italics in the message contents. - + - Nelson 2024-10-14: We might want to elaborate on this with "client-side chat commands" in the future, but - for the meantime I've hacked in this one command. + Set to true during OnDestroy to make sure we don't start recording again. - + - If set, find a child meshrenderer with this name and change its material to the character hair material. + If true, SteamUser.StartVoiceRecording has been called without a corresponding call to + SteamUser.StopVoiceRecording yet. - + - If non-zero, legacy ID of final Asset to return. + If true, voice toggle is in ON mode. - + - If non-zero, legacy ID of SpawnAsset to resolve. + Internal value managed by inputWantsToRecord. - + - If both legacy IDs are zero this GUID will be used. If the target asset is - a SpawnAsset it will be further resolved, otherwise the found asset is returned. + Set by updateInput based on whether voice is enabled, key is held, is alive, etc. + Reset to false during OnDestroy to stop recording. - + - Can be enabled by spawn tables that insert themselves into other spawn tables using the roots list. - If true, zeros the weight of child tables in the parent spawn table. + Called during Update on owner client to start/stop recording. - + - Has this spawn been added as a root of its child spawn table? - Used for debugging spawn hierarchy in editor. + Called during Update on owner client to record voice data. - + - Helper method for plugins because IDs are internal. + Play walkie-talkie squawk at our position. - + - Parent spawn assets this would like to be inserted into. + Start and stop playback of received audio stream. - + - Zero weights of child spawn tables. - Called when inserting a root marked isOverride. + Will this component ever need to record voice data? - + - Do tables need to be sorted and normalized? + Will this component ever need to play voice data? + In release builds this is only true for remote clients, but in debug we may want to locally listen. - + - Sort children by weight ascending, and calculate their normalized chance as a percentage of total weight. + Player's voice audio source cached during Start. - + - Remove from roots, and if reference is valid remove us from their children. + Looping voice audio clip. - + - Remove from tables, and if referencing a child table remove us from their roots. + Playback buffer. - + - Spawns an animal into the world. + Steam does less work on the main thread if we request samples at the native decompresser sample rate, + so the re-sampling can be done on the Unity audio thread instead. - The ID of the animal. - Position to spawn the animal. - Angle to spawn the animal. - Whether the animal is dead or not. - + - Gets the animal at a specific index. + 1 / frequency - The index of the animal. - - + - Find replacement spawnpoint for an animal and teleport it there. + Number of samples to zero after writing new audio data. - + - Used in arena mode to reset all animals to dead. + Wraps audio source to prevent caller from meddling with it, and to allow the implementation + to change in the future if necessary. - + - Stripped-down version of structure prefab for previewing where the structure will be spawned. + 2D audio. - + - Whether preview object is currently highlighted positively. + Optional parent transform to attach the audio source to. - + - Time when "Use" animation clip started playing in seconds. + 0 = 2D, 1 = 3D - + - Length of "Use" animation clip in seconds. + Associates an ID with the instance of the sound being played. This ensures that if Stop() is called + on an old handle it will not stop playing the audio if the component has already been recycled. - + - True when animation starts playing, false after placement sound is played. + True while inactive, false while playing. - + - Whether the "Use" animation clip started playing. + Timer needs playId as well in case source has been recycled by the time duration expires. - + - If running as server, whether ReceiveBuildStructure has been called yet. + Sort items with lowest "amount" to front of list. - + - Whether basic range and claim checks passed. + Sort items with highest "amount" to front of list. - + - Position the item should be spawned at. + Sort items with lowest quality% to front of list. - + - Rotation the item should be spawned at. + Sort items with highest quality% to front of list. - + - Interpolated toward customRotationOffset. + Sum up number of items found, ignoring amount. + Default except as described in TotalAmount comment. - + - Allows players to flip walls. + Sum up "amount" of each item. Optionally counting zero as one (ShouldCountEmptyAsOne). + Default for legacy "ammo type" blueprints and FillTargetItem operation. - + - Vertical offset using scroll wheel. + Note: if calling ItemRef.Get() please use FindItemAsset instead to avoid redundant asset lookups. - + - Whether enough time has passed for "Use" animation to finish. + If true, items with an "amount" of zero are included in eligible supplies as amount 1. + In practice (as of 2025-03-03), items with zero amount are empty containers such as magazines. - + - Whether animation has reached the time when placement sound should play. + Determines how totalAmount of each input is calculated. - + - Used to aid backwards compatibility as much as possible when transitioning Unity versions breaks asset bundles. + If true, items with an "amount" of zero are included in eligible supplies. + Otherwise, they are ignored (default). - + - Unity 5.5 and earlier per-asset .unity3d file. + If true, items with an "amount" >= their MaxAmount are ignored. Otherwise, they are eligible (default). - + - When "master bundles" were first introduced in order to convert older Unity 5.5 asset bundles in bulk. + If true, items with quality of 100% are eligible (default). Otherwise, they are ignored. - + - Unity 2018 needed a new version number in order to convert materials from 2017 LTS asset bundles. 2019 did not need a - new version number, but in retrospect it seems unfortunate that we cannot distinguish them, so 2020 does have its own. + Controls which items are used first. For example, whether to use the lowest quality items first. - + - 2021 LTS+ + If true, delete input item. Defaults to true. + Replaces the "tool" blueprint option. - + - The first time asset loading finishes it will load the main menu. + Does this blueprint input require the specified item? - + - If true, either loading during initial startup or full refresh. + Assets cannot be loaded from Resources during static initialization, so this reference defers the load until + the first time user tries to use it. - + - If true, currently searching locations added after initial startup loading. + Broadcasts once all workshop assets are finished installing. - + - Has initial client UGC loading step run yet? - Used to defer asset loading for workshop installs that occured during startup. + Called once the server is done registering items it wants to install. + True when running in offline-only mode. - + - Has initial map loading step run yet? - Used to defer map loading for workshop installs that occured during startup. + Request for details about the pending items. - + - Calling this "legacy" is a bit of a stretch because even most of the vanilla assets are - built around the 16-bit IDs. Ideally no new code should be relying on 16-bit IDs however. + File IDs of all the items we have enqueued for query. - + - Incremented when assets are added or removed. - Used by boombox UI to only refresh songs list if assets have changed. + Built from user-specified workshop item IDs, and then expanded as the query results + arrive with details about any dependent or child items. - + - In singleplayer and the level editor this is the same as defaultAssetMapping, - but when playing on a server a subset of assets based on the server's workshop files is used. + File IDs requested by the latest query submitted. - + - Should folders be scanned for and load .dat and asset bundle files? - Plugin developers find it useful to quickly launch the server. + Number of times we've tried re-submitted failed queries. - + - Do we want to enable shouldDeferLoadingAssets? + Built as the valid list of items arrive. - + - Should extra validation be performed on assets as they load? - Useful for developing, but it does slow down loading. + ID of the latest item we requested for download so that we can test if the callback is for us. - + - Should asset file metadata such as line numbers and comments be parsed? - Useful for development (e.g., error messages), but may slow down loading and increases RAM usage. + Enqueue an item if we have not queried it yet. This guards against querying an item + that is in two separate collections leading to duplicates. - + + True if item was installed from cache. + + - Should asset files be re-saved after all loading is finished? - Requires asset metadata. Useful for automatically upgrading .dat/.asset files. + Used in offline-only mode. - + + + Prepare a query that will request metadata for all the workshop items we want to install. + This allows us to check if the items are allowed to be auto-downloaded to this server, and to + detect any child or dependent items. + + Waits for onQueryCompleted. + + + - Should some specific asset types which opt-in be allowed to defer loading from asset bundles until used? - Disabled by asset validation because all assets need to be loaded. + Re-submit previous query after a query failure. - + - Should workshop asset names and IDs be logged while loading? - Useful when debugging unknown workshop content. + Can be null if nothing has been added at position. - + - Should a JSON report of all the game's assets be exported? + Does not add new lists to empty cells. - + - Should GC and clear unused assets be called after every loading frame? - Potentially useful for players running out of RAM, refer to: - https://github.com/SmartlyDressedGames/Unturned-3.x-Community/issues/1352#issuecomment-751138105 + Number of Lists to preallocate in batches. + (GRID_SIZE * GRID_SIZE) % LIST_POOL_SIZE should be zero leftover. + Reduces constructor performance cost. (public issue #4209) - + - Should modded spawn tables being inserted into parents be logged? - Useful for debugging workshop spawn table problems. + White 1x1 texture for solid colored images. + uGUI empty image draws like this, but we need the texture for IMGUI backwards compatibility. - + - Loaded master bundles. + Invoked when component is enabled and when the game object is activated. - + - Loading master bundles. + Invoked when component is disabled and when the game object is deactivated. + Note that if the component or game object spawn deactivated this will not be immediately invoked. - + - Master bundle from root /Bundles directory containing vanilla assets. + Called once key/values can be set. - + - While an asset is being loaded, this is the master bundle for that asset. - Used by master bundle pointer as a default. + Absolute path to directory containing bundle and .dat file. - + - This method supports . + Name of the actual asset bundle file, e.g. Hawaii.unity3d + Asset bundle should be next to this config file. - + - Find an asset by GUID reference. - This method supports . + assetBundleName without final .* extension. - Asset with matching GUID if it exists, null otherwise. - + - Find an asset by GUID reference. - This method supports . - Maybe considered a hack? Ignores the current per-server asset mapping. + Prefixed to all asset paths loaded from asset bundle. + Final path is built from assetPrefix + pathRelativeToBundlesFolder + assetName, + e.g. Assets/Hawaii/Bundles + /Objects/Large/House/ + Object.prefab - Asset with matching GUID if it exists, null otherwise. - + - Find an asset by GUID reference. - This method supports . - Maybe considered a hack? Ignores the current per-server asset mapping. + Custom asset bundle version used by Unturned to detect whether imports need + fixing up because they were exported from an older version of Unity. - Asset with matching GUID if it exists, null otherwise. - + - Load content from an assetbundle. + Get absolute path to asset bundle file. - + - Find an asset by GUID reference. - This method supports . + Get absolute path to file with per-platform hashes. - Asset with matching GUID if it exists, null otherwise. - + - Find an asset by GUID reference. - This method supports . + Insert path prefix if set. - Asset with matching GUID if it exists, null otherwise. - + - This method supports . + When to use this instead of formatAssetPath? MasterBundleReference and AudioReference repeatedly invoke + this string formatting (e.g., footstep sounds) and benefit from not generating that garbage. - + - This method supports . + Loaded asset bundle. - + - This method supports . - Note: this method doesn't handle redirects by VehicleRedirectorAsset. + Hash of loaded asset bundle file. + This is per-platform, so the server loads a hash file with all platform hashes. - + - This method supports . - Note: this method doesn't handle redirects by VehicleRedirectorAsset. + True if the server .hash file exists. + Hash file is not used by client, but client uses whether it exists to decide whether to include asset bundle hash in asset hash. - + - This method supports . + Hashes for Windows, Linux, and Mac asset bundles. + Only loaded on the dedicated server. Null otherwise. - + - This method supports . + On the surface level this is rather silly. + The primary reason for it is reducing garbage created by repeated calls to formatAssetPath. + Theoretically we could use this for caching redirected paths if/when that feature is added. - + - Useful if GUID can reference a different asset type than legacy ID. For example, gun magazine GUID can - reference a SpawnAsset while its legacy ID cannot. - This method supports . + Load the underlying asset bundle. - + - Append assets that extend from result type. + If true, the associated asset bundle couldn't be loaded and was instead copied from another config. - + - Maybe considered a hack? Ignores the current per-server asset mapping. - Append assets that extend from result type. + Nelson 2025-01-28: This command reproduces a bug destroying the player gameObject if the vehicle is + destroyed on the same frame as the request to exit. + https://github.com/SmartlyDressedGames/Unturned-3.x-Community/issues/4760#issuecomment-2613090165 - - - While playing on server the client will use the same dictionary/list of assets the server uses in order - to reduce issues with ID conflicts. - - 2023-05-27: server now ALSO uses the same logic to ensure IDs are applied in consistent order regardless - of multi-threaded loading order. - - - + - Search all loaded master bundles for one in path's hierarchy. + Find colliders in gameObject and encapsulate their bounding boxes together. + True if bounds were determined, false otherwise. - + - Find loaded master bundle by name. + Find colliders in gameObject and the point closest to position, otherwise use gameObject position. + Collider is only included if its layer is enabled in layer mask. - + - Unload all asset bundles from memory, and empty known list. - Called when reloading assets. + Does sphere overlap anything? - + - Catches exceptions thrown by LoadFile to avoid breaking loading. + HUD with projected labels for teammates. - + - Called when a new workshop item is installed either on client or server. + If not none, only remove zombies of this type. - + - Reload assets in given folder. + If greater than zero, only remove zombies matching this table unique ID. - + - Do we have any new spawn assets that have not been linked yet? - Used to skip linking spawns if not required when downloading assets. + Navmesh index to remove zombies within. If set to byte.MaxValue then zombies are removed everywhere. - + - Can now be safely called multiple times on client in order to handle spawns for downloaded maps. - Spawn tables have "roots" which allow mods to insert custom spawns into the vanilla spawn tables. - This method is used after workshop assets are loaded on client, or after the dedicated server is done downloading workshop content. + Nelson 2025-10-06: better late than never. Current indices into the gun state array (and + other item state arrays, for that matter) being unnamed makes it hard to read. Updates to + gun-related code should prefer using these names. - + - Look through all item blueprints and log errors if there are duplicates. + Starting position when the bullet was fired. - + - Look through all dialogue and check that their referenced - dialogueID or vendorID is an actual loaded asset. + Only available on the server. For use by plugins developers who want to analyze deviation between approximate + start direction and final hit position using and + per public issue #4450. Note that origin and direction on server are not necessarily exactly the same as on + the client for a variety of reasons, including that bullets on the client can be spawned between simulation + frames when the aim direction was different. (Aim direction is updated every drawn frame on the client as + opposed to every simulation frame on the server.) Rather than kicking for one particularly large deviation + we would recommend tracking stats for each shot's actual deviation vs max theoretical deviation. Remember + to account for bullet drop and that aim spread is relative to this direction. (For example, a shotgun may + fire ~8 pellets in a cone around this direction.) Note also that in third-person the bullet can turn up to + 90 degrees from the aim direction if the camera is up against a wall. - + - Manually run asset unload and garbage collection in the hope - that it will minimize RAM allocated during loading. + Combination of gun and attachments' bullet gravity multipliers. - + + Whether plugin allowed attachment. + + - Helper for Assets.init. - Load all non-map assets from: - /Bundles/Workshop/Content - /Servers/ServerID/Workshop/Content - /Servers/ServerID/Bundles + Plugin-only event when bullet is fired on server. - + - Helper for Assets.init. - Load all non-map assets from subscribed UGC. + Plugin-only event when bullet hit is received from client. - + - Helper for modders creating workshop content. - Loads folders in the "Sandbox" directory the same way workshop files are loaded. + Plugin-only event when projectile is spawned on server. - + - Helper for Assets.init. - Load all assets in each map's Bundles folder, and content in map's Content folder. + reticuleHook.localPosition after instantiation, or zero if null. - + - Not the tidiest place for this, but it allows startup to pause and show error message. - Occasionally there have been reports of the steamclient redist files being out of date on the dedicated - server causing problems. For example: https://github.com/SmartlyDressedGames/Unturned-3.x-Community/issues/2866#issuecomment-965945985 + True if startPrimary was called this simulation frame. + Allows gun to shoot even if stopPrimary is called immediately afterwards. - + - Note: inventory service does not support exchanging multiple items simultaneously. + Remaining calls to tock before firing. - + - Optional parameter for error logging and responding to the invoker. + Shot counter used by needsRechamber and RechamberAfterShotCount. - + - Wraps audio source to prevent caller from meddling with it, and to allow the implementation - to change in the future if necessary. + Is the tactical attachment toggle on? + e.g. True when the laser is enabled. - + - 2D audio. + Should stat modifiers from the current tactical attachment be used? - + - Optional parent transform to attach the audio source to. + Factor e.g. 2 is a 2x multiplier. + Prior to 2022-04-11 this was the target field of view. (90/fov) - + - 0 = 2D, 1 = 3D + Zoom multiplier in third-person. - + - Associates an ID with the instance of the sound being played. This ensures that if Stop() is called - on an old handle it will not stop playing the audio if the component has already been recycled. + Whether main camera field of view should zoom without scope camera / scope overlay. - + - True while inactive, false while playing. + Original barrel and magazine assets are supplied because they may have already been deleted. Barrel is only + valid if quality was greater than zero. - + - Timer needs playId as well in case source has been recycled by the time duration expires. + Called on server and owning client. - + - Not extendable until transport API is better finalized. + Calculate damage multiplier for individual bullet. - + - How many seconds message should popup. + Requested for plugin use. - + - Which item ID we thought was there. If the item ID currently at the coordinates doesn't match we clear this hotkey. + Request from the server to play a gun jammed animation. + Since client can't predict chamber jams we fixup the predicted ammo count. - - - Start/Stop input is encoded as 2 bits, 1 bit for Start flag and 1 bit for Stop flag. - - Prior to 2023-03-16 it was a single bit. The server would Start if true and the previous frame was false, - and vice versa call Stop if false and the previous frame was true. The problem with that approach was when - the client FPS is higher than the simulation FPS a series of repeated attack presses would be treated as a - continuous held attack input. Semi-auto guns were difficult to shoot at their max rate of fire. Sending both - allows the server to theoretically call Start every simulation frame as opposed to only half. - - First approach was to OR Start if held, otherwise OR Stop. This doesn't work because for example when Aim is - pressed the Stop flag will already be enabled, so the gun Starts aiming, Stops aiming, Starts aiming, and then - stays aiming rather than just Start and stay aiming. Instead we only want Stop to be sent once. - + + + Note: This is the m/s² acceleration, not the multiplier. + - + - Wants to "start" primary or secondary input. (e.g., Useable.startPrimary) + This is a bit of a hack... aimAccuracy is [0, maxAimingAccuracy] and changed during each FixedUpdate call, + but was used in some gameplay display features like holo sight, laser, ADS, etc. (yes, should + be de-coupled from FixedUpdate but that is its own issue) To smooth this out we interpolate + slightly behind the aimAccuracy value depending on the time since FixedUpdate. - + - Wants to "stop" primary or secondary input. (e.g., Useable.stopPrimary) + Holographic sights follow the true aiming direction regardless of viewmodel animation. - + - Invoked from tellEquip after change. + Note: This is the multiplier, not the m/s² acceleration. - + - Skin applied to the currently equipped useable. + Code common for regular gun and sentry gun. - + - Does equipped useable have a menu open? - If so pause menu, dashboard, and other menus cannot be opened. + Relatively efficiently find mesh components, and log an error if their mesh is missing, among other checks. - + - For aiming toggle input. + Unity warns about renderers registered with more than one LOD group, so we do our own validation as part of + asset loading to make it easier to find these. - + - Get ragdoll effect to use when the current weapon deals damage. + Alerts any agents in the area to the player if needed. + The player causing this alert. + The position of the alert. + The detection radius. + Whether or not to hide. - + - It should be safe to call this immediately because hotkeys are loaded in InitializePlayer. + Alerts any agents in the area. + The position of the alert. + The detection radius. - + - Prevent multiple hotkeys from referencing the same item. + Name of the asset bundle. + core.content - + - Left-handed characters need the stat tracker to be flipped on the X axis so that the text reads properly. - ItemTool doesn't know about left/right handedness, so for the moment that's handled here because only players need this fixed up. + Path within the asset bundle. - + - Match stat tracker gameobject's isActive to whether skins are visible. + Spawned zombie will be changed to this speciality type. - + - Match all stat tracker visibilities to whether skins are visible. + Zombie(s) will be spawned at a Spawnpoint node matching this ID. + If multiple Spawnpoints match this ID a random spawnpoint is chosen for each zombie. - + - Called clientside to ask server to equip an item in the inventory. + If greater than zero, find this zombie type configured in the level editor. For example, if the level editor + lists "0 Fire (4)", then 4 is the unique ID, and if assigned to this reward a zombie from the "Fire" + table will spawn. - + - Hacked-in to bypass regular clientside checks when client would predict the item at given coords. + Number of zombies to spawn. - + - Remove the item from inventory so that if we die before the item isn't dropped + If set, zombies will not spawn unless CooldownDuration seconds have passed since last run. - + - Finish dequipping from + Stripped-down version of structure prefab for previewing where the structure will be spawned. - + - Invoked before dealing damage regardless of whether the punch impacted anything. + Whether preview object is currently highlighted positively. - + - (Temporarily?) separated out from simulate to try and get a better exception call stack. + Time when "Use" animation clip started playing in seconds. - + - (Temporarily?) separated out from simulate to try and get a better exception call stack. + Length of "Use" animation clip in seconds. - + - (Temporarily?) separated out from simulate to try and get a better exception call stack. + True when animation starts playing, false after placement sound is played. - + - Allow UI to process input [0, 9] key press when cursor is visible. + Whether the "Use" animation clip started playing. - + - Process input [0, 9] key press. + If running as server, whether ReceiveBuildStructure has been called yet. - + - If equipped item is bound to a hotkey, return the button [0, 9] associated. - Otherwise, return -1. + Whether basic range and claim checks passed. - + - Called by input when preparing for simulation frame. + Position the item should be spawned at. - + - Called once by Setup. + Rotation the item should be spawned at. - + - Extension method for Thread class. - Plugins use this. - I might have accidentally removed it due to zero refs and Pustalorc was mad: - https://github.com/SmartlyDressedGames/Unturned-3.x-Community/discussions/4131 + Interpolated toward customRotationOffset. - + - Throw an exception if current thread is not the game thread. + Allows players to flip walls. - + - Only on dedicated server: throw an exception if current thread is not the game thread. + Vertical offset using scroll wheel. - + - Search loaded assets for blueprints that output a single structure item and are - available on the current map. + Whether enough time has passed for "Use" animation to finish. - + - Update status of all relevant blueprints. + Whether animation has reached the time when placement sound should play. - + - Currently saved craftableBlueprint for asset may have become uncraftable, - in which case we try finding a craftable replacement. + Configuration for DedicatedUGC. - + - Get a blank status from the pool or construct a new one. + Published workshop file IDs to download. - + - Search inventory for housing items, count the quantity of each, and remove - duplicate entries from the list because it is used for the UI. + Published workshop file IDs whose children (dependencies) should be skipped. + Useful if workshop author lists dependencies as a way of advertising. - + - Stripped-down version of structure prefab for previewing where the structure will be spawned. + Controls SetAllowCachedResponse. Disabled when set to zero. + Balance between item change frequency and allowing cached results when query fails. - + - Whether preview object is currently highlighted positively. + Number of total times to try re-submitting failed workshop queries before aborting. - + - Position the item should be spawned at. + Should items already installed be loaded? - + - Rotation the item should be spawned at. + Should used items be monitored for updates? - + - Interpolated toward customRotationOffset. + Seconds to wait before shutting down after an update is detected. - + - Allows players to flip walls. + Message broadcasted when shutdown timer begins. - + - Vertical offset using scroll wheel. + Message sent to players when shutdown timer completes. - + - Box in the HUD with selected item name and quantity. + Get instance if loaded, but do not load. - + - Blueprints which create a structure item. + Get instance, or load if not yet loaded. - + - One craftable blueprint per potential structure item. + Overrides how fall damage is calculated when landing on this game object or its descendants. - + - Recycled blueprint statuses. + Could be extended in the future to increase, decrease, or set fall damage. - + - Steam currency codes seem to be ISO 4217, however the documentation (as of 2021-01-29) does not say so. + Potentially useful for an event to toggle the override. - + - If overlay is disabled there is no point showing the in-game item store because the player will not be able - to checkout. We request listings regardless in order to show the "sale" label automatically. + Character will not take any fall damage. - + - Windows-specific extensions of Windows console input. - Uses the Win32 API to force a console to be created and destroyed. + Default. Per-navmesh difficulty asset takes priority over per-table/type difficulty asset. + If per-navmesh asset is null the per-table asset is the fallback. - + - Directory the game files are installed in. For the editor this is the /Builds/Shared directory. - Windows and Linux: contains the executable and the Unturned_Data directory. - MacOS: contains the Unturned.app bundle. + Per-table/type difficulty asset takes priority over per-navmesh difficulty asset. + If per-table asset is null the per-navmesh asset is the fallback. - + - Handles VehicleRedirectorAsset (if any) and returns actual vehicle asset (if any). + Intensity of fog effect while camera is inside a water volume. + Defaults to 0.075. - + - Handles VehicleRedirectorAsset returning load paint color override (if any) and returns actual vehicle asset (if any). + Player stealth radius cannot go below this value. - + - Handles VehicleRedirectorAsset returning spawn paint color override (if any) and returns actual vehicle asset (if any). + Deal damage and break legs if speed is greater than this value. - + - Handles VehicleRedirectorAsset (if any) and returns actual vehicle asset (if any). + By default players in singleplayer and admins in multiplayer have a faster salvage time. + This option was requested for maps with entirely custom balanced salvage times. - + - Handles VehicleRedirectorAsset returning load paint color override (if any) and returns actual vehicle asset (if any). + Cached result of finding all craftingBlacklists. - + - Handles VehicleRedirectorAsset returning spawn paint color override (if any) and returns actual vehicle asset (if any). + Determines which weather can naturally occur in this level. + Null if empty. - + - Handles VehicleRedirectorAsset (if any) and returns actual vehicle asset (if any). + If set, this weather will always be active and scheduled weather is disabled. - + - Handles VehicleRedirectorAsset returning load paint color override (if any) and returns actual vehicle asset (if any). + Audio clip to play in 2D when a player dies. - + - Handles VehicleRedirectorAsset returning spawn paint color override (if any) and returns actual vehicle asset (if any). + Defaults to false because some servers have rules and info on the loading screen. - + - Supports redirects by VehicleRedirectorAsset. If redirector's SpawnPaintColor is set, that color is used. + Volume weather mask used while not inside an ambience volume. - + - Supports redirects by VehicleRedirectorAsset. If redirector's SpawnPaintColor is set, that color is used. + If >= 0, overrides vanilla skill cost. + Defaults to -1. - true if matching vehicle asset was found. (Not necessarily whether vehicle was spawned.) - + - Tools like carjacks and tires can be used in safezone by admins for maintenance. + If >= 0, overrides vanilla increase in skill cost with each level. + For example, if the base cost is 10 and this is 15, the first level will cost 10 XP, + the second level 25 XP, the third 40 XP, so on and so forth. + Defaults to -1. - + - Create glazier implementation. Invoked early during startup. + Allows level to override skill max levels. + Null if empty, otherwise matches 1:1 with PlayerSkills._skills. - + - Multiplier for the maximum distance the gunshot can be heard. + If false, clouds are removed from the skybox. - - true if key existed and was removed. - - - true if key existed and was removed. + + + If set, instantiate this particle system and set its material color to cloud color. + - + - Unturned equivalent of unity's PlayerPrefs. - Convenient for saving one-off key-value pairs. + Multiplier for CloudOverrideParticlesPrefab emission rate according to level's clouds intensity. - + - String table specifically for Unity physics material names. - Implemented so that tires can more efficiently replicate which ground material they are touching. + Particle system's material instance will have these color properties set to the level's cloud color. + Defaults to _Color. - + - Get an ID that can be used to reference a physics material name over the network. If given material name - isn't supported (e.g., not registered in a PhysicsMaterialAsset or over max material limit) returns - instead. + t passed into ParticleSystem.Simulate when clouds need an update. - + - Get name of a physics material from network ID. Returns null if ID is null, e.g., if the sent name wasn't - registered or was over the max material limit. + If set, overrides the per-skillset items players spawn with. + Can be used to prevent skillset default items in singleplayer. + Server "Loadout" command takes priority over this option. + Defaults to null. - + - Called when resetting network state. + Players are kicked from multiplayer if their skin color is within threshold of any of these rules. - + - Called on server and singleplayer before loading level. + If true, bypasses SafezoneNode no-buildables mode in singleplayer. - + - Number of bits needed to replicate PhysicsMaterialNetId. + Blueprints can test for these tags. (Future extension here?) - + - Creating all these elements is a bit slow, so we only do it once the menu is first opened. + Controls where attachments looks for ADS alignment transform. - + - Implemented by components to support taking damage from explosions. - Not intended for external use (yet?) and may need to change. + Look for aim alignment transform relative to sight model. + Defaults to Model_0/Aim. - + - Used to exclude dead entities from further evaluation. + Look for aim alignment transform relative to equipable prefab. + Requires setting AimAlignment_Path. - + - Used to sort damage from nearest to furthest. + Factor e.g. 2 is a 2x multiplier. + Prior to 2022-04-11 this was the target field of view. (90/fov) - + - Intended for internal use only. + Zoom factor used in third-person view. - + - Data that we pool to reduce allocations, but needs to be separate per-invocation of explosion in case it's - invoked recursively. (for example, by blowing up a vehicle) + Whether main camera field of view should zoom without scope camera / scope overlay. - + - Replacement for playerDamaged. + If true, scale scope overly by 1 texel to keep "middle" pixel centered. - + - Replacement for zombieDamaged. + Controls where to find AimAlignmentTransformPath. - + - Replacement for animalDamaged. + If set, find this transform relative to AimAlignmentTransformOwner. - + - Refer to ExplosionPoolData for pooling explanation. + Position offset relative to Aim transform or transform specified by aimAlignmentTransformPath. - + - Was necessary when structures were children of level transform. + [0, 1] local distance from center to start of line. - + - Was necessary when trees were children of ground transform. + [0, 1] local width of horizontal line. - + - Somewhat hacked-together to find owner of a vehicle, barricade, or structure descendant. + Whether line/number are on left or right side of the center line. - + - Get average explosionArmor of player's equipped clothing. + If true, text label for distance is visible. - + - Refer to getPlayerExplosionArmor for explanation of total/average. + Which item ID we thought was there. If the item ID currently at the coordinates doesn't match we clear this hotkey. - + + + Start/Stop input is encoded as 2 bits, 1 bit for Start flag and 1 bit for Stop flag. + + Prior to 2023-03-16 it was a single bit. The server would Start if true and the previous frame was false, + and vice versa call Stop if false and the previous frame was true. The problem with that approach was when + the client FPS is higher than the simulation FPS a series of repeated attack presses would be treated as a + continuous held attack input. Semi-auto guns were difficult to shoot at their max rate of fire. Sending both + allows the server to theoretically call Start every simulation frame as opposed to only half. + + First approach was to OR Start if held, otherwise OR Stop. This doesn't work because for example when Aim is + pressed the Stop flag will already be enabled, so the gun Starts aiming, Stops aiming, Starts aiming, and then + stays aiming rather than just Start and stay aiming. Instead we only want Stop to be sent once. + + + - Do damage to a zombie. + Wants to "start" primary or secondary input. (e.g., Useable.startPrimary) - + - Legacy function replaced by damageZombie. + Wants to "stop" primary or secondary input. (e.g., Useable.stopPrimary) - + - Legacy function replaced by damageZombie. + Invoked from tellEquip after change. - + - Do damage to an animal. + Skin applied to the currently equipped useable. - + - Legacy function replaced by damageAnimal. + Does equipped useable have a menu open? + If so pause menu, dashboard, and other menus cannot be opened. - + - Legacy function replaced by damageAnimal. + For aiming toggle input. - + - This unwieldy mess is the original explode function, but should be maintained for backwards compatibility with plugins. + Get ragdoll effect to use when the current weapon deals damage. - + - Used if explosion won't damage anything. + It should be safe to call this immediately because hotkeys are loaded in InitializePlayer. - + - Do radial damage. + Prevent multiple hotkeys from referencing the same item. - + - Server spawn impact effect for all players within range. + Left-handed characters need the stat tracker to be flipped on the X axis so that the text reads properly. + ItemTool doesn't know about left/right handedness, so for the moment that's handled here because only players need this fixed up. - + - Server spawn impact effect for all players within range. Optional "spectator" receives effect regardless of distance. + Match stat tracker gameobject's isActive to whether skins are visible. - + - Server spawn effect by ID for all players within range. Optional "spectator" receives effect regardless of distance. + Match all stat tracker visibilities to whether skins are visible. - + - Server spawn effect for all players within range and instigator receives effect regardless of distance. + Called clientside to ask server to equip an item in the inventory. - + - parent should only be set if that system also calls ClearAttachments, otherwise attachedEffects will leak memory. + Hacked-in to bypass regular clientside checks when client would predict the item at given coords. - + - Nelson 2025-03-10: This aims to avoid messing with Magazine transform IsActive unless skin already did. + Remove the item from inventory so that if we die before the item isn't dropped - + - Nelson 2024-11-15: By default, attachments use their corresponding "hook" transform. For example, magazines - use the "Magazine" transform as their parent. If a child of the hook transform matches a caliber in the - attachment's caliber list that is used instead. + Finish dequipping from - + - Should the buying and selling lists be alphabetically sorted? + Invoked before dealing damage regardless of whether the punch impacted anything. - + - This prevents identical tag provider setups from listing in the UI. - For example, two workbenches providing the same tags shouldn't show two UI listings. + (Temporarily?) separated out from simulate to try and get a better exception call stack. - + - Player does not want to see this blueprint. + (Temporarily?) separated out from simulate to try and get a better exception call stack. - + - Player wants to save this blueprint in a special category. + (Temporarily?) separated out from simulate to try and get a better exception call stack. - + - Find nearby crafting tag providers and query their tags. + Allow UI to process input [0, 9] key press when cursor is visible. - + - Tests whether nearby tags include specified tag. - Doesn't update nearby tags, so call UpdateAvailableCraftingTags if out-of-date. + Process input [0, 9] key press. - + - Requested for plugin use. - Notifies owner they should refresh the crafting menu. + If equipped item is bound to a hotkey, return the button [0, 9] associated. + Otherwise, return -1. - + - Update anything that will not change as blueprint is invoked repeatedly on server. + Called by input when preparing for simulation frame. - + - Update anything that can change as blueprint is invoked repeatedly on server. + Amount of experience to reward harvesting player. - + - Returns true if should exit early. - If updating behavior here please remember to update . + If true, harvesting has a chance to provide a second item. - + - Find all item assets available to the player for crafting. - Used to more quickly identify blueprints that might be craftable, rather than testing all blueprints. - If updating behavior here please remember to update . + If true, rain will finish growing the plant. - + - Allows housing planner to craft without playing effect, without also allowing - cheaters to craft without playing effect. (if it were an RPC param) + NPC rewards to grant upon harvesting the crop. - + - Get local player's per-blueprint preferences. + If true, light contributes to player spotlight. Defaults to true. + + Can be set to false for modders with a custom light setup. For example, this was added + for a modder who is using melee lights to toggle a lightsaber-style glow. - + - Set local player's per-blueprint preferences. - This is helpful both to prevent accidentally crafting certain blueprints (like blindfolds) when click to - craft is enabled, and to save frequently used blueprints. + 32-bit mask granting server plugins additional control over custom UIs. + Only replicated to owner. + + + + + Enables cursor movement while not in a vanilla menu. - + - Why isn't tags list public visibility? Because if adding features to (for example) consume a resource when - crafting tag provider is used that will require an API change. + Disable background blur regardless of other UI state. - + - Extensions to the built-in Screen class. - We have run into multiple problems with the Screen.resolutions property over the years, so this class aims to - protect against bad data. + Enable background blur regardless of other UI state. + Takes precedence over NoBlur. - + - Work-in-progress plan to allow modders to create custom physics effects. + Enable title card while focusing a nearby player. - + - Can crops be planted on a given material? + Enable explanation and respawn buttons while dead. - + - Can oil drills be placed on a given material? + Enable health meter in the HUD. - + - Original width field is misleadingly named. It represents half the width of the flat section of the road. + Enable food meter in the HUD. - + - Original depth field is misleadingly named. It represents half the "up" size of the road. + Enable water meter in the HUD. - + - Distance along the terrain surface normal to move each road vertex. + Enable virus/radiation/infection meter in the HUD. - + - New code should not use this. Only intended for backwards compatibility. + Enable stamina meter in the HUD. - + - Ideally the interactable components should have a reference to their barricade, but that will maybe happen - after the NetId rewrites. For the meantime this is to avoid calling FindBarricadeByRootTransform. If we go - the component route then FindBarricadeByRootTransform will do the same as this method. + Enable oxygen meter in the HUD. - - -1 if table was not found. - - + - By default, clickable only responds to LeftMouse without the Control modifier. - Unturned (currently) filters left/right mouse and modifiers outside Glazier, - so add activators for left/right and control modifier to all clickables. + Enable icons for bleeding, broken bones, temperature, starving, dehydrating, infected, drowning, full moon, + safezone, and arrested status. - + - USS best practices mentions inline styles have a higher memory overhead, so we - only apply an inline value if it doesn't match the default :root font style. + Enable UseableGun ammo and firemode in the HUD. - + - USS best practices mentions inline styles have a higher memory overhead, so we - only apply an inline value if it doesn't match the default :root text alignment. + Enable vehicle fuel, speed, health, battery charge, and locked status in the HUD. - + - Ehh kind of a stretch to mark this obsolete or for backwards compatibility. Introducing it for road assets - which specify the PhysicMaterial to assign to the colliders. Specifying an asset path is available, but - for the common case we will use the built-in vanilla resources. + Enable center dot when guns are not equipped. - + - Get legacy enum corresponding to Unity physics material object name. - Moved from obsolete checkMaterial method. + Enable popup when in-game rep is increased/decreased. - + - If collider and its physics material are not null, get the physics material's name. Null otherwise. - - Nelson 2025-04-22: this method may seem silly on first glance. However, I tracked down some every-frame - memory allocation to getting the PhysicMaterial.name property. This method caches the instance ID to - name lookup in a dictionary to avoid that. Note: we don't worry about clearing the dictionary because - there aren't very many physics materials. + Default flags set when player spawns. - + - Base class for uGUI implementations of primitive building block widgets. + 32-bit mask indicating to the server which admin powers are being used. + Does not control which admin powers are available. - + - Called after constructor when not populating from component pool. + Player is using spectator camera. - + - Called after constructor when re-using components from pool. + Player is using barricade/structure transform tools. - + - Synchronize uGUI component colors with background/text/image etc. colors. - Called when custom UI colors are changed, and after constructor. + Player is using overlay showing player names and positions. - + - Synchronize uGUI component sprites with theme sprites. - Called when custom UI theme is changed, and after constructor. + Per-player event invoked when admin usage flags change. - - False if element couldn't be released into pool and should be destroyed. - - + - Unity recommends enabling components after parenting into the destination hierarchy. + Event invoked when any player's admin usage flags change. - + - RectTransform children should be attached to. Overridden by ScrollView content panel. + Used by plugins. - + - This helper property's purpose is to: - - Ensure other properties don't accidentally remove LayoutElement if others need it. - - Ensure LayoutElement is destroyed before returning to pool. + Invoked on client when a plugin changes the widget flags. - - - Parameters for connecting to a game server. - - Admittedly there are other parameters to the Connect method, - but those are for detecting advertisement discrepencies and can be null. - - - + - Server's public IP address of a Steam "Fake IP" address. + Exposed for Rocket transition to modules backwards compatibility. - + - Port for Steam's "A2S" query system. This the port we refer to when - sharing a server's address (e.g., 127.0.0.1:queryport). + Not rate limited because server tracks number of expected screenshots. - + - Port for game traffic. i.e., Steam manages the query port socket while - we manage the connection port socket. The game assumes it's the query - port plus one. NOTE HOWEVER after the introduction of "Fake IP" support - (2023-12-07) the connection port is the same as the query port for fake - IPs. In keeping with the spirit of fake values to simplify existing code, - we act as if the connection port is plus one except in the appropriate - ClientTransport code when the fake IP is detected. + Request client to open a given URL. + Allows plugins to open web browser, but also gives client the chance to ignore it. - + - Referred to as "Server Code" in menus. - Used if address is zero. + Tell client to join a specific server. + Disconnects client and sends them to the join server screen. + Only used by plugins. - + - If -1, this region is finished activating/deactivating. - Otherwise, incremented once per frame until per-region count is reached. - - Per-region data is removed when isInsideMask is false and progressIndex is -1. + Is this player currently in a plugin's modal dialog? + Enables cursor movement while not in a vanilla menu. - + - If true, this region is within MaxDistance of current CameraCoord. + Tell the client whether to be in plugin modal mode or not. + Kept from prior to introduction of pluginWidgetFlags. - + - Tracks activation and deactivation of Regions as camera moves around the level. + If true, bypass player culling test as if freecam overlay were active. + Enables plugins to implement a custom admin culling bypass switch. (Was requested.) + Defaults to false. - + - Mark all cells as finished loading and remove cells outside the camera view. - Used after teleporting or loading. + Which admin powers are currently in use by the client. + Reported to the server by the client. + Does not control which admin powers are available. + Note: Hacks can prevent this notification from being sent. - + - Caller passes an empty dictionary to be filled with update info. - Increments progressIndex for each returned region. - If region is finished updating, call NotifyRegionFinishedUpdating. + Called on the client to notify the server of admin usage changes (if any). - + - Called when progressIndex has reached end of given region. + Called on the client to notify the server of admin usage changes (if any). - + - Fill output set with mask offsets applied to current camera coordinate. + Teleport to a random player spawn designated in the level. - + - Find changes between old and current coordinate sets to mark regions in/out of mask. + Teleport to bed, if player has set one. - + - Reset region's progress counter and change inside/outside status. + Teleport is always handled by owner and locally (loopback), but *not* by culled clients. - + - Allows Unity events to spawn effects. + Get simulation center of mass. - + - GUID of effect asset to spawn when SpawnDefaultEffect is invoked. + How many calls to will succeed per second. - + - If true the server will spawn the effect and replicate it to clients, - otherwise clients will predict their own local copy. + How many rate limited actions have been performed recently. + Increased after performing each rate limited action, and decreased over time. + Cannot perform actions when greater than one. - + - Should the RPC be called in reliable mode? Unreliable effects might not be received. + Note: new official code should be using per-method rate limit attribute. + This is kept for backwards compatibility with plugins however. + + Call this method before any requests the client can spam to the server. + Should your code proceed with the rate limited action? - + - Transform to spawn the effect at. - If unset this game object's transform will be used instead. + Call every frame to cool down rate limiting. - + - Applied if greater than zero. Defaults to 128. + This code was in the Start message, and should happen before other initialization. - + - Marker for counting number of tips. + Hacky replacement for Start() that runs after net ids are assigned but before sending player state. - + - Camera used while transitioning between scenes to prevent the "no cameras rendering" warning. + Nelson 2024-11-11: Added to help narrow down if player is destroyed outside of Provider.removePlayer. + (public issue #4760) - + - Shown when game connection ping is significantly higher than server browser ping. At the time of writing - (2025-01-17) this is likely because the server is using an "anycast proxy" in front of Steam A2S cache. + Maximum count of naturally spawned boss zombies. Unlimited if negative. + Game will not spawn/respawn boss zombie types passing this limit, but quest spawns can bypass it. - + - Set to Time.frameCount + 1 while loading. - In the past used realtime, but that was unreliable if an individual frame took too long. + When a client method is called on a target object that does not exist yet this class is responsible for + deferring the invocation until the instance does exist. For example until finished async loading. - + - Select a loading image while on the startup screen or a level without any images. + Called by generated methods when target object does not exist. If target object has been marked deferred + then the method will be invoked after it exists. - + - Convert world-space point into region coordinates that may be out of bounds. + Add list of deferred invocations for key. Otherwise messages will be discarded assuming it was canceled. - + - Convert world-space position into a region coordinate that may be out-of-bounds. + Remove pending invocations. - + - Returns true if coord is within legacy range. + Invoke all deferred calls. - + - Clamp position into the maximum bounds expected by the game, not necessarily the level bounds. + Invocations are grouped by net id block to ensure order is preserved between related objects. - True if position was modified. - + - Kick players maybe trying to impersonate me. I guess nobody else named Nelson is allowed in the game! - 2023-09-19: relaxed this a bit by trimming names and using Equals/Starts/Ends rather than Contains - because there was a player with Nelson in their username. + Not a member of ClientMethodInfo because it does not need to be looked up using reflection. - + - GUID of the asset this is referring to. + Called before loading level. - + - Whether the type has been asigned. Note that this doesn't mean an asset with exists. + Parses fv:X from input string and loads X.txt from game folder. - + - True if resovling this type reference would get that type. + Has the contained been animated into visibility on-screen? + Used to disable animating out if disabled. - + - Maximum count of naturally spawned boss zombies. Unlimited if negative. - Game will not spawn/respawn boss zombie types passing this limit, but quest spawns can bypass it. + If true, object is within a culling volume. + Name is old and not very specific, but not changing because it's public. - + - Base class for UIToolkit implementations of primitive building block widgets. + Transform created to preserve objects whose assets failed to load. + Separate from default transform to avoid messing with old behavior when transform is null. - + - Set by child. + If true, can be instantiated. Defaults to true. + Enables mappers to remove culling volumes embedded in objects if they're causing issues. - + - Synchronize control colors with background/text/image etc. colors. - Called when custom UI colors are changed, and after constructor. + Can this object's rubble be damaged? + Allows holiday restrictions to be taken into account. (Otherwise holiday presents could be destroyed out of season.) - + - If set, takes priority over VehicleRedirectorAsset's paint color and over VehicleAsset's default paint color. + Object activation is time-sliced, so this does not necessarily match whether the region is active. - + - Returned asset is not necessarily a vehicle asset yet: It can also be a VehicleRedirectorAsset which the - vehicle spawner requires to properly set paint color. + Defaults to true because most objects are not inside a culling volume. - + - Plugin-only event when throwable is spawned on server. + Used by InteractableObjectBinaryState to indicate whether it wants navGameObject to be active. It's only + active if both IOBS and Rubble want it active. - + - Allows NPCs to trigger plugin or script events. + Used by InteractableObjectRubble to indicate whether it wants navGameObject to be active. It's only + active if both IOBS and Rubble want it active. - + - instigatingPlayer can be null. For example, if instigated by NpcGlobalEventMessenger. + Used if the object asset has weather blend alpha conditions. - + - Circular mask for 2D distances in meters on a 2D cell grid. - Includes a cell if the meters distance between the center cell - and the closest point on test cell is within radius. + Used if the object asset has weather status conditions. - + - World space distance in meters. + Callback when an individual quest flag changes for the local player. + Refreshes visibility conditions if the flag was relevant to this object. - + - Region cell size in meters. + Separate from UpdateActiveAndRenderersEnabled so graphics settings can call it. - + - Data in common between list downloaded from a GET request and a ServerListCurationAsset. + Assume renderers default to enabled. - + - Optional web image path if icon isn't included. + Used by the server to validate client Unity player files (assemblies and resources). - + - Incremented during server list refresh for each server blocked by this rule. + Should players be allowed to join this server regardless of whether their DLL hash matches ours? + Useful to allow players to join debug mode servers. - + - Starting position when the bullet was fired. + Should players be allowed to join this server regardless of whether their resources hash matches ours? + Useful to allow players to join debug mode servers. - + - Only available on the server. For use by plugins developers who want to analyze deviation between approximate - start direction and final hit position using and - per public issue #4450. Note that origin and direction on server are not necessarily exactly the same as on - the client for a variety of reasons, including that bullets on the client can be spawned between simulation - frames when the aim direction was different. (Aim direction is updated every drawn frame on the client as - opposed to every simulation frame on the server.) Rather than kicking for one particularly large deviation - we would recommend tracking stats for each shot's actual deviation vs max theoretical deviation. Remember - to account for bullet drop and that aim spread is relative to this direction. (For example, a shotgun may - fire ~8 pellets in a cone around this direction.) Note also that in third-person the bullet can turn up to - 90 degrees from the aim direction if the camera is up against a wall. + Can be added to any GameObject to listen for the Event NPC reward type. - + - Combination of gun and attachments' bullet gravity multipliers. + *_ID configured in NPC rewards list. - - Whether plugin allowed attachment. - - + - Plugin-only event when bullet is fired on server. + If true the event will only be invoked in offline mode and on the server. - + - Plugin-only event when bullet hit is received from client. + Invoked when NPC global event matching EventId is processed. - + - Plugin-only event when projectile is spawned on server. + Thanks to Glenn Fiedler for this RK4 implementation article: + https://gafferongames.com/post/integration_basics/ - + - reticuleHook.localPosition after instantiation, or zero if null. + Higher values return to the target position faster. - + - True if startPrimary was called this simulation frame. - Allows gun to shoot even if stopPrimary is called immediately afterwards. + Higher values reduce bounciness and settle at the target position faster. + e.g. a value of zero will bounce back and forth for a long time (indefinitely?) - + - Remaining calls to tock before firing. + Represents an item the vendor is buying from players. - + - Shot counter used by needsRechamber and RechamberAfterShotCount. + Can be added to any GameObject to receive weather events for a specific custom weather asset. - + - Is the tactical attachment toggle on? - e.g. True when the laser is enabled. + GUID of custom weather asset to listen for. - + - Should stat modifiers from the current tactical attachment be used? + Invoked when custom weather is activated, or immediately if weather is fading in when registered. - + - Factor e.g. 2 is a 2x multiplier. - Prior to 2022-04-11 this was the target field of view. (90/fov) + Invoked when custom weather finishes fading in, or immediately if weather is already fully active when registered. - + - Zoom multiplier in third-person. + Invoked when custom weather is deactivated and begins fading out. - + - Whether main camera field of view should zoom without scope camera / scope overlay. + Invoked when custom weather finishes fading out and is destroyed. - + - Original barrel and magazine assets are supplied because they may have already been deleted. Barrel is only - valid if quality was greater than zero. + GUID parsed from WeatherAssetGuid parameter. - + - Called on server and owning client. + Helpers on the dedicated server to optimize client prefabs for server usage. - + - Calculate damage multiplier for individual bullet. + Optimize client prefab for server usage. - + - Requested for plugin use. + Nelson 2025-03-10: This aims to avoid messing with Magazine transform IsActive unless skin already did. - + - Request from the server to play a gun jammed animation. - Since client can't predict chamber jams we fixup the predicted ammo count. + Nelson 2024-11-15: By default, attachments use their corresponding "hook" transform. For example, magazines + use the "Magazine" transform as their parent. If a child of the hook transform matches a caliber in the + attachment's caliber list that is used instead. - + - Note: This is the m/s² acceleration, not the multiplier. + Returned asset is not necessarily a vehicle asset yet: It can also be a VehicleRedirectorAsset which the + vehicle spawner requires to properly set paint color. - + - This is a bit of a hack... aimAccuracy is [0, maxAimingAccuracy] and changed during each FixedUpdate call, - but was used in some gameplay display features like holo sight, laser, ADS, etc. (yes, should - be de-coupled from FixedUpdate but that is its own issue) To smooth this out we interpolate - slightly behind the aimAccuracy value depending on the time since FixedUpdate. + Optional parameter for error logging and responding to the invoker. - + - Holographic sights follow the true aiming direction regardless of viewmodel animation. + How many seconds message should popup. - + - Note: This is the multiplier, not the m/s² acceleration. + No longer used in vanilla. Kept in case plugins are using it. - + - Code common for regular gun and sentry gun. + No longer used in vanilla. Kept in case plugins are using it. - + - Consolidates parameters for older, separate inventory search methods. - - The "player" part of the name refers to the PlayerInventory-specific parameters. It can still be used to search - the Items class, in which case those parameters do not apply. + No longer used in vanilla. Kept in case plugins are using it. + + + + + Actual internal implementation. - + - List to populate with matching items. + World to local bounds only works well for axis-aligned icons. - + - If true, search player's primary and secondary weapon slots. - Only applicable when used with PlayerInventory class. (I.e., not Items class.) + Unity's Camera.orthographicSize is half the height of the viewing volume. Width is calculated from aspect ratio. - + - If true, search storage container player is currently interacting with (if any). - Only applicable when used with PlayerInventory class. (I.e., not Items class.) + Original type on the Russia map which requires a mask with filters. - + - If greater than zero, search exits early once Results count meets MaxResultCount. + Requires a mask with filters and full body suit. - + - If set, item must be this type to match. + Damage dealt to players while inside the volume if they *don't* have clothing matching the deadzone type. + Could help prevent players from running in and out to grab a few items without dieing. - + - If set, AssetRef must be a reference to item's asset to match. - Replaces older "id" parameter which matched if item's legacy asset ID was the same. + Damage dealt to players while inside the volume if they *do* have clothing matching the deadzone type. + For example, an area could be so dangerous that even with protection they take a constant 0.1 DPS. - + - If true, items with amount of zero can match. Otherwise, they are ignored. - Replaces older "findEmpty" parameter which matched if (findEmpty || amount > 0). + Virus damage to players while inside the volume if they *don't* have clothing matching the deadzone type. + Defaults to 6.25 to preserve behavior from before adding this property. - + - If true, items with an "amount" >= their MaxAmount are ignored. Otherwise, they can match (default). + Rate of depletion from gasmask filter's quality/durability. + Defaults to 0.4 to preserve behavior from before adding this property. - - + - If set, item must be of type ItemCaliberAsset. Asset's caliber list must either: - • Contain this caliber ID. - • Or, if empty, IncludeUnspecifiedCaliber must be true. - Otherwise, item is ignored. + This value is confusing because in the level editor it is the normalized radius, but in-game it is the square radius. - + - If set, item must be of type ItemCaliberAsset. Asset's caliber list must either: - • Contain one of these caliber IDs. - • Or, if empty, IncludeUnspecifiedCaliber must be true. - Otherwise, item is ignored. + Nelson 2024-06-10: Added this property after nodes were converted to volumes. i.e., only old levels from + before this property were added still have nodes, so it's expected that they won't deal damage over time. - + - Only applicable if CaliberId or AnyCaliberIds is set. - If true, assets with an empty calibers list can match. Otherwise, they are ignore.d + Same description as . - + - If set, do not include this specific item instance in search results. - Kind of hacked-in for ignoring "target item" as a potential input item. + Same description as . - + - Nearly identical to InventorySearch aside from: - • Struct instead of class to improve garbage collection performance in pooled lists. - • More understandable name. - • Provides reference to Items holding "Jar." Longer-term this should be preferred over the "Page" property. + Same description as . - + - Serverside delete an amount of this item. + Counts hits per-IPv4 address (if available) and per-SteamID (if available). + Connection is blocked if more than "threshold" hits occur within category (IPv4/SteamID). + Hit count resets when "window" seconds have passed since last hit. - False for crafting where original item can be kept, true when selling to vendors. - Total amount deleted. - + - -1 if no eligible item is found. - If includeMaxQuality is true an item with quality of 100 can be "lowest quality", otherwise item has to - be less than 100 quality. + If hit is within this many seconds of previous hit, it counts. Otherwise, counter is reset. - + - Please use PlayerInventorySearchResultV2 for better performance! + If more than this many hits occur the limit is reached. - + - Serverside delete an amount of this item. + Matches the console behavior prior to command IO refactor. - Total amount deleted. - + - Used by the server to validate client Unity player files (assemblies and resources). + Hack, we put this string on a newline for box probabilities. - + - Should players be allowed to join this server regardless of whether their DLL hash matches ours? - Useful to allow players to join debug mode servers. + Auto-registering list of volume manager subclasses for level editor. - + - Should players be allowed to join this server regardless of whether their resources hash matches ours? - Useful to allow players to join debug mode servers. + Should calling InstantiateVolume create a new volume? + False for deprecated (landscape hole volume) types. - + - Experience to add or subtract when used. Defaults to zero. + The game uses Process.Start to open web links when the Steam overlay is unavailable, which could be exploited + to e.g. download and execute files. To prevent this we only allow valid http or https urls. + If true, prefix with https:// if neither http:// or https:// is specified. - + - Canned beans have skins from April Fools. + This version just doesn't return the parsed URL. - + - Note: if calling ItemRef.Get() please use FindItemAsset instead to avoid redundant asset lookups. + Version before named version constants were introduced. (2023-11-07) - + - Does this blueprint output create the specified item? + Delegate not reset when level reset. - + - Reset dragging handle and register transformation. + Delegate not reset when level reset. - + - If true, vest and backpack spawn System_Area instead of System_Hook. + Delegate not reset when level reset. - + - Sets the point to lerp from, should be called after resetting position or things like that. + Delegate not reset when level reset. - + - Logs enabled when WITH_NSB_LOGGING is defined. - Tracking down an issue where snapshot buffer stops working for groups of networked objects. + Number of in-game days this world has run. + Incremented each time night ends. + Saved between sessions. - + - When adding or removing entries remember to update NetMessages size and regenerate NetCode! + Weather has not been decided yet. Level might not have any enabled. - + - Server sent a ping. + Weather has been forecast. Timer counts down until activation. - + - Server replying to our ping. + Weather is now active. Timer counts down until deactivation. - + - Server is shutting down shortly. + Weather is active. Will not deactivate naturally. + Prevents loaded perpetual weather from deactivating. - + - Create game object for player. + Determines which weather can naturally be scheduled in this level. + Includes default rain and snow for older levels. - + - Destroy game object for player. + Seconds until weather activates. - + - Download these files before loading the level. + Seconds until weather deactivates. - + - Server wants additional info before accepting us. + Forecast or active weather. - + - Server has accepted us and will create a player game object. + Set weather active and disable scheduling. - + + True if given weather has config. + + - Server rejected us, we will go back to the menu. + Cancel scheduled weather and re-evaluate on next update. - + - Banned either during connect or gameplay. + Cancel active weather and prevent next weather from being scheduled. - + - Kicked during gameplay. + Get weather override for the currently loaded level. + Warning: this is kept for backwards compatibility, whereas newer maps will set LevelAsset.perpetualWeather. - + - Should be converted to an RPC. Leftover from prior to net messaging code. + Assign schedulableWeathers array according to level asset or legacy lighting settings. - + + True if perpetual weather was enabled, false otherwise. + + - Should be converted to an RPC. Leftover from prior to net messaging code. + Number of players inside the navmesh when the beacon was placed. + Clamped to 1 if ShouldScaleWithNumberOfParticipants is false. - + - Server sending BattlEye payload to client. + The base transform does not rotate, instead a child transform is created with the pivot in the center. - + - Infrequent notification of queue position. + To work around a uGUI bug we always a sign a texture, even if desiredTexture is null. - + - Server calling an RPC. + Utilities for calling workshop functions without worrying about client/server. + This could be nicely refactored into a client and server interface, but not enough time for that right now. - + - Allow Unity events to apply damage in a sphere. (doesn't have any visual effects) - Intended to replace unsupported/unintentional use of "Grenade.cs" and "Rocket.cs" scripts. + Client/server safe version of GetQueryUGCNumKeyValueTags. - + - Zombie explosion types have slight variations e.g. lighting zombies on fire. + Client/server safe version of GetQueryUGCKeyValueTag. - + - If greater than -0.5, overrides default radius zombies and animals will be alerted within. + Search for the value associated with a given key. - + + + Client/server safe version of GetQueryUGCResult. + + + - If true, per-surface effects like blood splatter are created. + Is file banned? - + - If true, explosion damage passes through Barricades and Structures. + Contains presetsScrollView which contains customPresetsContainer and defaultPresetsContainer. - + - Speed to launch players away from blast position. + Contains column buttons and server list itself. - + - If true and player has no shirt equipped, use fallback shirt as equipped shirt. - Used by oversize vest and zip-up vest so they are visible without a shirt equipped. + Synchronize widgets with their values. - + - Overrides how fall damage is calculated when landing on this game object or its descendants. + Does having this item show the compass? - + - Could be extended in the future to increase, decrease, or set fall damage. + Does having this item show the chart? - + - Potentially useful for an event to toggle the override. + Does having this item show the satellite? - + - Character will not take any fall damage. + Note: as of 2025-04-23 this *can* be null. (E.g., audio-only effects.) - + - Payload for the DamageTool.damageZombie function. + If set, use OneShotAudioParameters to play this audio. - + - Should game mode config damage multiplier be factored in? + If true the music option is respected when this effect is used by ambiance volume. - + - Equivalent to the "armor" parameter of the legacy damage function. + In multiplayer the effect will be spawned for players within this radius. - + - Defaults to 1. + Currently used by plugins to identify what damaged a buildable. - + - If not null and damage is applied, is called with this position (startle: true). + Explosion instigated by . - + - If non-zero, NPC name is shown as ??? until bool flag is true. + Are any players standing on the mannequin? + Used to prevent exploiting pose switches to push through objects. - + - This value is confusing because in the level editor it is the normalized radius, but in-game it is the square radius. + Payload for the EffectManager.triggerEffect method. - + - Returning an Asset rather than the older IDs allows GUIDs to be used. - legacyTargetAssetType is required for compatibility with spawn tables using legacy 16-bit IDs. If set to - None and the spawn asset uses legacy IDs a warning is logged explaining GUIDs are necessary. + Required effect to spawn. - - + - Doesn't support spawn assets with legacy 16-bit IDs. + World-space position to spawn at. - + - For backwards compatibility with features that still need a legacy ID rather than asset. + Local-space scale. Defaults to one. - + - For backwards compatibility with features that still need a legacy ID rather than asset. + If running as server should this effect be replicated to clients? + Defaults to true. Set to false for code that is called on client AND server. - + - For backwards compatibility with features that still need a legacy ID rather than asset. + Should the RPC be called in reliable mode? Unreliable effects might not be received. - + - If using a map or mods from the workshop, this class monitors them for changes so the server can be restarted. + Was a player directly responsible for triggering this effect? + For example grenade explosions are instigated by players, whereas zombie acid explosions are not. + Used to prevent mod damage on the effect prefab from hurting players on PvE servers. - + - Request status of workshop items. + Players within this radius will be sent the effect unless the effect overrides it. + Defaults to 128. - + - Called the next tick after update(s) detected. + Get world-space rotation for the effect. - + - Called when a queried item's update timestamp is newer than our initially loaded version. + Set world-space rotation for the effect. - + - Called when results from a call to submitQueryRequest are available. + World-space rotation for the effect. - + - Called once timer reaches interval. + If true, rotation was specified by setter methods. + Required for backwards compatibility because `direction` field is public. - + - Were update(s) detected that should be handled on next tick? + Only send the effect to the given player, if set. - + - Are we done monitoring? - Default finished once an update is detected. + Only send the effect to the given players, if set. + Otherwise relevantDistance is used. - + - Interval between query submissions. + Only send the effect to the given player, if set. - + - Accumulated time before submitting query after passing interval. + World-space direction to orient the Z axis along. Defaults to up. - + - Callback from Steam when results from a call to submitQueryRequest are available. + Allows mappers to bulk replace assets by listing pairs in a text file. + https://github.com/SmartlyDressedGames/Unturned-3.x-Community/issues/2275 - + - Slightly interpolated copy of actual spread angle to smooth out sharp changes like crouch/prone. + If a redirector for oldGuid exists, returns target asset. Otherwise null. - + - Allows interpolatedSpread to snap to target value when crosshair becomes visible. + Thanks to Glenn Fiedler for this RK4 implementation article: + https://gafferongames.com/post/integration_basics/ - + - Deserialize JSON onto an existing object instance. + Higher values return to the target position faster. - + - Potentially useful for players with corrupted cloud storage. - https://github.com/SmartlyDressedGames/Unturned-3.x-Community/issues/2756 + Higher values reduce bounciness and settle at the target position faster. + e.g. a value of zero will bounce back and forth for a long time (indefinitely?) - + - Introduced much later (2020) than most of the other methods in this class (2014) in order to properly handle - BOM/preamble of text files. Matches somewhat undesirable legacy behavior like creating directories. + At low framerate deltaTime can be so high the spring explodes unless we use a fixed timestep. - + - NOTE: From and to are both relative to PATH. + Is current UTC time within this time span, and player has not dismissed? - + - Read GUI texture from a .jpg or .png file. + Has the current time span been dismissed? + For example, player may have dismissed a previous event but not this current one. - + - Read GUI texture from a .jpg or .png file. + Is current UTC time within this time span? - + - Windows-specific extensions of console input. - Uses the Win32 API to force a console to be created and destroyed. + Sets the point to lerp from, should be called after resetting position or things like that. - + - Called by navmesh baking to complete pending object changes that may affect which nav objects are enabled. + Logs enabled when WITH_NSB_LOGGING is defined. + Tracking down an issue where snapshot buffer stops working for groups of networked objects. - + - Hide culling volume by default because new mappers might wonder what these purple boxes - are and why their number goes away after moving objects. + Non-item replacement for SleekJars. + Arranges children in an equally-spaced ring around the center. - + - Check a fixed number of volumes for visibility updates per frame. + Button in a list of levels. - + - Any volumes in the process of enabling/disabling get updated once per frame. + Button in the list of levels for server browser filters. - + - True for the next update after the player is teleported. + Button in the list of levels for the map editor. - + - Associates items of the same currency, e.g. dollars or bullets. + Note: this can be different from status.blueprint after status refreshes because status is pooled. - + - Should this item/value be shown in the list of vendor currency items? - Useful to hide modded item stacks e.g. a stack of 100x $20 bills. + Update the title box describing the "most important" item: item to repair, salvage, craft, etc. - + - String to format value {0} into. + Can be added to EquipablePrefab item GameObject to receive events. - + - String to format value {0} of total {1} into if not otherwise specified in NPC condition. + Invoked when gun is fired. - + - Sum up value of each currency item in player's inventory. + Invoked when gun begins reload sequence. - + - Does player have access to items covering certain value? + Invoked when gun begins hammer sequence. - + - Add items to player's inventory to reward value. + Invoked when gun begins aiming. - + - Remove items from player's inventory to pay required value. + Invoked when gun ends aiming. - + - Sort currency entries by value. + Invoked when Magazine game object is activated. - + - Temporary replacement for static block member because plugins might depend on it. + Invoked when Magazine game object is activated. - + - Parses fv:X from input string and loads X.txt from game folder. + When moving between physics materials we need to continue any previous tire kickup particles until they expire. + This class manages the individual effect per-physics-material. Each wheel can have multiple at once. When the + particles have despawned and the effect is no longer needed, the effect game object is returned to the effect + pool and this class is returned to . - + - Called after lod bias may have changed. + Name from . - - - Can be added to any GameObject with an interactable binary state in its parents. - - If players should not be allowed to interact with the object in the ordinary manner, - add the Interactability_Remote flag to its asset to indicate only mod hooks should control it. - + + + Instantiated effect. Null after returning to pool. + - + - When a state change is requested in singleplayer it should be treated as if running as a client on a server. - This is the default to match behavior from before this option was added. + Effect's transform. Null after returning to pool. - + - When a state change is requested in singleplayer it should be treated as if running as a dedicated server. + Component on gameObject. Null after returning to pool. - + - Invoked when interactable object enters the Used / On / Enabled state. + Whether this effect should be emitting particles. False stops the particle system immediately, whereas true + only starts playing on the next frame to avoid filling a gap between positions, e.g., after a jump. - + - Invoked when interactable object enters the Unused / Off / Disabled state. + Prevents repeated lookups if asset is null, while allowing asset to be looked up each time this effect + becomes active so that it can be iterated on without restarting the game. - + - Should the OnStateEnabled and OnStateDisabled events be invoked when the object is loaded, becomes relevant - in multiplayer, and is reset? True is useful when visuals need to be kept in sync with the state, whereas - false is useful for transient interactions. + Does this wheel affect brake torque? - + - If true, OnStateEnabled and OnStateDisabled are only invoked in singleplayer and on the server. + Turn on/off physics as needed. Overridden by isAlive. - + - If true, calls to GotoEnabledState, GotoDisabledState, and ToggleState are only processed in singleplayer - and on the server. + [0.0, 1.0] normalized position of wheel along suspension. - + - Controls how state change requests are performed when running as both client and server ("listen server"). - On the dedicated server, requesting a state change overrides the current state without processing NPC - conditions, whereas when a client requests a state change NPC conditions apply. This option fixes the - inconsistency in singleplayer of whether to treat as server or client. (public issue #4298) - At the time of writing (2024-01-29) listen server only applies to singleplayer. + [0.0, 1.0] normalized position animated toward replicatedSuspensionState. - + - Set state to Enabled if currently Disabled. - - On dedicated server this directly changes the state, - but as client this will apply the usual conditions and rewards. + Model position interpolated toward animatedSuspensionState according to modelSuspensionSpeed. - - - Set state to Disabled if currently Enabled. + + + [0, 360] angle of rotation around wheel axle. Measured in degrees because Quaternion.AngleAxis takes degrees. - On dedicated server this directly changes the state, - but as client this will apply the usual conditions and rewards. - + We track rather than using GetWorldPose so that we can alternate between using replicated and simulated + results without snapping transforms. + - - - Toggle between the Enabled and Disabled states. - - On dedicated server this directly changes the state, - but as client this will apply the usual conditions and rewards. - + + + List is created if this wheel has a collider and uses collider pose. Null when vehicle is destroyed to + prevent creation of more effects. + - + - Tests whether current or recent history contains point. + Instance corresponding to current ground material. Doesn't necessarily mean the particle system is active. - + - One second history at 50 tickrate. + Called after construction and on all clients and server when a player stops driving. - + - Not originally supported by networking. Added temporarily during netpak rewrite because the quaternion - compression is so much better for vehicles than three byte Euler rotation. + Called when vehicles explodes. - + - Gets barricades both attached to vehicles and not attached to vehicles. + Called during FixedUpdate if vehicle is driven by the local player. - + - Nelson 2025-04-08: thank goodness that this didn't use the temperature system! (For some reason?) Makes it - relatively straightforward to convert campfires and ovens to Crafting Tags, and means vanilla has a test - case for the mod hook, too. (This method tests for CraftingHeatTag in radius.) + Calculate suspension state from GetWorldPose result. + + Nelson 2024-03-25: Originally we used the result of GetWorldPose for the model transform and calculated + the suspension state from it because I thought Unity was internally using the spring position that isn't + (currently) exposed to the API. Whether or not it is, it seems fine to calculate the spring position using + the ground hit point instead. We switched entirely away from GetWorldPose so that the wheel can retain + its roll angle when transitioning between locally simulated and replicated. - + - Index into Blueprints list. -1 means blueprint name is used instead. + Called during Update on dedicated server only if replicated suspension state is enabled. - + - Name to look for in Blueprints list. + Set replicated suspension state AND animated suspension state when vehicle is first received. + - + - Other menus can modify DevkitSelectionToolOptions so we need to sync our menu when opened. + Supported when locally simulated and on remote clients. - + - Thanks to Glenn Fiedler for this RK4 implementation article: - https://gafferongames.com/post/integration_basics/ + Called during Update on client. - + - Higher values return to the target position faster. + Called during Update if vehicle is driven by the local player. - + - Higher values reduce bounciness and settle at the target position faster. - e.g. a value of zero will bounce back and forth for a long time (indefinitely?) + Called during Update on the server while vehicle is driven by player. - + - Should objects that failed to load due to missing assets be saved? - If true, a placeholder transform is created and used to save. - If false, objects without assets are zeroed during save. (old default) + Given path to a workshop map, try to find its /Bundles folder. - + - Hash of Objects.dat + Given path to a workshop map, try to find its /Content folder. - + - Called by navmesh baking to complete pending object changes that may affect which nav objects are enabled. + Maps on the workshop are a root folder named after the published file id, containing + the map folder itself with the level name. In order to load the map's bundles and content + properly we need to find the nested Bundles and Content folders. - + + If true, include current animation speed modifier. + + + True if an animation was found and started playing. + + - Stagger regional visibility across multiple frames. + If level is using underground whitelist then conditionally clamp world-space position. - + - Caches uint16 ID to ID redirects. + If level is using underground allowlist then conditionally clamp world-space position. - - Matches handle returned by request, or -1 if cached. + + + Used by animals and zombies to teleport to a spawnpoint if outside the map. + - + - Revive all trees in a specific region. + Used by housing validation to check item isn't placed underground. - + - Revive trees worldwide. Used between arena rounds. + BuildDescription implementations can use this to concatenate longer strings. - + - Material instantiated when dual-render scopes are enabled. - Overrides the material of the gun sight attachment. + Determines which info is automatically added to the item description. - + - Unintuitively (to say the least), a pitch of 0 is up, 90 is forward, and 180 is down. + Do not add any of the newer info to the description. + Equivalent to Use_Auto_Stat_Descriptions false. + Also applicable when using IMGUI. - + - Nelson 2025-06-27: previously, stopping aim cancelled the sway offset immediately. When - experimenting with removing the dual-render scope blur this felt jarring. + Include names of gun's attachments in the description. - + - Reset to actual fov when first used. + Include any other info without its own flag. + + This only exists because description flags are retrofitted over an all-or-nothing + option (Use_Auto_Stat_Description). - + - If true, freecam controls take input priority. - Previously named isOrbiting. + Add as much info to the description as possible. + Equivalent to Use_Auto_Stat_Descriptions true. - + - Should player stats be visible in spectator mode? + Which parent to use when attaching an equipped/useable item to the player. - + - Smoothing adds some initial blend-in which felt nicer for explosion rumble. + Helper for plugins that want item prefabs server-side. + e.g. Allows item icons to be captured on dedicated server. - + - Slightly clamped third-person version of "eyes" value to prevent sweep from hitting floor. + Item name wrapped in color rich text tags according to rarity. - + - Get point-of-view in world-space. + Hack for Kuwait aura icons. - + - Get point of view in worldspace without the left/right leaning modifier. + Useable subclass. - + - This is only used after capturing dual-render scope, not when exiting scope overlay. - Otherwise the lighting vision may have changed between entering and exiting the scope. + Can this useable be equipped by players? + True for most items, but allows modders to create sentry-only weapons. - + - Clamp _pitch within the [0, 180] range. + Can this useable be equipped while underwater? - + - Clamp yaw while seated, and keep within the [-360, 360] range. + Vertical half size of icon camera. + Values less than zero are disabled. - + - Can spectating be used without admin powers? - Plugins can enable spectator mode. + Vertical half size of economy icon camera. - + - Can workzone be used without admin powers? - Plugins can enable workzone permissions. + Should the newer automatic placement and orthographic size for axis-aligned icon cameras be used? + Enabled by default, but optionally disabled for manual adjustment. - + - Can spectator overlays be used without admin powers? - Plugins can enable specstats permissions. + Nelson 2025-04-10: adding this for semantics because amount isn't an obvious name. - + - Called from the server to allow spectating without admin powers. - Only used by plugins. + If true, item should be removed when "amount" reaches zero. + Defaults to true except for magazines. - + - Allow use of spectator mode without admin powers. - Only used by plugins. + Which parent to use when attaching an equipped/useable item to the player. + + + + + If true, equipable prefab is a child of the left hand rather than the right. + Defaults to false. - + - Called from the server to allow workzone without admin powers. - Only used by plugins. + Whether viewmodel should procedurally animate inertia of equipped item. + Useful for low-quality older animations, but modders may wish to disable for high-quality newer animations. - + - Allow use of workzone mode without admin powers. - Only used by plugins. + Defaults to true. If false, the equipped item model is flipped to counteract the flipped character. - + - Called from the server to allow spectator overlays without admin powers. - Only used by plugins. + If true, stats like damage, accuracy, health, etc. are automatically appended to the description. + Defaults to true. - + - Allow use of spectator overlay mode without admin powers. - Only used by plugins. + Nelson 2024-12-11: This can now be null for cosmetic items (). For those items it wasn't + used outside of the main menu 3D item preview, in which case the clothing prefab is typically a better + visualization. - + - Multiple hits are necessary because the first returned hit is not always the closest. + Optional alternative item prefab specifically for the PlayerEquipment prefab spawned. - + - Sweep a sphere to find collisions blocking the third-person camera. + Name to use when instantiating item prefab. + By default the asset legacy id is used, but it can be overridden because some + modders rely on the name for Unity's legacy animation component. For example + in Toothy Deerryte's case there were a lot of duplicate animations to work + around the id naming, simplified by overriding name. - Valid world-space camera position. - + - Replacement for enum origin. + Movement speed multiplier while the item is equipped in the hands. - + - Hardcoded built-in name, or name of workshop file if known. + Sound to play when inspecting the equipped item. - + - Steam file ID if loaded from the workshop, zero otherwise. + Sound to play when moving or rotating the item in the inventory. - + - If true, when added to asset mapping the new assets will override existing ones. - This ensures workshop files installed by servers take priority and disables warnings about overlapping IDs. + When a player dies with this item, should an item drop be spawned? - + - If true, we can re-save .dat/.asset files from this origin. - Defaults to false. Only true for assets in the game install folder. + Can player click the drop button on this item? - + - Can be added to any GameObject to receive text chat events. + If this item is compatible with skins for another item, lookup that item's ID instead. - + - Message can be in any chat channel. + Defaults to true. If false, skin material and mesh are not applied when is + set. For example, a custom axe can transfer the kill counter and ragdoll effect from a vanilla item's skin + without also transferring the material and mesh. - + - Message must be in Global channel. + Should friendly-mode sentry guns target a player who has this item equipped? - + - Message must be in Local channel. + Kept in case any plugins refer to it. + Renamed to shouldFriendlySentryTargetUser. - + - Filter to apply to message type. + Should players be allowed to start primary/secondary use of this item while inside given safezone? + If returns false the primary/secondary inputs are set to false. - + - Sphere radius (squared) around this transform to detect player messages. - e.g. 16 is 4 meters + Should this item be deleted when using and quality hits zero? + e.g. final melee hit shatters the weapon. - + - Substring to search for in message. + Should the game destroy all child colliders on the item when requested? + Physics items in the world and on character preview don't request destroy, + but items attached to the character do. Mods might be using colliders + in unexpected ways (e.g., riot shield) so they can disable this default. - + - Message must start with phrase text. + Are there any official skins for this item type? + Skips checking for base textures if item cannot have skins. - + - Message must contain phrase text. + Find useableType by useable name. - + - Message must end with phrase text. + V2 is for newer dat list features. - + - Filter to apply to message text. + Legacy is for backwards compatibility with Blueprint_# format. - + - Invoked when a player message passes the filters. + V2 is for newer dat list features. - + - Calculate angle in radians the player would need to offset their aim upward - to hit a target a certain distance away. + Legacy is for backwards compatibility with Action_# format. - + + sortOrder values for description lines. + Difference in value greater than 100 creates an empty line. + + - Separate from isEnabled to hide markers when they are outside the scope. + Properties common to Gun and Melee. - + - Used to sync hasLabel visibility. + Properties common to Barricade and Structure. - + - True while fading in or fully transitioned in. + Properties common to Gun, Consumable, and Throwable. - + - True while fading in, but not at full intensity. + Properties common to Gun and Melee. - + - True while finished fading in. + Properties common to Gun and Melee. - + - True while fading out, but not at zero intensity. + Properties common to Gun and Melee. - + - True while finished fading out. + Properties common to Gun and Melee. - + - True while fading in or out. + Server list filter for plugin usage. - - Matches handle returned by request, or -1 if cached. - - + - Read commands from standard input, and write logs to standard output. + Exposed for Rocket transition to modules backwards compatibility. - + - Each Update we consume a key press from the console buffer if available. - Unfortunately ReadLine is not an option without blocking output, so we maintain our own pending input. + List of all interactable items. Originally only used to clamp their distance from the drop point to ensure + clients can always pick them up, but now used to find items within a radius for nearby menu as well. - + - Entry in the MenuPlayServerBookmarksUI list. + Kept for plugin backwards compatibility. + This one is problematic because on the client physics can move items between regions. - + - Null token. + Find physically simulated items within radius. - + - Text between tags. + Despawn any old items in the current despawn region. + True if the region had items to search through. - + - [b] + Attempt to respawn an item in the current respawn region. + True if an item was succesfully respawned. - + - [/b] + Not ideal, but there was a problem because onLevelLoaded was not resetting these after disconnecting. - + - [i] + Instantiate at least this many items per frame even if we exceed our time budget. - + + -1 if table was not found. + + - [/i] + Fading in. - + - [list] + Finished fading in. - + - [/list] + Fading out. - + - [olist] + Finished fading out. - + - [/olist] + Can be added to certain entities to modify which crafting tags they make available to players. + At the time of writing (2025-04-08) the compatible entities are: + • Barricade + • Structure + • Vehicle + • Resource + • Object - + - [*] value - Nelson 2025-07-02: manually written lists typically don't have a ListItemClose token. + Each specified component modifies tags. - + - [/*] - Nelson 2025-07-02: Steam's new visual editor adds closing tokens to list items, but - manually-written list items typically don't have them. + TextMesh Pro uGUI text components. - + - [h1] + TextMesh Pro uGUI input field components. - + - [/h1] + Exposed for Rocket transition to modules backwards compatibility. - + - [h2] + This effect makes a nice clicky sound and lots of older code used it, + so I moved it into a little helper method here. - + + If true, client will download the image once and re-use it for subsequent calls. + If true, client will destroy any cached copy of the image and re-acquire it. + + - [/h2] + Notify server that a button was clicked in a clientside effect. - + - [h3] + Notify server that an input field text was committed. - + - [/h3] + If an effect with a given key exists, destroy it. - + - [url=value] + parent should only be set if that system also calls ClearAttachments, otherwise attachedEffects will leak memory. - + - [/url] + Helper for sending and spawning effects. + Newer and refactored code should use this method. - + - [img] + Objects registered so that they can be destroyed all at once if needed. + May be null if they were destroyed with a timer. - + - [/img] + Plugin UIs spawned by the server. - + - [previewyoutube=value] + Called prior to destroying effect (if attached) to free up attachments list. - + - [/previewyoutube] + Called after attaching effect so that it can be returned to pool when/if parent is destroyed. - + - '\n' or "\r\n" + Maps root transform to any attached effects. + This allows us to detach effects when returning a barricade/structure to their pool. - + - [quote=value] (value is author) + Recycled lists for attachedEffects dictionary. - + - [/quote] + Overrides breathability for example in a deep cave with no oxygen, or near a deep sea plant that provides oxygen. - + - [p] + Find highest alpha breathable volume overlapping position. - + - [/p] + Find highest alpha non-breathable volume overlapping position. - + - [u] + Enabled for effects held by guns and sentries. - + - [/u] + Listen for OnDestroy callback because mods may be destroying themselves in unexpected ways (e.g., Grenade + component) and still need to be cleaned up. - + - Steam's new visual editor quotes value in [url=x] tag. If value is not quoted, this method returns as-is. - If it IS quoted, this methods returns without quotation marks. + [0, 1] blends towards one while active regardless of local volume. - + - Breaks down Steam's version of BBcode into tokens like, "[b]", "[i]", "actual text", etc. + [0, 1] blends towards one if current volume bitwise AND with asset is non-zero. - + - If true, parse newlines in the input as LineBreak tokens. (default true) - If false, exclude LineBreak tokens from output. - Steam's new visual editor doesn't emit newlines, instead inferring line breaks from paragraph blocks. To - make life easier we will do the same for the main menu announcement feed. + Lesser of global or volume blend alphas. - + - Reset to -1 when not chatting. If player presses up/down we get index 0 (most recent). + If blending was not ticket yet then local blend can use global value, e.g. loading into rain storm. - + - Fill chat field with previous sent message. - Useful for repeating commands with minor changes. + Is blendAlpha at 100%? - + - Use the latest hotbar items in the UI. + [0, 1] Rain puddle alpha cutoff. - + - Icon uploaded to CDN. + [0, 1] Rain puddle ripples alpha. - + - Icon used in game menus. + For non-repeat weapons the "Use" audio clip is played once time reaches this point. - + - Project-relative asset importer version of + Material on Model_0, the low-speed actual blade. - + - Icon saved for community members in Extras folder. + Renderer on Model_1. - + - Has the small icon been captured yet? + Material on Model_1, the high-speed blurred outline. - + - Has the large icon been captured yet? + transform's localRotation when the vehicle was instantiated. - + - Moved icon code from MenuTitleUI to here. + Rigidbody component on the root game object. - + - These directories are excluded from source control and Steam depots so they might not exist yet. + If true, set sharedMaterial. If false, set material. - + - If updating this method please remember to update the support article: - https://support.smartlydressedgames.com/hc/en-us/articles/13452208765716 + Calculated speed of this track. Used by some wheels. - + - Does name contain rich text tags? - Some players were abusing rich text enabled servers by inserting admin colors into their steam name. + Temporary array for use with physics queries. - + - Used when damaging zombies to override in which situations they are stunned. + Temporary list for gathering materials. - + - Default stun behaviour determined by damage dealt. + Precursor to Net ID. Should eventually become obsolete. - + - Don't stun even if damage is over threshold. + Asset ID. Essentially obsolete at this point. - + - Stun regardless of damage. + Used to restore vehicle materials when changing skin. - + - Overrides hat item from zombie table with a specific item ID. + Only used by trains. Constrains the train to this path. - + - Overrides gear item from zombie table with a specific item ID. + Unfortunately old netcode sends train position as a Vector3 using the X channel, but new code only supports + [-4096, 4096) so we pack the train position into all three channels. Eventually this should be cleaned up. - + - If zombie is stuck this was a nearby barricade potentially blocking our path. + Nelson 2024-06-24: When first implementing batteries there was only the vanilla battery item, and it was + fine to delete it when the charge reached zero. This may not be desirable, however, so zero now represents + no battery item is present, and one represents the battery is completely drained but still there. - + - If zombie is stuck this was a nearby structure potentially blocking our path. + Is this vehicle inside a safezone? - + - If zombie is stuck this was a nearby vehicle potentially blocking our path. + Duration in seconds since this vehicle entered a safezone, + or -1 if it's not in a safezone. - + - If target player is passenger in a vehicle this is their vehicle. + Should askDamage requests currently be ignored because we are inside a safezone? - + - If zombie is stuck this was a nearby object potentially blocking our path. + Nelson 2024-06-24: This property is confusing, especially with isEnginePowered, but essentially represents + starting the engine ignition when a player enters the driver's seat. If true, there's a driver, there was + sufficient battery to start (or battery not required), and the engine wasn't underwater. - + - Incremented while stuck. Prevents doing overlap test too frequently. + Doesn't imply the vehicle *uses* batteries, only that it contains a battery item with some charge left. - + - Add or remove from ticking list if needed. - Separated from updateTicking in order to move once after first spawn. + Doesn't imply the vehicle *uses* batteries, only that it contains a (potentially uncharged) battery item. - + + + Nelson 2024-11-13: Adding this primarily to indicate whether a vehicle was spawned by the level versus + placed by a player or bought from a vendor. This way if the number of "naturally"-spawned vehicles is below + a certain threshold the level can spawn more. (e.g., a server where players have hoarded a bunch of + vendor-purchased vehicles and no default vehicles are left for new players.) + + Only available on the server. + Defaults to true for old saves to prevent suddenly spawning a bunch more vehicles. + + + - Boss zombies are considered mega as well. + Whether the player can shoot their equipped turret. - + - Yeah it seems kinda ugly to pollute all zombies with this code... zombie rewrite eventually please. + Do any of the passenger seats have a player? - + - If damage exceeds this value, stun the zombie. + When the server saves it doesn't include any cleared vehicles. - + - Used to kill night-only zombies at dawn. + If true, the vehicle will be destroyed at the end of the frame. Set before OnPreDestroyVehicle. + Used to reject requests to enter the vehicle on the same frame it's being destroyed. - + - Cache difficulty asset (if any) for this zombie's current type and bound. - Allows difficulty assets to override certain zombie behaviors. - Called after bound/type is initialized, and after type changes during respawn. + Magnitude of rigidbody velocity, replicated by current simulation owner. - + - Called when zombie does not have a target, but has been stuck for a period. + Rigidbody velocity along forward axis, replicated by current simulation owner. - + - Reduces frequency of UndergroundAllowlist checks because it can be expensive with lots of entities and volumes. + Replicated by current simulation owner. Target velocity used, e.g., for helicopter engine speed. - + - Helper to prevent mistakes or plugins from breaking alive zombie count. + [0, 1] If forward velocity is greater than zero, get normalized by target forward speed. If less than zero, + get normalized by target reverse speed. Result is always positive. - + - Helper to prevent mistakes or plugins from breaking alive boss zombie count. + Animated toward ReplicatedForwardVelocity. - + - 2023-01-31: set height to 2 rather than adjusting per-zombie-type. Tall zombies (megas) couldn't - get through doorways, and short zombies (crawlers) could get underneath objects they shouldn't - like gas tanks. Zombies were also stacking on top of eachother a bit too much. + Animated toward ReplicatedVelocityInput. - + - Very similar to . + [-1.0, 1.0] Available on both client and server. - + - Very similar to . + Animated towards replicated steering angle. Used for steering wheel and front steering column. + Non-simulating wheels (e.g., car driven by remote client) use this as steering angle multiplied by their + per-wheel . - True if sound played. - + - Exposed for Rocket transition to modules backwards compatibility. + Front steering column of bicycles and motorcycles. - + - Exposed for Rocket transition to modules backwards compatibility. + If true, server should replicate latest state to clients. - + - Ideally in a future rewrite asset overload will become the default rather than the overload taking legacy ID. + Used by several engine modes to represent an interpolated velocity target according to input. - + - If true, item has 100% quality. If false, item has a random quality. + Set from inputTargetVelocity then multiplied by any factors which shouldn't affect the player's "target" + speed ike boatTraction. - + - Get animal or player damage based on game mode config. + Vehicles with buoyancy interpolate this value according to whether it's in the water, and multiply + boat-related forces by it. - + - Get zombie or player damage based on game mode config. + Rigidbody on the Vehicle prefab. + (not called "rigidbody" because as of 2024-02-28 the deprecated "rigidbody" property still exists) - + - Allows Unity events to spawn barricades. + Primarily for backwards compatibility with plugins. Previously, multiple "updates" could be queued per + vehicle and sent to clients. This list was public, unfortunately, so plugins may rely on submitting vehicle + updates. After making it obsolete each vehicle can only be flagged as needing a replication update, and + this is reset after each server replication update. - + - Distance along tree's local up axis to offset debris spawn position. Defaults to 1.0. + Is player currently allowed to repair this vehicle? - + - Before had randomization properties (which trees don't currently use - as of 2024-12-11 because rotation/scale aren't saved) each tree has some random rotation and scale variation - based on its position. This property controls the rotation away from upright. + Give battery item to player and set battery charge to zero. - + - Amount of experience to reward foraging player. + Nelson 2024-06-24: Previously, this wouldn't give an item to the player if the quality was zero. Now it + trusts the caller to validate we have a battery item to give, and respects . - + - Forageable resource message. + Can a tire item be used with this vehicle? - + - Weapon must have matching blade ID to damage tree. - Both weapons and trees default to zero so they can be damaged by default. + Find the index of the wheel collider that contains this position. - + - If true, prevent collisions between falling tree and the stump. (i.e., debris can fall through stump) - Defaults to true. + Find the index of the wheel collider closest to this position, or -1 if not near any. - + - Only activated during this holiday. + Called during simulate at fixed rate. - + - Tree to use during the Christmas event instead. + Is a given player allowed access to this vehicle? - + - Tree to use during the Halloween event instead. + If true, sentry ignores this vehicle early in target scanning. + Friendly if locked by owner/group of sentry, or driven by owner/group of sentry. - + - Get asset ref to replace this one for holiday, or null if it should not be redirected. + Average vehicle-space position of wheel bases. - + - Essentially deprecated for now. + Turn taillights on/off depending on state. - + - Server response to a non-rejected CONNECT request. Notifies client they are in the queue. + Returns null if index is out of bounds or initialization has failed. - + - Rather than creating all SleekItems as once we create a few per frame. + Returns null if index is out of bounds, initialization failed, or seat is empty. - + - Reset all items hotkey label. + This check should really not be necessary, but somehow it is a recurring issue that servers get slowed down + by something going wrong and the vehicle exploding a billion times leaving items everywhere. - + - Kept because lots of modders have been using this script in Unity, - so removing legacy effect id would break their content. + VehicleManager expects this to only find the seat, not add the player, + because it does a LoS check. - + - Find an item to apply stat tracker tool to. + Call on the server to empty the vehicle of passengers. - + - Find an item with a stat tracker to remove. + Kicks them out even if there isn't a good spot. Used when killing the occupant. + True if player is seated, false otherwise. - + + + Can a safe exit point currently be found? + + Called when considering to add a new passenger to prevent players from entering + a vehicle that they wouldn't be able to exit properly. + + + - Find an item with a ragdoll effect to remove. + Could a player capsule fit in a given exit position? - + + True if anything was hit. + + - Find an item to apply ragdoll effect tool to. + Raycast along a given direction, penetrating through barricades attached to THIS vehicle. + Returns point at the end of the ray if unblocked, or a safe (radius) distance away from hit. - + + + Fallback if there are absolutely no good exit points. + Sets point and angle with a normal player spawnpoint. + + Once vehicle is completely surrounded there is no nice way to pick an exit point. Finding + a point upwards is abused to teleport upward into bases, finding an empty capsule nearby is + abused to teleport through walls, so if we're sure there isn't a nice exit point we can + fallback to teleporting them to a safe spawnpoint. + + + + True if we can safely exit. + + - Toggle button to open/close advanced filters panel. + Initially use tryGetExit to find a safe exit, but if one isn't available then fallback to getExitSpawnPoint. - + - On/off checkbox for including description text in filter. + Dedicated server simulate driving input. - + - Switch between sort modes. + -1 is reverse. + 0 is neutral. + +1 is index 0 in gear ratios list. - + - On/off checkbox to reverse sort results. + Engine RPM replicated by current simulation owner. - + - On/off checkbox to show only equipped items. + Animated toward ReplicatedEngineRpm. - + - Container for advanced options. + Called when engine RPM exceeds threshold and there are more gears available. + Purpose is to skip gear numbers that don't bring engine RPM within threshold (if possible). - + - Whether to include description text in filter. + Called when engine RPM is below threshold and there are more lower gears available. + Purpose is to skip gear numbers that don't bring engine RPM within threshold (if possible). - + - How to sort filtered items. + Client simulate driving input. - + - Should sorted list be reversed? + Nelson 2025-05-05: ran into a bug where our manual OnUpdate is called before Unity calls Start! - + - Should only equipped items be shown? + Nelson 2025-05-02: keeping the previous comment from 2020-11-26 here. At first I wondered if 24 vehicles + wasn't enough to properly test, but even with a higher vehicle count it can seemingly be *slower* to + call Update manually. That said, calling Update manually does give us the option to time-slice vehicle + updates. On the client and singleplayer we now update vehicles outside render distance at a lower + frequency which saves ~0.1 ms per frame on my PC. + + 2020-11-26 experimented with dispatching all vehicle updates from C# in VehicleManager because they make up + a significant portion of the MonoBehaviour Update, but the savings on my PC with 24 vehicles on PEI was + minor. Not worth the potential troubles. - + - Remove items that do not match search text. + Nelson 2025-04-22: it hopefully goes without saying the bicycle pedals are janky as heck, I'm just separating + out the Update method to make profiling it easier. - + - Removed items that are not equipped. + Nelson 2025-04-22: this should ideally be moved into FixedUpdate, incorrect to run in Update. - + - All main menu MTX shop code should be routed through here so that it could theoretically be ported to other - platforms or stores. Obviously this is all very Steam specific at the moment, but at least the UI does not - depend on Steam API here as much as older parts of the game. + Nelson 2025-04-22: this should ideally be moved into FixedUpdate, incorrect to run in Update. - + - Was this item marked as new in the config? - If new, and not marked as seen, then a "NEW" label is shown on the listing. + Update whether this vehicle is inside a safezone. + If a certain option is enabled, unlock after time threshold is passed. - + - Do we have pricing details for a given item? - Price results may not have been returned yet, or item might not be public. + Can be called without calling init. - + - Messy, but we only show a menu alert if there was a problem. + Called after initializing vehicle. - + - Already filtered to only return locally known items which pass country restrictions. + Makes the collision detection system ignore all collisions between this vehicle and the given colliders. + Used to prevent vehicle from colliding with attached items. - + - Empty if outside new time window. + Used to disable collision between skycrane and held vehicle. - + - Subset of listings. + Transform used for exit physics queries. - + - Subset of listings. + Find collider with the largest volume to use for exit physics queries. - + - Subset of listings. + Set material on DepthMask child renderer responsible for hiding water when interior of vehicle is submerged. - + - Subset of listings. + Skin material does not always need to be destroyed, so this is only valid if it should be destroyed. - + - Subset of listings. + Materials that should be destroyed when this vehicle is destroyed. - + - May be out of date by one frame. + Handles to unregister from DynamicWaterTransparentSort. - + - Currently used by vehicles to deactivate some rendering features when outside rendering distance. - Uses "frozen" position if applicable, otherwise the camera position from the most recent Update. This means - it could be out-of-date, but for LOD purposes it should be "good enough." + Materials to set _PaintColor on. - + - Reset prior to joining a new server. + Materials to move UVs in sync with wheels. - + - By default if the client submits an asset guid which the server cannot find an asset for the client will - be kicked. This is necessary to prevent cheaters from spamming huge numbers of random guids. In certain cases - like a terrain material missing the server knows the client will be missing it as well, and can register - it here to prevent the client from being kicked unnecessarily. + Time.time decayTimer was last updated. - + - Send asset hash (or lack thereof) to server. - - IMPORTANT: should only be called in cases where the server has verified the asset exists by loading it, - otherwise only if the asset exists on the client. This is because the server kicks if the asset does not - exist in order to prevent hacked clients from spamming requests. Context parameter is intended to help - narrow down cases where this rule is being broken. + Seconds since vehicle was interacted with. - + - Send asset hash to server. - Used in cases where server does not verify asset exists. (see other method's comment) + Fractional damage counter. - + - Called each Update on the client. + transform.position used to test whether vehicle is moving. - + - Called from the server to override salvage duration. - Only used by plugins. + Should be called AFTER replication (if applicable) so that events can call methods relying on replication. - + - Override salvage duration without admin. - Only used by plugins. + If true, the player can press Interact [F] when there are no responses + and the "next" dialogue will be opened. - + - Outlined object is not necessarily the focused object, so we track it to disable later if focus is destroyed. + Each dialogue message is separated into multiple pages. - + - Search up hierarchy for most specific Target transform. + Current page localized text with name_npc and name_char formatted in. - + - Was focus non-null during last update? Used to detect when focus was destroyed. + Seconds elapsed while viewing current page not including pause timer. + Used to gradually show the message text. - + - Currently used by plugins to identify what damaged a buildable. + Seconds to wait before resuming pageAnimationTime counting. - + - Explosion instigated by . + Appends chars from pageFormattedText according to pageAnimationTime. - + - Should only be used by . - For example: "Condition_##" where ## is an index. + Rich text formatting tags to close those opened by visible text in animatedTextBuilder. + For example, if animatedTextBuilder includes an opening color=#, this includes the closing color markup. + Required depending on Glazier used. - + - If >0 the game will start a coroutine to grant the reward after waiting. + Number of chars of pageFormattedText currently visible. - + - If true and player has this reward pending when they die or disconnect it will be granted. + Added to animation visible chars to skip time on markup. - + - Intended to replace filling data from constructor. + Seconds elapsed since responses started becoming visible. + Used to gradually enable responses rather than all at once. - + - Intended to replace filling data from constructor. Legacy is for backwards compatibility with Reward_#_Key - format, whereas V2 uses the list and dictionary features. + Animated toward total number of responses to make them gradually visible. - + - Used in a test scene to quickly test UI Toolkit implementation. + If true, animation is finished and there is another page to show when Interact [F] is pressed. - + - Assigned when a named preset is created. - 0 is the default and should be replaced by a preset when loaded. - -1 indicates the preset was modified. - -2 and below are the default presets. + If true, text on current page is in the process of gradually appearing. - + - Nelson 2024-09-20: Changing default to any (from has players) because the default server list sort will now - push empty servers to the bottom. + Used by quest UI to return to current dialogue. - + - If true, only servers with available player slots are shown. - Nelson 2024-09-20: Changing default to false because the default server list sort will now push them down - from the top a little bit. + Update timers and UI for current page index. - + - If >0, servers with ping higher than this will not be shown. + Called when the player presses Interact [F] in dialogue screen. - - True if level was added to the list of maps. - - + - Version before named version constants were introduced. (2023-11-13) + Show complete text for the current page and make responses visible. + Called if dialogue animation is disabled, and when the player presses Interact [F] during animation. - + - % Full + The main reason for this silliness is older versions didn't have a layered clothing shader, rather they + pre-baked shirt/pant texture combinations according to the level's zombie configurations. - + - Note: this can be different from status.blueprint after status refreshes because status is pooled. + Not originally supported by networking. Added temporarily during netpak rewrite because the quaternion + compression is so much better for vehicles than three byte Euler rotation. - + - Update the title box describing the "most important" item: item to repair, salvage, craft, etc. + Factor e.g. 2 is a 2x multiplier. + Prior to 2022-04-11 this was the target field of view. (90/fov) - + - The dialogue to go to when a message has no available responses. - If this is not specified the previous dialogue is used as a default. + Responsible for loading asset definitions on a separate thread. - + - For level objects with QuestCondition called when quests are added or removed. + Parser error messages, if any. - + - Event specifically for plugins to listen to global quest progress. + Warning: on worker thread this only acts as handle. Do not access. - + - Event for plugins when group or rank changes. + Used on main thread to determine when all queued tasks have finished. - + - Overrides label text next to marker on map. - Used by plugins. Not saved to disk. + Loop searching directories recursively for asset bundle and asset definition files. - + - Kept serverside. Used to check whether the player is currently in their Steam group or just a normal in-game group. + Warning: on worker thread this only acts as handle. Do not access. - + - Check before allowing changes to this player's + Tooltip text. - + - Can rename the group. + Holds tooltip text - + - Can promote and demote members. + Standard shader mode changes are based on built-in StandardShaderGUI.cs - + - If set, default spawn logic will check for a location node or spawnpoint node matching name. - Saved and loaded between sessions. + Does shader name match any of the standard shaders? + Standard, StandardSpecular and the Unturned "Decalable" variants all share nearly identical parameters. - + - If true, hide viewmodel and prevent using equipped item. For example, to prevent shooting gun on top of a - first-person scene. This could be expanded in the future with other flags and options. + Based on fixup routine in StandardShaderGUI SetMaterialKeywords. - + - Called serverside to set marker on clients. + Conditionally fixup older standard materials. + True if material was edited. - + - Ask server to set marker. + Multiplier for the maximum distance the gunshot can be heard. - + - Call serverside to replicate new rank to clients + Labels for named locations. - + - Set player's group to their Steam group (if any) without testing restrictions. + Contains arena outer circle and inner target points. - - Ignores group changing rules when true. + + + Player avatars. + - + - Serverside send packet telling player about this invite + Arrow oriented with the local player. - + - Called on server to finalize and remove quest. + Convert level-space 3D position into normalized 2D position. - + - Called by quest details UI to request server to abandon quest. + Convert normalized 2D position into level-space 3D position. - + - Called when there are no responses to choose, but server has indicated a next dialogue is available. + Temporary to unbind events because this class is static for now. (sigh) - + - Called in singleplayer and on the server after client requests NPC dialogue. + Do not override zombie health. - + - Prevent re-creating it during destroy (e.g. plugin granting rewards) from leaking gameobject. + Per-speciality value is a multiplier for health configured in the level editor. - + - White 1x1 texture for solid colored images. - uGUI empty image draws like this, but we need the texture for IMGUI backwards compatibility. + Per-speciality value is a multiplier for vanilla health value. - + - Is the server this widget represents currently favorited? - Can be false on the favorites list. + Per-speciality value replaces zombie's health. - + - Payload for the DamageTool.damagePlayer function. + Can horde beacons be placed in the associated bounds? - + - Should armor worn on matching limb be factored in? + Can be null if not assigned. - + - Should game mode config damage multiplier be factored in? + Vendor asset that owns this buy/sell record. - + - If player dies should it count towards quests? + If not null, replaces item/vehicle description. - + - Effect to apply to ragdoll if dead. + Used in a test scene to quickly test UI Toolkit implementation. - + - Read 8-bit per channel color excluding alpha. + Is the application running as a headless server? + Replacement for isDedicated property. The property could not be changed to const in dedicated-server-only + builds without potentially breaking plugins. Only development builds can be run as both client or server. - + - Intended as a drop-in replacement for existing assets with property uint16s. + Are we currently running the standalone dedicated server app? - + - Is a point safely within the level bounds? - Also checks player clip volumes if legacy borders are disabled. + Should dedicated server disable requests to internet? + While in LAN mode skips the Steam backend connection and workshop item queries. + Needs a non-Steam networking implementation before it will be truly offline only. - + - Is given Y (vertical) coordinate within level's height range? - Maps using landscapes have a larger range than older maps. + Icon uploaded to CDN. - + - Notify menus that levels list has changed. - Used when creating/deleting levels, as well as following workshop changes. + Icon used in game menus. - + - Get level's cached asset, if any. + Project-relative asset importer version of - + - Should loading code proceed with redirects? - Disabled by level and when in the editor. + Icon saved for community members in Extras folder. - + - Placeholder created between unloading the main menu and loading into game or editor. + Has the small icon been captured yet? - + - Loading screen music. + Has the large icon been captured yet? - + - Clip to play to fade out loop. + Moved icon code from MenuTitleUI to here. - + - Useful to narrow down why a player is getting kicked for modified level files when joining a server. + These directories are excluded from source control and Steam depots so they might not exist yet. - + - Display version string of the currently loaded level. + Code common to and . - + - Version string of the currently loaded level packed into an integer. + Work-in-progress plan to allow modders to create custom physics effects. - + - Refreshes known levels and attempts to redirect level reference if it no longer exists. + Can crops be planted on a given material? - + - Find level matching both name AND workshop file ID (can be zero). + Can oil drills be placed on a given material? - + - Load level details from Level.dat in directory path. + Optional component on Turret_# GameObject for modding UnityEvents. - + - Server list allows player to enter a map name when searching, so we try to find a local - copy of the level for version number comparison. (Server map version might differ.) + Optional collider matching the player capsule to prevent short vehicles (e.g. bikes) from clipping into walls. - + - New map filter uses lowercase map name and doesn't need startswith. + Invoked prior to built-in death logic. - + - Search all map folders to add any previously unregistered maps. + Event for plugins when player dies. - + - Temporary to unbind events because this class is static for now. (sigh) + Invoked after player finishes respawning. - + - Defines how instance methods handle invocation when the target instance does not exist yet, for example - if the target instance is async loading or has time sliced instantiation. + Tracks this player as an aggressor if they were recently an aggressor or if they haven't been attacked recently. + Ignores rules and just make aggressive. + Whether to call markAggressive on group members. - + + Should damage be dealt even while inside safezone? + + - Invocation should be ignored if the target instance does not exist. - This is the only applicable defer mode for static methods and server methods. + Set bleeding state and replicate to owner if changed. - + - Invocation will be queued up if the target instance does not exist. - Originally an "Overwrite" mode was considered for cases like SetHealth where only the newest value is - displayed, but this was potentially error-prone if multiple queued methods depended on values from each other. + Set legs broken state and replicate to owner if changed. - + - Allows Unity events to execute commands from the server. - Messenger context is logged to help track down abusive assets. + Add to or subtract from stamina level. + Does not replicate the change. - + - Responsible for loading asset definitions on a separate thread. + Add to or subtract from stamina level. + Does not replicate the change. - + - Parser error messages, if any. + Called from the server to modify stamina. - + - Warning: on worker thread this only acts as handle. Do not access. + Add to or subtract from stamina level on the client and server. - + - Used on main thread to determine when all queued tasks have finished. + Called from the server to induce a hallucination. - + - Loop searching directories recursively for asset bundle and asset definition files. + Add to or subtract from hallucination level on the client. - + - Warning: on worker thread this only acts as handle. Do not access. + Add to or subtract from warmth level. + Does not replicate the change. - + - Absolute path to *.log file. + Called from the server to modify warmth. - + - Responsible for the per-process .log file in the Logs directory. - Kept multiple log files in the past, but now consolidates all information - into a single file named Client.log or Server_{Identifier}.log. + Add to or subtract from warmth level on the client and server. - + - Should setup of the default *.log file be disabled? + Add to or subtract from oxygen level. + Does not replicate the change. - + - If true, information like IP addresses and login tokens should be censored in vanilla logs. - Nelson 2024-11-11: Special thanks to Jdance and asineth0 in public issue #4740! + Add to or subtract from health level. + Replicates change to owner. - + - Text to replace with if is enabled. + Add to or subtract from food level. + Replicates change to owner. - + - *ATTEMPTS* to replace IPv4 address(es) with . - Should only be called if is enabled. - Case-by-case redaction should be preferred for performance reasons over using this function. This function - is intended for third-party messages (e.g., BattlEye) that we don't have control over. + Add to or subtract from water level. + Replicates change to owner. - True if message was modified. - + - Get logging to path. + Add to or subtract from virus level. + Replicates change to owner. - + - Set path to log to. + Used by plugins to respawn the player bypassing timers. Issue #2701 - + - Close current log file. + Very similar to VehicleManager.sendExitVehicle. Please refer to that for comments. - + - Invoked when door is opened/closed, but not when loaded. + Used to refill all client stats like stamina - + - Switches between "legacy" (per-level road textures bundle) and "assets" (using RoadAsset). + Used by UI. True when underwater or inside non-breathable oxygen volume. - + - If modifying usage please update support article: - https://support.smartlydressedgames.com/hc/en-us/articles/13452208765716 + Rewards to grant when quest is removed without completing. + Not granted when player finishes quest. - + - If modifying usage please update support article: - https://support.smartlydressedgames.com/hc/en-us/articles/13452208765716 + Index of the context parameter, if not None. - + - Client has a critical module the server doesn't. + Reflected attribute that was used to find this method. + Contains extra information about how to call it. - + - Server has a critical module the client doesn't. + Backwards-Compatible Asset Reference with Caching + • Supports both GUID and legacy ID. + • Caches resolved asset and updates if asset has been reloaded. + • Parsing legacy ID without context requires "LegacyType:LegacyID" format. E.g., "Item:4" for the Eaglefire. + • See CachingAssetRef if legacy ID support is unnecessary. - + - Level config's version number does not match. + If true, doesn't reference anything. + Could also be called "IsZero" or "IsNull". - + - EconInfo.json hash does not match. + Opposite of IsEmpty. - + - Master bundle hashes do not match. + Assigned GUID, not the referenced asset's GUID. - + - Server has not received an auth session response from Steam yet. + Assigned legacy ID, not the referenced asset's legacy ID. - + - Server has not received an economy response from Steam yet. + Assigned legacy type, not the referenced asset's legacy type. - + - Server has not received a groups response from Steam yet. + Doesn't only check (Get() == asset) because a new asset may have loaded. + Rather, checks whether GUID or legacy ID (whichever is set) points at asset. + If asset is null, returns true if GUID and legacy ID are zero. - + - Player nickname exceeds limit. + Supports both GUID and legacy ID formats. + - If input string contains ':' the first part is EAssetType and the second part is legacy ID. + - If defaultLegacyType is not None the input string can be parsed as a legacy ID. + - Otherwise, parsed as GUID. - + - Player nickname contains invalid characters. - - If modifying usage please update support article: - https://support.smartlydressedgames.com/hc/en-us/articles/13452208765716 + Supports both GUID and legacy ID formats. + - If input string contains ':' the first part is EAssetType and the second part is legacy ID. + - Otherwise, parsed as GUID. - + - Player nickname should not be a number. + Returns Empty if TryParse returns false. - + - Player resources folders don't match. + Returns Empty if TryParse returns false. - + - The network identity in the ticket does not match the server authenticating the ticket. - This can happen if server's Steam ID has changed from what the client thinks it is. - For example, joining a stale entry in the server list. (public issue #4101) + Enables assigning assetRef from an existing asset without manually calling constructor. - + - Player's skin color is too similar to one of . + Enables assigning assetRef from an asset GUID without manually calling constructor. - + - Steam ID reported by net transport doesn't match client's reported Steam ID. - This was exploited to fill the server queue with fake players. + Enables assigning assetRef from a non-backwards-compatible asset ref without manually calling constructor. - + - Received too many connection requests from player in a short window. + Original width field is misleadingly named. It represents half the width of the flat section of the road. - + - Received too many invalid messages from connection in a short window. + Original depth field is misleadingly named. It represents half the "up" size of the road. - + - Server limits how many clients are joining from the same IP address. - (public issue #5001) + Distance along the terrain surface normal to move each road vertex. - + - Zero is treated as unset. + Base class for uGUI implementations of primitive building block widgets. - + - Returned asset is not necessarily a vehicle asset yet: It can also be a VehicleRedirectorAsset which the - vehicle spawner requires to properly set paint color. + Called after constructor when not populating from component pool. - + - Kept because lots of modders have been using this script in Unity, - so removing legacy effect id would break their content. + Called after constructor when re-using components from pool. - + - Matches level with same file name AND workshop file ID. + Synchronize uGUI component colors with background/text/image etc. colors. + Called when custom UI colors are changed, and after constructor. - + - Version before named version constants were introduced. (2023-11-08) + Synchronize uGUI component sprites with theme sprites. + Called when custom UI theme is changed, and after constructor. - + + False if element couldn't be released into pool and should be destroyed. + + - Moved into ServerListFilters. + Unity recommends enabling components after parenting into the destination hierarchy. - + - Exposed for plugins. Can be null. Please do not modify. + RectTransform children should be attached to. Overridden by ScrollView content panel. - + - This overload supports legacy Condition_# format. + This helper property's purpose is to: + - Ensure other properties don't accidentally remove LayoutElement if others need it. + - Ensure LayoutElement is destroyed before returning to pool. - + - This overload doesn't support legacy Condition_# format. + Whether the pointer is currently in a spot that can be painted. - + - If true, button tooltip will be overridden with tooltip from states array. + Get brush strength multiplier where strength decreases past falloff. Use this method so that different falloffs e.g. linear, curved can be added. + Percentage of . - + - If true oxygen is restored while in this volume, otherwise if false oxygen is depleted. + Find materials in finished ragdoll and replace them with the appropriate effect. - + - Merges textures used in the level into an atlas to assist runtime draw call batching. + Base class for IMGUI implementations of primitive building block widgets. - + - Skip renderer children of these transforms, if any. - For example we skip lights with material instances and rubble debris. + Position passed into the GUI draw methods. - + - Most objects in Unturned use the standard shader without transparency/emissive/detail/etc. + Added to player's food value. - + - Meshes we logged an explanation for as to why they can't be atlased. + Added to player's water value. - + - Textures we logged an explanation for as to why they can't be atlased. + Added to player's virus value. - + - Materials we logged an explanation for as to why they can't be atlased. + Added to player's hallucination value. - + - Objects instantiated for the lifetime of the level that should be destroyed when exiting the level. + Get animal or player damage based on game mode config. - + - If true, don't assign texture atlas to material so batched materials are obvious. + Get zombie or player damage based on game mode config. - + - If true, assign a red material to excluded meshes so they are obvious. + Should player/animal/zombie surface be nulled on hit? + Requested by spyjack for a chainsaw-style shield that was overboard with the blood. - + - If true, replace each unique material with a colored one before static batching. + Should this weapon bypass the DamageTool.allowedToDamagePlayer test? + Used by weapons that heal players in PvE. - + - If true, log why texture/material can't be included in atlas. + Please refer to ItemWeaponAsset.BuildDescription for an explanation of why this is necessary. - + - If true, log if mesh has UVs outside [0, 1] range. + Please refer to ItemWeaponAsset.BuildDescription for an explanation of why this is necessary. - + - We generate a 1x1 texture for materials without one. + Update currency and owned items if inventory has changed and menu is open. - + - Tracks which mesh filters and skinned mesh renderers were referencing a given mesh. + Update currency or experience depending what the vendor accepts. - + - Tracks which meshes and materials were referencing a given texture. + Allows Unity events to broadcast text chat messages from the server. - + - If true, UVs should be centered and overridden because original mesh was not textured. + Text to use when SendDefaultTextChatMessage is invoked. - + - Maps original mesh to any mesh filters using it. - When mesh's UVs are modified the mesh filters need to be pointed at the copied mesh. + URL of a png or jpg image file to show next to the message. - + - Renderers with a material using the texture. - After combining texture the renderers need to be pointed at the combined material. + Text color when rich text does not override with color tags. - + - Tracks which textures were referencing a given shader. + Should rich text tags be parsed? + e.g. bold, italic, color - + - StaticBatchingUtility.Combine requires input renderers are enabled and active in hierarchy, - so we temporarily activate/enable them to keep this logic out of LevelObject/ResourceSpawnpoint. + Entry in the MenuPlayServerCurationRulesUI list. - + - Payload for the DamageTool.damageAnimal function. + In vanilla this field is ONLY used for the per-character saves on servers. + If that changes check that it does not affect the savedata options. - + - Should game mode config damage multiplier be factored in? + 20-byte SHA1 salted hashes of client's hardware ID(s). + Providing multiple HWIDs makes it more difficult to bypass HWID bans because spoofing a single component + only changes one of the bans. For example spoofing the MAC address will not spoof the Windows GUID. + + Randomized if system did not support hwid, or perhaps player is cheating. + Should not be called on the client side, but just in case there is a default zeroed array. - + - If not null and damage is applied, is called with this position. + Ignore requests to kick me in debug mode. :) + Steam ID may not have been authenticated yet here which may seem like a security risk, but fortunately that + would get caught when Steam auth ticket response is received. - + - Can be added to EquipablePrefab item GameObject to receive events. + Array of 20-byte SHA1 hashes. - + - Invoked when item begins inspect animation. + Read 8-bit per channel color excluding alpha. - + - Entry in the MenuPlayServerCurationUI list. + Intended as a drop-in replacement for existing assets with property uint16s. - + - In-game rich text does not support embedded YouTube videos, but they look great in the web browser, - so we simply remove them from the in-game text. + By default, clickable only responds to LeftMouse without the Control modifier. + Unturned (currently) filters left/right mouse and modifiers outside Glazier, + so add activators for left/right and control modifier to all clickables. - + - Unfortunately in-game rich text does not have code formatting yet, so remove the tags while preserving text. + USS best practices mentions inline styles have a higher memory overhead, so we + only apply an inline value if it doesn't match the default :root font style. - + - Nelson 2025-01-28: This command reproduces a bug destroying the player gameObject if the vehicle is - destroyed on the same frame as the request to enter. - https://github.com/SmartlyDressedGames/Unturned-3.x-Community/issues/4760#issuecomment-2613090165 + USS best practices mentions inline styles have a higher memory overhead, so we + only apply an inline value if it doesn't match the default :root text alignment. - + - Not using rate limit attribute because this is potentially called for hundreds of barricades at once, - and only admins will actually be allowed to apply the transform. + Can be added to EquipablePrefab item GameObject to receive events. - + - Only used by plugins. + Invoked when item begins inspect animation. - + - See BarricadeRegion.FindBarricadeByRootFast comment. + Has player dismissed the given workshop item? - + - For code which does not know whether transform exists and/or even is a barricade. - See BarricadeRegion.FindBarricadeByRootFast comment. + Track that the player has dismissed the given workshop item. - + - Does this label fade out as the chat message gets older? + Has player already auto-subscribed to the given workshop item? - + - Chat message values to show. + Track that the player has auto-subscribed to the given workshop item. - + - Tree activation is time-sliced, so this does not necessarily match whether the region is active. + If true, vest and backpack spawn System_Area instead of System_Hook. - + - Can this tree be damaged? - Allows holiday restrictions to be taken into account. (Otherwise holiday trees could be destroyed out of season.) + Determines how NPCFlagMathReward handles formatReward. - + - Some new code common to SteamPending and SteamPlayer. + Use text as-is without formatting. For backwards compatibility. - + - Realtime the first ping request was received. + Format flag A value into {0} and flag B value (or default) into {1}. - + - Number of ping requests the server has received from this client. + Parses mb:X from input string and filters assets using X master bundle. - + - Called when a ping request is received from this client. + This is a bit of a hack in order to simplify the foliage menu when most of the time editors are either + manually placing foliage or automatically baking it. - + - Realtime passed since the first ping request was received from this client. + Get brush strength multiplier where strength decreases past falloff. Use this method so that different falloffs e.g. linear, curved can be added. + Percentage of . - + - Average number of ping requests received from this client per second. - Begins tracking 10 seconds after the first ping request was received, or -1 if average is unknown yet. + Can be added to Vehicle Turret_# GameObject to receive events. - + - Only set on server. Associates player with their connection. + Invoked when turret gun is fired. - + - Used when kicking player in queue to log what backend system might be failing. + Invoked when turret gun begins reload sequence. - + - Number of alive zombies. + Invoked when turret gun begins hammer sequence. - + - Last time a quest boss was spawned. + Invoked when turret gun begins aiming. - + - Allow another quest to spawn a boss zombie immediately. + Invoked when turret gun ends aiming. - + - Kills the boss zombie if nobody is around, if the boss was killed it calls UpdateBoss. + Invoked when turret gun controlled by a local player begins aiming. - + - Checks for players in the area with quests and spawns boss zombies accordingly. + Invoked when turret gun controlled by a local player ends aiming. - + - HUD with projected labels for teammates. + Invoked when turret gun controlled by a local player begins inspecting attachments. - + - Allows map makers to create custom weather events. + Invoked when turret gun controlled by a local player ends inspecting attachments. - + - Does this weather affect fog color and density? + Invoked when any player enters the seat. - + - Does this weather affect sky fog color? + Invoked when any player exits the seat. - + - Does this weather affect cloud colors? + Invoked when a locally controlled player enters the seat. - + - Directional light shadow strength multiplier. + Invoked when a locally controlled player exits the seat. - + - Exponent applied to effect blend alpha. + Note: if calling ItemRef.Get() please use FindItemAsset instead to avoid redundant asset lookups. - + - Exponent applied to effect blend alpha. + Does this blueprint output create the specified item? - + - SpeedTree wind strength for blizzard. Should be removed? + Reset prior to joining a new server. - + - If specified level editor color can be used rather than a per-asset color. + By default if the client submits an asset guid which the server cannot find an asset for the client will + be kicked. This is necessary to prevent cheaters from spamming huge numbers of random guids. In certain cases + like a terrain material missing the server knows the client will be missing it as well, and can register + it here to prevent the client from being kicked unnecessarily. - + - Remove any existing item alert widgets. + Send asset hash (or lack thereof) to server. + + IMPORTANT: should only be called in cases where the server has verified the asset exists by loading it, + otherwise only if the asset exists on the client. This is because the server kicks if the asset does not + exist in order to prevent hacked clients from spamming requests. Context parameter is intended to help + narrow down cases where this rule is being broken. - + - Open fullscreen alert showcasing newly granted items. - Uses first item for title color, so items should be sorted by priority. + Send asset hash to server. + Used in cases where server does not verify asset exists. (see other method's comment) - + - Open fullscreen alert showcasing newly granted items. + Called each Update on the client. - + - Handle esc/back key press. - Still really messy, but this used to be inside a huge nested if/elseif in Update. + Called on the client after a new message is inserted to the front of the list. - + - Despite being newer code, this is obviously not ideal. Previously the news request was using the Steam HTTP - API which might have been the cause of some crashes, so it was quickly converted to Unity web request instead. + Called on the server when preparing a message to be sent to a player. + Allows controlling how %SPEAKER% is formatted for the receiving player. - + - Invoked when web item is first loaded or reloaded. + Called on the server when formatting a player's message before sending to anyone. + Allows structuring the message and where the player's name is, for example: '[CustomPluginRoleThing] %SPEAKER% - OriginalMessageText' - + - If false this structure cannot take damage. + Exposed for Rocket transition to modules backwards compatibility. - + - Modded structures can disable pooling if they have custom incompatible logic. + Add a newly received chat message to the front of the list, + and remove an old message if necessary. - + - Length of raycast downward from pivot to check floor is above terrain. - Vanilla floors can be placed a maximum of 10 meters above terrain. + Previous messages sent to server from this client. + Newest at the front, oldest at the back. Used to repeat chat commands. - + - Optional alternative structure prefab specifically for the client preview spawned. + Send a request to chat from the client to the server. - + - Called on the dedicated server to optimize client prefab for server usage. + Allows Unity events to send text chat messages from the client, for example to execute commands. + Messenger context is logged to help track down assets using it in inappropriate ways. - + - Compares weather intensity to value. + Allows Unity events to broadcast text chat messages from the server. + Messenger context is logged to help track down assets using it in inappropriate ways. - + - Called during startup and when returning to the main menu. + Server send message to specific player. + Used in vanilla for the welcome message. + Should not be removed because plugins may depend on it. - + - Result is never null, but may be empty or out-of-date. + Server send message to specific player. + Used in vanilla by help command to tell player about command options. + Should not be removed because plugins may depend on it. - + - Can be added to Vehicle GameObject to receive events. + Server send message to all players. + Used in vanilla by some alerts and broadcast command. + Should not be removed because plugins may depend on it. - + - Invoked when any player enters the driver seat. + Serverside send a chat message to all players, or a specific player. + Contents to display. + Default text color unless rich formatting overrides it. + Player who sent the message (used for avatar), or null if send by a plugin. + Send message to only this player, or all players if null. + Mostly deprecated, but global/local/group may be displayed. + URL to a 32x32 .png to show rather than a player avatar, or null/empty. + Enable rich tags e.g., bold, italics in the message contents. - + - Invoked when any player exits the driver seat. + Nelson 2024-10-14: We might want to elaborate on this with "client-side chat commands" in the future, but + for the meantime I've hacked in this one command. - + - Invoked when a locally controlled player enters the driver seat. + Allow Unity events to forcefully remove any barricades inside a sphere. - + - Invoked when a locally controlled player exits the driver seat. + If non-zero, legacy ID of final Asset to return. - + - Invoked when a locally controlled player enters the vehicle. + If non-zero, legacy ID of SpawnAsset to resolve. - + - Invoked when a locally controlled player exits the vehicle. + If both legacy IDs are zero this GUID will be used. If the target asset is + a SpawnAsset it will be further resolved, otherwise the found asset is returned. - + - Invoked when lock is engaged. + Can be enabled by spawn tables that insert themselves into other spawn tables using the roots list. + If true, zeros the weight of child tables in the parent spawn table. - + - Invoked when lock is disengaged. + Has this spawn been added as a root of its child spawn table? + Used for debugging spawn hierarchy in editor. - + - Invoked when horn is played. + Helper method for plugins because IDs are internal. - + - Invoked after explosion plays. + Parent spawn assets this would like to be inserted into. - + - Root transform. + Zero weights of child spawn tables. + Called when inserting a root marked isOverride. - + - Hit collider's transform. Can be null. + Do tables need to be sorted and normalized? - + - Tag display name without rich text formatting. To use, for example, in logging, sorting, or with rich color override. + Sort children by weight ascending, and calculate their normalized chance as a percentage of total weight. - + - If true, tag requests name to be displayed in UI with NameColor label color override. + Remove from roots, and if reference is valid remove us from their children. - + - Color to use in UI when displaying name. + Remove from tables, and if referencing a child table remove us from their roots. - - - If HasNameColor is enabled, this is PlainTextName wrapped with NameColor rich text color tags. - If unset, falls back to PlainTextName. - - Nelson 2025-05-02: initially, we allowed enabling any rich text tags in names. But, considering that we - are also using PlainTextName for other color overrides (e.g. "bad" when missing), this will be disappointing - if tags are displayed inconsistently. - - - + - If true, icon should be tinted according to player's foreground color preference. + Mesh Replacement Details + .dat Flags: + Has_1P_Character_Mesh_Override True Bool + Character_Mesh_3P_Override_LODs # Int + Has_Character_Material_Override True Bool + Asset Bundle Objects: + Character_Mesh_1P_Override_# GameObject with MeshFilter (mesh set to a skinned mesh) + Character_Mesh_3P_Override_# GameObject with MeshFilter (mesh set to a skinned mesh) + Character_Material_Override Material - + - Wrap PlainTextName with color rich text tag. + Replacements for the main 1st-person character mesh. - + - Wrap PlainTextName with player's font color preference. + Replacements for the main 3rd-person character mesh. - + - If HasNameColor, get RichTextName. Otherwise, get PlainTextNameWithPreferredFontColor. + Replacement for the main character material that typically has clothes and skin color. - + - Get sleek color for UI. If HasNameColor, get NameColor. Otherwise, preferred font color. + Called by navmesh baking to complete pending object changes that may affect which nav objects are enabled. - + - Allows Unity events to modify which crafting tags are provided by owning object. - Must be connected to a Crafting Tag Provider. + Hide culling volume by default because new mappers might wonder what these purple boxes + are and why their number goes away after moving objects. - + - GUIDs of Unturned tag assets to modify. + Check a fixed number of volumes for visibility updates per frame. - + - Add listed tags to provided tags. + Any volumes in the process of enabling/disabling get updated once per frame. - + - Remove listed tags from provided tags. + True for the next update after the player is teleported. - + - Apply only if this component is active and enabled. + [0, 1] percentage whether a shot decreases ammo count. Defaults to 100%. + For example, 0.25 means 25% of shots will use a bullet, while the remaining 75% will be free. - + - Apply only if this component is inactive and/or disabled. + [0, 1] percentage whether a shot decreases quality. Defaults to 100%. + Combined with the gun's chance of decreasing quality. - + - Always apply. + Players/zombies within this range are treated as potential targets while scanning. - + - Get wrapper method rather than Awake because component might be inactive but should still apply modifiers. + Will not lose current target within this range. Prevents target from popping in and out of range. - + - Used for item placement in displays / holsters, and whether useable can be placed in primary/secondary slot. + If true, this sentry can attack players. Defaults to true. - + - Cannot be placed in primary nor secondary slots, but can be equipped from bag. + If true, this sentry can attack zombies. Defaults to true. - + - Can be placed in primary slot, but cannot be equipped in secondary or bag. + If true, this sentry can attack animals. Defaults to true. - + - Can be placed in primary or secondary slot, but cannot be equipped from bag. + If true, this sentry can attack vehicles. Defaults to true. - + - Only used by NPCs. + If true, sentry can damage players and vehicles in PvE mode. - + - Can be placed in primary, secondary, or equipped while in bag. + If true, sentry immediately focuses on attacking player. - + - Project current field of view onto screen compared to desired field of view. + Degrees away from forward sentry yaw sweeps left/right. - + - Multiply sensitivity according to scope/optic zoom. For example an 8x zoom has 1/8th sensitivity. + Duration in seconds for sentry to complete a sweep from left to right and back again. - + - Preserve how sensitivity felt prior to 3.22.8.0 update. + If modifying usage please update support article: + https://support.smartlydressedgames.com/hc/en-us/articles/13452208765716 - + - Do not adjust sensitivity while aiming. + If modifying usage please update support article: + https://support.smartlydressedgames.com/hc/en-us/articles/13452208765716 - + - When held the cursor is released. + Client has a critical module the server doesn't. - + - If held while clicking a blueprint action in the item context menu, the crafting menu is bypassed. + Server has a critical module the client doesn't. - + - Replace instances of with their bound key text. - Allows server effects to display plugin hotkeys. + Level config's version number does not match. - + - Item 0 is "1" and item 9 is "0" + EconInfo.json hash does not match. - + - Multiplier for Input.GetAxis("mouse_x") and Input.GetAxis("mouse_y") + Master bundle hashes do not match. - + - When held the cursor is released. + Server has not received an auth session response from Steam yet. - + - If held while clicking a blueprint action in the item context menu, the crafting menu is bypassed. + Server has not received an economy response from Steam yet. - + - Broadcasts once all workshop assets are finished installing. + Server has not received a groups response from Steam yet. - + - Called once the server is done registering items it wants to install. + Player nickname exceeds limit. - True when running in offline-only mode. - + - Request for details about the pending items. + Player nickname contains invalid characters. + + If modifying usage please update support article: + https://support.smartlydressedgames.com/hc/en-us/articles/13452208765716 - + - File IDs of all the items we have enqueued for query. + Player nickname should not be a number. - + - Built from user-specified workshop item IDs, and then expanded as the query results - arrive with details about any dependent or child items. + Player resources folders don't match. - + - File IDs requested by the latest query submitted. + The network identity in the ticket does not match the server authenticating the ticket. + This can happen if server's Steam ID has changed from what the client thinks it is. + For example, joining a stale entry in the server list. (public issue #4101) - + - Number of times we've tried re-submitted failed queries. + Player's skin color is too similar to one of . - + - Built as the valid list of items arrive. + Steam ID reported by net transport doesn't match client's reported Steam ID. + This was exploited to fill the server queue with fake players. - + - ID of the latest item we requested for download so that we can test if the callback is for us. + Received too many connection requests from player in a short window. - + - Enqueue an item if we have not queried it yet. This guards against querying an item - that is in two separate collections leading to duplicates. + Received too many invalid messages from connection in a short window. - - True if item was installed from cache. - - + - Used in offline-only mode. + Server limits how many clients are joining from the same IP address. + (public issue #5001) - - - Prepare a query that will request metadata for all the workshop items we want to install. - This allows us to check if the items are allowed to be auto-downloaded to this server, and to - detect any child or dependent items. - - Waits for onQueryCompleted. - - - + - Re-submit previous query after a query failure. + Can be added to Vehicle GameObject to receive events. - + - If level is using underground whitelist then conditionally clamp world-space position. + Invoked when any player enters the driver seat. - + - If level is using underground allowlist then conditionally clamp world-space position. + Invoked when any player exits the driver seat. - + - Used by animals and zombies to teleport to a spawnpoint if outside the map. + Invoked when a locally controlled player enters the driver seat. - + - Used by housing validation to check item isn't placed underground. + Invoked when a locally controlled player exits the driver seat. - - - Almost every menu has a container element for its contents which spans the entire screen. This element is then - animated into and out of view. In the IMGUI implementation this was fine because containers off-screen were not - processed, but with uGUI they were still considered active. To solve the uGUI performance overhead this class - was introduced to disable visibility after animating out of view. + + + Invoked when a locally controlled player enters the vehicle. - + - Payload for the EffectManager.triggerEffect method. + Invoked when a locally controlled player exits the vehicle. - + - Required effect to spawn. + Invoked when lock is engaged. - + - World-space position to spawn at. + Invoked when lock is disengaged. - + - Local-space scale. Defaults to one. + Invoked when horn is played. - + - If running as server should this effect be replicated to clients? - Defaults to true. Set to false for code that is called on client AND server. + Invoked after explosion plays. - + - Should the RPC be called in reliable mode? Unreliable effects might not be received. + Get animal or player damage based on game mode config. - + - Was a player directly responsible for triggering this effect? - For example grenade explosions are instigated by players, whereas zombie acid explosions are not. - Used to prevent mod damage on the effect prefab from hurting players on PvE servers. + Get zombie or player damage based on game mode config. - + - Players within this radius will be sent the effect unless the effect overrides it. - Defaults to 128. + Number of Attack_# animations. - + - Get world-space rotation for the effect. + Number of Eat_# animations. - + - Set world-space rotation for the effect. + Number of Glance_# animations. - + - World-space rotation for the effect. + Number of Startle_# animations. - + - If true, rotation was specified by setter methods. - Required for backwards compatibility because `direction` field is public. + Maximum distance on the XZ plane. - + - Only send the effect to the given player, if set. + Maximum distance on the XZ plane when attacking vehicles. - + - Only send the effect to the given players, if set. - Otherwise relevantDistance is used. + Maximum distance on the Y axis. - + - Only send the effect to the given player, if set. + Minimum seconds between attacks. - + - World-space direction to orient the Z axis along. Defaults to up. + Temporary until something better makes sense? For Spyjack. - + - Nelson 2025-04-08: newer code should probably use CachingAssetRef instead. (Or CachingLegacyAssetRef if legacy - ID support is necessary.) + If true, animal won't start moving until startle animation finishes. - + - Whether the asset has been assigned. Note that this doesn't mean an asset with exists. + This value is confusing because in the level editor it is the normalized radius, but in-game it is the square radius. - + - Is this asset not assigned? + Used by dawn and dusk skins which pull per-level lighting colors. - + - True if resolving this asset reference would get that asset. + Note: unfortunately it appears the stupid skin system always instantiated materials, but never destroys + them... will need to clean this up, but it will be tricky because the game does not hold a reference to them. - + - Resolve reference with asset manager. + If true, sets the Magazine attachment hook inactive while this skin is applied. (guns only) + + Nelson 2025-03-10: Adding this to address mismatched Ace bullets with certain skins. (public issue #4923) + It should be fine for vanilla guns because there shouldn't be assumptions about Magazine enable/disable, + but modded guns may have different expectations (particularly with GunAttachmentEventHook). - + - GUID of the asset this is referring to. + Used by melee skins to override impact sound. - + - Each quality tier has different rarities. - Legendary: 5% Epic: 20% Rare: 75% + Invoked immediately before Destroy vehicle. - + - Each item has an equal chance regardless of quality. + Exposed for Rocket transition to modules backwards compatibility. - + - Kept because lots of modders have been these scripts in Unity, - so removing legacy effect id would break their content. - Note: unsure about this one because it is private and not serialized. + If true, a vehicle asset has been replaced. - + - Sorts higher rarity items into the front of the list. + Find vehicle with matching replicated instance ID. - + - Set handles pivot point according to selection transform. - Doesn't apply if handle is currently being dragged. + Supports redirects by VehicleRedirectorAsset. If redirector's SpawnPaintColor is set, that color is used. - + - If Unturned is loading this asset bundle from a Steam workshop file but the file ID does not match then - loading will be canceled. Prevents the asset bundle from being easily copied/stolen. + Supports redirects by VehicleRedirectorAsset. If paintColor is set that takes priority, otherwise if + redirector's SpawnPaintColor is set, that color is used, - - - Same as ownerWorkshopFileId for cases where the asset bundle is allowed in multiple uploads. - - Uploading the same asset bundle multiple times is not ideal because the game doesn't handle - multiple of them with the same name well, and Unity logs an error if an asset bundle with the - same files is already loaded. That being said, the game doesn't handle dependencies between - workshop files well either (as of 2023-01-12), so this is perhaps the lesser of two evils. - - My understanding is that some mod creators license their work to multiple servers that upload - the files and this property will make it easier so it doesn't need to be re-exported multiple times. - + + + Supports redirects by VehicleRedirectorAsset. If redirector's SpawnPaintColor is set, that color is used. + - + - Helpers on the dedicated server to optimize client prefabs for server usage. + Supports redirects by VehicleRedirectorAsset. If paintColor is set that takes priority, otherwise if + redirector's SpawnPaintColor is set, that color is used, - + - Optimize client prefab for server usage. + Supports redirects by VehicleRedirectorAsset. If redirector's SpawnPaintColor is set, that color is used. - + - If true, object is within a culling volume. - Name is old and not very specific, but not changing because it's public. + Supports redirects by VehicleRedirectorAsset. If paintColor is set that takes priority, otherwise if + redirector's SpawnPaintColor is set, that color is used, - + - Transform created to preserve objects whose assets failed to load. - Separate from default transform to avoid messing with old behavior when transform is null. + Supports redirects by VehicleRedirectorAsset. If redirector's SpawnPaintColor is set, that color is used. - + - If true, can be instantiated. Defaults to true. - Enables mappers to remove culling volumes embedded in objects if they're causing issues. + Supports redirects by VehicleRedirectorAsset. If paintColor is set that takes priority, otherwise if + redirector's SpawnPaintColor is set, that color is used, - + - Can this object's rubble be damaged? - Allows holiday restrictions to be taken into account. (Otherwise holiday presents could be destroyed out of season.) + Added so that garage plugins do not need to invoke RPC manually. + zero spawns without a battery, ushort.MaxValue indicates the battery should be randomly spawned according to asset configuration, other values force a battery to spawn. - + - Object activation is time-sliced, so this does not necessarily match whether the region is active. + For backwards compatibility. This older method spawns a vehicle with a random paint color. (set paintColor + to zero for a random paint color) + zero spawns without a battery, ushort.MaxValue indicates the battery should be randomly spawned according to asset configuration, other values force a battery to spawn. - + - Defaults to true because most objects are not inside a culling volume. + Used by external spawn vehicle methods. + Supports redirects by VehicleRedirectorAsset. If redirector's SpawnPaintColor is set, that color is used, + unless preferredColor.a is byte.MaxValue. + Owner to lock vehicle for by default. Used to lock vehicles to the player who purchased them. - + - Used by InteractableObjectBinaryState to indicate whether it wants navGameObject to be active. It's only - active if both IOBS and Rubble want it active. + Client-side request server to toggle headlights. - + - Used by InteractableObjectRubble to indicate whether it wants navGameObject to be active. It's only - active if both IOBS and Rubble want it active. + As client request server to use bonus feature like towing hook or police sirens. - + - Used if the object asset has weather blend alpha conditions. + Helper for servers with huge numbers of vehicles. + Called with fixed span of indexes e.g. [0, 10), then [10, 20). This function then clamps the final span to the vehicle count. - + - Used if the object asset has weather status conditions. + Plugin devs: if you are using reflection to call this even though it's private, please use sendExitVehicle + instead which properly handles player culling. - + - Callback when an individual quest flag changes for the local player. - Refreshes visibility conditions if the flag was relevant to this object. + Does as few tests as possible while maintaining base game expectations. - + - Separate from UpdateActiveAndRenderersEnabled so graphics settings can call it. + Force remove player from vehicle they were in, if any. + Called when player disconnects to tidy up and run callbacks. + True if player was in a vehicle, false otherwise. - + - Assume renderers default to enabled. + Remove player from vehicle and teleport them to an unchecked destination. - + - Combine two existing 20-byte hashes. + Handles culling if exit position is not visible to certain clients. + If adjusting how this works, PlayerLife.SendReviveTeleport may need revision. - + - Utility to hash a stream of bytes over several frames. + Is spawnpoint open for vehicle? - + - [0, 1] percentage progress through the stream. + Try to find a random spawnpoint to spawn a vehicle while server is running. - + - Advance 1MB further into the stream. + Add a new vehicle at given spawnpoint. + Supports redirects by VehicleRedirectorAsset. If redirector's SpawnPaintColor is set, that color is used. - True if there is more data, false if complete. - + - Get the computed hash after processing stream. + Add a new vehicle at given spawnpoint and replicate to clients. + Supports redirects by VehicleRedirectorAsset. If redirector's SpawnPaintColor is set, that color is used. - + - If true, visible in chart and satellite UIs. + Called when deciding whether to respawn a new vehicle, after gameplay has begun. - + - Multiplier for explosive projectile damage. + Called during level load to determine how many vehicles to create. - + - Multiplier for explosive projectile's blast radius. + Called on server each frame to slowly damage abandoned vehicle. - + - Multiplier for explosive projectile's initial force. + +0 = InteractableVehicle + +1 = root transform + +X = VehicleBarricadeRegion + Asset does not know number of train cars, so we always reserve slack. - + - Should amount be filled to capacity when detached? + Speed is unsigned, so 8 bits allows a range of [0, 256). - + - Nelson 2024-10-18: Moved to a constant because clients need this value for footsteps and they don't have the - character controller component. + Velocity is signed, so 9 bits allows a range of [-256, 256). - + - Jump speed = sqrt(2 * jump height * gravity) - Jump height = (jump speed ^ 2) / (2 * gravity) - With 7 speed and 9.81 * 3 gravity = apex height of 1.66496772 + Distance along tree's local up axis to offset debris spawn position. Defaults to 1.0. - + - Note: Only UpdateCharacterControllerEnabled should modify whether controller is enabled. - (turning off and back on is fine though) + Before had randomization properties each tree has + some random rotation and scale variation based on its position. This property controls + the rotation away from upright. - + - Valid while isRadiated. + Amount of experience to reward foraging player. - + - Set according to volume or level global asset fallback. + Forageable resource message. - + - Was set to true during teleport, and restored to false during the next movement tick. - - Server pauses movement when this is set until next client update that matches, - in order to prevent rubberbanding following a teleport. + Weapon must have matching blade ID to damage tree. + Both weapons and trees default to zero so they can be damaged by default. - + - Used instead of actual position to avoid revealing admins in "vanish" mode. + If true, prevent collisions between falling tree and the stump. (i.e., debris can fall through stump) + Defaults to true. - + - Flag for plugins to allow maintenance access underneath the map. + Only activated during this holiday. - + - Get seat (if any), otherwise null. + Tree to use during the Christmas event instead. - + - Serverside force player to exit vehicle regardless of safe exit points. + Tree to use during the Halloween event instead. - True if player was seated in vehicle. - + - Dedicated server simulate while input queue is empty. + Get asset ref to replace this one for holiday, or null if it should not be redirected. - + - Dedicated server simulate driving input. + Deserialize JSON onto an existing object instance. - + - Client and dedicated server simulate walking input. + Potentially useful for players with corrupted cloud storage. + https://github.com/SmartlyDressedGames/Unturned-3.x-Community/issues/2756 - - - In the future this can probably replace checkGround for locally simulated character? - (Unturned only started using OnControllerColliderHit on 2023-01-31) - - 2023-02-28: be careful with .gameObject property because it returns .collider.gameObject - which can cause a null reference exception. (public issue #3726) - - - + - Examine a store listing with description text. + Introduced much later (2020) than most of the other methods in this class (2014) in order to properly handle + BOM/preamble of text files. Matches somewhat undesirable legacy behavior like creating directories. - + - Only visible when cart is not empty. + NOTE: From and to are both relative to PATH. - + - Convert 32-bit version into 8-char string. - String is advertised on server list for clients to filter their local map version. + NOTE: From and to are both relative to PATH. - + - Parse 32-bit version from 8-char string. - String is advertised on server list for clients to filter their local map version. + Read GUI texture from a .jpg or .png file. - + - These server relay variables redirect the client to another server when the menu opens - similar to how Steam sets the +connect string on game startup. Allows plugin to redirect - player to another server on the same network. + Read GUI texture from a .jpg or .png file. - - If true the server is immediately joined, otherwise show server details beforehand. + + + Prevents static member from being initialized during MonoBehaviour construction. (Unity warning) + - + - If player gets too far away from this storage while using it, should we close out? - False by default for trunk storage because player is inside vehicle. - Plugins needed to be able to set this to false for "virtual storage" plugins, - so we default to false and set to true if asset enables it. + Kept for backwards compatibility with plugins. - + - Keep all the uGUI Canvas sort orders in the same place. + Editor-only helper to read all text/dialogue. - + - Manually created canvas in the Menu scene. + Tracks whether we should show the "NEW" label on listings and item store button. - + - Devkit canvas in the Setup scene. + Track that player has seen the new crafting blueprints. - + - Dropdowns, drag-drop content, tab destinations, etc. + Track that player has seen the page with all new listings. - + - Devkit tooltips should be visible over all other devkit content. + Has player seen the given listing? - + - uGUI glazier contains tooltips and cursor regardless of mode (e.g. devkit), so takes absolute priority. + Track that the player has seen the given listing. - + - Plugins were spawning canvases with high sort orders that showed over the loading screen, so as a hacky - workaround we put the uGUI loading screen on a higher sort order than normal glazier. + Seconds to wait between burning one unit of fuel. - + - uGUI cursor needs to show above plugin canvas. - Unity exposes sort order as an int32, but it is actually an int16, so this value is slightly below the 32767 max. + Delete all savedata folders for player's characters. - + - Worst case scenario, maybe shotgun hit or fast spray SMG. + Corresponds to not active and not blending with new weather system. - + - Tags how client expects server to use a raycast input. - For example, client may think they fired a gun while server thinks they dequipped the gun, - so tagging the input prevents the server from handling it as a punch instead. + Corresponds to transitioning in with new weather system. - + - Nelson 2025-09-09: changing to only require bounds test when usage will - apply damage because Detonator usage provides the barricade root transform - which may not have a collider. (Public issue #5202.) + Corresponds to active with new weather system. - + - Resulting transform.position immediately after movement.simulate was called. + Corresponds to transitioning out with new weather system. - + - Calls to UseableGun.tock per second. + Corresponds to not active and not blending with new weather system. - + - Called for every input packet received allowing plugins to listen for a few special - keys they can display in chat/effect UIs. + Corresponds to transitioning in with new weather system. - + - Whether client is currently penalized for potentially using a lag switch. False positives are relatively - likely when client framerate hitches (e.g. loading dense region), so we only modify their stats (e.g. reduce - player damage) for a corresponding duration. + Corresponds to active with new weather system. - + - Server tracks history of this player's bounding box to assist with validating hits. - Some padding is added to reduce false positives sliding against walls (substep) and - player movement inside vehicles. + Corresponds to transitioning out with new weather system. - + - Get the hit result of a raycast on the server. Until a generic way to address net objects is implemented - this is how legacy features specify which player/animal/zombie/vehicle/etc they want to interact with. + Kept for backwards compatibility with mod hooks, plugins, and events. - + - Ideally simulation frame number would be signed, but there is a lot of code expecting unsigned. + Kept for backwards compatibility with mod hooks, plugins, and events. - + - Can be enabled in the unity inspector to test that discarding inputs recovers properly. + [0, 1] used to avoid invoking BlendAlphaChanged every frame. + Compared against globalBlendAlpha not taking into account local volume. - + - askInput is always called the same number of times per second because it's run from FixedUpdate, - but the spacing between calls can vary depending on network and whether client FPS is low. + Hash of lighting config. + Prevents using the level editor to make night time look like day. - + - If average askInput calls per second exceeds this, we either ignore their request or flat-out kick them. + Level designed target fog color. - + - If average askInput calls per second exceeds this we silently kick them. + Level designed target fog intensity. - + - Number of times askInput has been called by client. - Even with huge packet loss, we know that + Level designed target atmospheric fog intensity. - + - Realtime that the first call to askInput was made by the client. + If global ocean plane is enabled then return the worldspace height, + otherwise return the optional default value. Default for volume based + water is -1024, but atmosphere measure uses a default of zero. - + - Realtime that the previous askInput kick test was performed. + Nelson 2025-09-01: hacking this in to reset cloud particle systems when changing time + in the level editor. Otherwise, it's hard to tell how the intensity affects them. - + - Set rollingWindowIndex to newIndex, zeroing all input counts along the way. - Important to zero the intermediary indexes in-case server stalled for more than one second. + Ticked on dedicated server as well as client so that server can listen for weather events. + On dedicated server this is always 0xFFFFFFFF. - + - Notify client there has been a prediction error, so movement needs to be re-simulated. + Reset any global shader properties that may affect the main menu. - + - Notify client old inputs can be discarded because they were predicted correctly. + Source effect to group multiple volumes. - + - Not using rate limit attribute because it internally keeps a rolling window limit. + Audio source added to AmbianceAudioGameObject. - + - Only bound on dedicated server. - When dieing in a vehicle this prevents delay handling packets. + Reset to false before updating volumes. - + - Counter of simulation frames before fake lag penalty is disabled. + Reset to false before updating volumes. - + - Player damage multiplier while under penalty for fake lag. (10%) + Reset to zero before updating volumes. If any volume uses distance fadeout, this is the maximum alpha. - + - If set, this item is prioritized over equipped cosmetics. Used by item inspect menu. - Admittedly, this is very hacked-together. Hopefully rewriting this file someday? + If any volume doesn't use distance fadeout, this is the alpha based on time spent inside.. - + - Is cosmetic or skin equipped? + Highest priority of overlapping volumes. - + - Merging the devkit, legacy, and housing transform handles into one place. + If any volume doesn't use distance fadeout, this is the minimum of their audio fade-in time. - + - Position and plane handles for each axis. + If any volume doesn't use distance fadeout, this is the minimum of their audio fade-out time. + Only reset when created so that value is available after leaving all volumes. - + - Disc handles for each axis. + Material to use during the Christmas event instead. - + - Scale handles for each axis. + Material to use during the Halloween event instead. - + - Position handles on each side of box. + Material to use during the April Fools event instead. - + - Scale handles on each side of box which both move and resize the box. + Allows Unity events to spawn vehicles. - + - Invoked when handle is clicked so that tool can save selection transform relative to pivot. - This avoids floating point precision loss of applying delta for each Transformed event. + When loaded or spawned as a vehicle, creates a different vehicle instead. + For example, Off_Roader_Orange has ID 4. When that ID is loaded/spawned the new combined Off_Roader vehicle is + used instead. Can also optionally apply a paint color, allowing saves to be converted without losing colors. - + - Invoked when handle is dragged and value actually changes. + Redirectors are in the Vehicle category so that legacy vehicle IDs point at the redirector. - + - Invoked when handle is dragged and value actually changes. + Vehicle to use when attempting to load or spawn this asset. - + - Preferred mode only takes effect while not dragging. - Bounds modes fall back to non-bounds modes if bounds are not set. + If set, overrides the default random paint color when loading a vehicle from a save file. + Used to preserve colors of vehicles in existing saves. - + - Pivot only takes effect while not dragging. This is to help ensure - the caller does not depend on the internal pivot values. + If set, overrides the default random paint color when spawning a new vehicle. + Optionally used to preserve colors of vehicles in spawn tables. - + - Somewhat hacky, useful to make the "copy-paste transform" feature easier to implement. - Invoke tranformed callback as if pivot were manually dragged to the new position and rotation. + Remove items that do not match search text. - + - Called before raycasting into the regular physics scene to give transform tool priority. + Note SetListing also calls RefreshInCart. - + - Update properties that depend on the transform of the camera relative to our handles. + Cannot be created until store data is available. - + - Center of handle. + Toggle button to open/close advanced filters panel. - + - Rotation of handle. + On/off checkbox for including already-owned items in filter. - + - True if pivotBounds is non-zero. + Container for advanced options. - + - Mouse currently over this handle. + Displays the current page number. - + - Mouse currently dragging this handle. + Only visible when cart is not empty. - + - Direction from camera toward pivot. + [0, pageCount) - + - Multiplier according to distance between camera and pivot to keep handles a constant on-screen size. + If true, listings should be re-filtered when opening the menu. - + - Multiplier to flip axis handles according to which side the camera is on. + Collections of multiple items. - + - Pivot rotation when rotation drag started. + Discounted items. - + - Rotating around this axis. + Items marked as new in the Status.json file. - + - Direction from circle center to edge point. + Items marked as featured in the Status.json file. - + - Point on the edge of the circle. + Can be added to any GameObject with a Trigger to receive events. + Ensure that Layer will detect player overlaps. Trap is a good candidate. - + - Drag along this tangent to the circle. + Invoked when a player enters the trigger. + Called before OnFirstPlayerEnter. - + - Does having this item show the compass? + Invoked when a player exits the trigger. + Called before OnAllPlayersExit. - + - Does having this item show the chart? + Invoked when first player enters the trigger, and not again until all players have left. + Called after OnPlayerEnter. - + - Does having this item show the satellite? + Invoked when last player exits the trigger. + Called after OnPlayerExit. - + - Ideally component Awake/Start order should not matter, but Unturned's menu is a mess. - For most players the default order was fine, but it seems it was not deterministic so it would break for some players. + Originally this was only in the uGUI implementation, but plugins can create uGUI text fields + regardless of which glazier is used. - + - Index into per-connection rate limiting array. + Nelson 2024-11-29: Curious to put all the gun stats in one place for easier comparison. Rather rudimentary at + the moment so not including in the update. - + - Number of server methods with rate limits. + Project current field of view onto screen compared to desired field of view. - + - Log all known net methods. + Multiply sensitivity according to scope/optic zoom. For example an 8x zoom has 1/8th sensitivity. - + - Useful debug check to ensure every built-in handle is claimed exactly once. + Preserve how sensitivity felt prior to 3.22.8.0 update. - + - This class gets used from type initializers, so Unity's built-in log is not an option unfortunately. + Do not adjust sensitivity while aiming. - + - Not *really* supported but *might* probably work. Adding for public discussion #4176. + When held the cursor is released. - + - Kept for backwards compatibility with plugins. + If held while clicking a blueprint action in the item context menu, the crafting menu is bypassed. - + - Can be added to EquipablePrefab item GameObject to receive events. + Replace instances of with their bound key text. + Allows server effects to display plugin hotkeys. - + - Invoked when gun is fired. + Item 0 is "1" and item 9 is "0" - + - Invoked when gun begins reload sequence. + Multiplier for Input.GetAxis("mouse_x") and Input.GetAxis("mouse_y") - + - Invoked when gun begins hammer sequence. + When held the cursor is released. - + - Invoked when gun begins aiming. + If held while clicking a blueprint action in the item context menu, the crafting menu is bypassed. - + - Invoked when gun ends aiming. + Allows pooling elements. + If set, this is called rather than removing element from scroll view. - + - Invoked when Magazine game object is activated. + Kind of hacky... Used by player list for group connections. - + - Invoked when Magazine game object is activated. + Keep all the uGUI Canvas sort orders in the same place. - + - TextMesh Pro uGUI text components. + Manually created canvas in the Menu scene. - + - TextMesh Pro uGUI input field components. + Devkit canvas in the Setup scene. - + - Exposed for Rocket transition to modules backwards compatibility. + Dropdowns, drag-drop content, tab destinations, etc. - + - This effect makes a nice clicky sound and lots of older code used it, - so I moved it into a little helper method here. + Devkit tooltips should be visible over all other devkit content. - - If true, client will download the image once and re-use it for subsequent calls. - If true, client will destroy any cached copy of the image and re-acquire it. - - + - Notify server that a button was clicked in a clientside effect. + uGUI glazier contains tooltips and cursor regardless of mode (e.g. devkit), so takes absolute priority. - + - Notify server that an input field text was committed. + Plugins were spawning canvases with high sort orders that showed over the loading screen, so as a hacky + workaround we put the uGUI loading screen on a higher sort order than normal glazier. - + - If an effect with a given key exists, destroy it. + uGUI cursor needs to show above plugin canvas. + Unity exposes sort order as an int32, but it is actually an int16, so this value is slightly below the 32767 max. - + - parent should only be set if that system also calls ClearAttachments, otherwise attachedEffects will leak memory. + Entry in the MenuPlayServerCurationUI list. - + - Helper for sending and spawning effects. - Newer and refactored code should use this method. + Can be added to gun item game objects (including children) to receive events. - + - Objects registered so that they can be destroyed all at once if needed. - May be null if they were destroyed with a timer. + Which attachment type to monitor. - + - Plugin UIs spawned by the server. + Optional. If set, only consider item matching this GUID. I.e., slot is considered empty if attached item + has a different asset GUID. - + - Called prior to destroying effect (if attached) to free up attachments list. + If true, AssetGuidFilter passes when item in slot *doesn't* match GUID. - + - Called after attaching effect so that it can be returned to pool when/if parent is destroyed. + Invoked both when: + 1. Gun is first equipped and an item is already present in the slot. + 2. An item is added to the slot. - + - Maps root transform to any attached effects. - This allows us to detach effects when returning a barricade/structure to their pool. + Invoked both when: + 1. Gun is first equipped and the slot is empty. + 2. An item is removed from the slot. - + - Recycled lists for attachedEffects dictionary. + Controls whether events are invoked when asset in slot changes. - + - Find materials in finished ragdoll and replace them with the appropriate effect. + Nelson 2025-02-04: Gun attachment slots are currently hard-coded, but if that changes this could be updated + with a "custom" option. - + - Context for the Assets.ReportError methods. - Nelson 2024-11-20: Converted from directly using asset to this interface so that asset-related features can - more easily log warnings to the in-game menu. + If emptiness of slot doesn't change (attachment replaced), do nothing. - + - Format text to prefix any errors reported in this context. (e.g., this asset's name and ID) + In addition to regular Attached and Detached events, if the item asset in the slot changes invoke + Detached then Attached. - + - Alerts any agents in the area to the player if needed. + Controls how first-person arms are moved for turrets operated from the driver's seat. - The player causing this alert. - The position of the alert. - The detection radius. - Whether or not to hide. - + - Alerts any agents in the area. + Default. Pushes first-person arms off-screen while aiming. Originally implemented for the Fighter Jet where + it looks weird if your arms are still visible when the camera zooms in while "aiming." - The position of the alert. - The detection radius. - + - Report success or failure from game systems, conditionally compiled into the Windows 64-bit build. + Push first-person arms off-screen when equipped. - + - Call when the server is done all loading without running into errors. - Ignored if not running in CI mode, otherwise exits the server successfully with error code 0. + No particular use in mind, but included for completeness. - + - Call when the server encounters any error. - Ignored if not running in CI mode, otherwise exits the server with error code 1. + Default. Plays "Hammer" animation if ammo count was zero. - + - Entry in the MenuPlayServerCurationRulesUI list. + Regardless of ammo, does not play "Hammer" animation after reloading. - + - Seconds to wait between burning one unit of fuel. + Regardless of ammo, will play "Hammer" animation after reloading. - + - Number of seconds to finish growing. + Sound to play when input is pressed but weapon has a fire delay. - + - Item legacy ID to grant the player. + Maximum distance the gunshot can be heard. - + - Uses unscaled time (realtime) because "planted" time is a timestamp. + Override Rangefinder attachment's maximum range. + Defaults to range value. - + - Created when a chat entry is received from the server for display in the UI. + Can this weapon instantly kill players by headshots? + Only valid when game config also enables this. - + - Player who sent the message, or null if it was a plugin broadcast. - Used to retrieve player avatar. + Can this weapon be fired without consuming ammo? + Some mods use this for turrets. - + - Web address of a 32x32 .png to use rather than a platform avatar. - Only used if not null/empty. + Ammo quantity to consume per shot fired. - + - How the message was sent through global, local or group. - Mostly deprecated because that status isn't formatted into texts anymore. + Simulation steps to wait after input before firing. - + - Default font color to use unless overridden by rich text formatting. + Can magazine be changed by player? - + - Whether this entry should enable rich text formatting. - False by default because players abuse font size and ugly colors. + Can player ADS while sprinting and vice versa? - + - Text to display for this message. + If true, the gun cannot shoot unless the player is aiming. + Note: String action overrides this. + Defaults to true for miniguns. - + - When the entry was locally received from the server. + If true, the gun will stop aiming regardless of player input. - + - How many seconds ago this message was locally received from the server. + Seconds from pressing "aim" to fully aiming down sights. - + - Event for plugins to be notified when a server update is detected. - - Pandahut requested this because they run the game as a Windows service and need to shutdown - through their central management system rather than per-process. + If true, Aim_Start and Aim_Stop animations are scaled according to actual aim duration. - + - Manages scheduled restart for dedicated server. + Selects a default magazine, following magazine replacements and spawn table resolution. - + - Sorted from low to high. + Selects a default magazine, following magazine replacements and spawn table resolution. - + - Sorted from low to high. + How long in seconds after firing to rechamber the gun by playing the Hammer animation. + Only applicable if RechamberAfterShotCount is >0. + Defaults to 0.25 seconds. - + - Non-NPC object the player can talk with. + How long in seconds after hammering to eject a bullet casing. + Defaults to 0.45 seconds. - + - Broadcasts for plugins before applying consumeable stats to another player. + How long in seconds after reloading to eject bullet casings. + Only applicable if CasingEjectCountAfterReload is greater than zero. + Defaults to 0.5 seconds. - + - Broadcasts for plugins after applying consumeable stats to another player. + Defaults to false. If true, attachments must specify at least one non-zero caliber. + Requested by Great Hero J to block vanilla attachments in VGR. - + - Broadcasts for plugins before applying consumeable stats to self. + Determines whether "Hammer" animation plays after attaching a magazine. + Note: this happens when a magazine replaces another OR fills previously empty slot. - + - Broadcasts for plugins after applying consumeable stats to self. + Determines whether "Hammer" animation plays after detached a magazine. + Note: this happens when a magazine is removed from the gun without a replacement. - + - Called serverside when using consumeable on another player. + Spread multiplier while sprinting. - + - Called by owner and server when using consumeable on self. + Spread multiplier while crouched. - + - If false, a deny rule matched the input. + Spread multiplier while prone. - + - If true, at least one rule matched the input. + Spread multiplier while swimming. - + - If set, this was the final match. + Spread multiplier while not grounded. - + - Optional. If set, filled with any rules that matched. + Recoil magnitude multiplier while the gun is aiming down sights. - + - If >0, this link was added by live config. + Recoil magnitude while sprinting. - + - Determines how a server that doesn't match any rules is handled. + Recoil magnitude while crouched. - + - Include in the list. Default. + Recoil magnitude while prone. - + - Exclude from list. (same as EServerListCurationDenyMode.Hide) + Recoil magnitude while swimming. - + - Move to the bottom of the list. Similar to EServerListCurationDenyMode.MoveToBottom, but the server is - still clickable. I.e., low priority. + Recoil magnitude while not grounded. - + - Called earlier during startup to try and have web lists ready by the time server browser is opened. + [0, 1] percentage of maximum range where damage begins decreasing toward falloff multiplier. - + - Used to detect asset refresh. + [0, 1] percentage of maximum range where damage finishes decreasing toward falloff multiplier. - + - If true, list needs to be sorted. + [0, 1] percentage of damage to apply at damageFalloffMaxRange. - + - If true, MergeRules should be called before doing any filtering. + Seconds before physics projectile is destroyed. - + - If false, LoadWebUrls still needs to be called. + Is this gun setup to have a change of jamming? - + - For non-repeat weapons the "Use" audio clip is played once time reaches this point. + [0, 1] quality percentage that jamming will start happening. - + - If true, the server will replicate the event to clients. - Defaults to true. + [0, 1] percentage of the time that shots will jam the gun when at 0% quality. + Chance of jamming is blended between 0% at jamQualityThreshold and jamMaxChance% at 0% quality. - + - Catch exceptions to prevent a broken powerable from breaking all the other powerable items in the area. + Name of the animation to play when unjamming chamber. - + - Unsorted list of world space generators turned-on and fueled. + Movement speed multiplier while the gun is aiming down sights. - + - Allows Unity events to broadcast text chat messages from the server. + If >0, hammer animation plays after shooting this many shots after RechamberAfterShotDelay seconds pass. + Defaults to one for EAction.Pump and EAction.Bolt, zero otherwise. - + - Text to use when SendDefaultTextChatMessage is invoked. + If >0, emit particles after hammer after EjectAfterHammerDelay seconds pass. + Only applicable if RechamberAfterShotCount is >0. + Defaults to 1. - + - URL of a png or jpg image file to show next to the message. + If >0, emit particles after reloading after EjectAfterReloadDelay seconds pass. + Defaults to ammoMax for EAction.Break. - + - Text color when rich text does not override with color tags. + If true, emit particles when a shot is fired. + Defaults to true for EAction.Trigger and EAction.Minigun. - + + + Nelson 2025-04-09: this acted as both category AND behaviour modifier, so I'm separating it into a custom tag + for categorization and a property for overriding how the blueprint processes input items. + + Nelson 2025-04-10: repair and ammo "types" had a variety of quirks I wanted to sort out: + • Moving amount between items required ammo type blueprint, but some modders expressed interest in non-ammo use. + (I.e., ideally better supporting amount on non-ammo items going forward.) + • Both types ignored output items. Output was used to represent the target item. Similarly, the UI added a fake + extra input item representing target item. + • PlayerCrafting and PlayerDashboardCraftingUI re-implemented some crafting item searching logic for finding + the item to refill or repair that can be converted into input item parameters. + The plan at the moment is to make the last input item the "target" item for operations. Legacy ammo/repair + blueprints will then default to no output item and add an extra input item. (And add a variety of parameters + needed to replicate the specialized item search behaviour.) + + + - Should rich text tags be parsed? - e.g. bold, italic, color + Controls what blueprint does with input items. + Separated from EBlueprintType which acted as both category AND operation. - + - Allows Unity events to spawn vehicles. + No special modification to input items. - + - Recoil magnitude multiplier while the gun is aiming down sights. + Restore target input item to full quality. - + - Multiplier for gun's Aim_In_Duration. + Transfer amount from input items to target item. - + - For backwards compatibility this is *subtracted* from the gun's firerate, so a positive number decreases - the time between shots and a negative number increases the time between shots. + Seconds after placement before damage can be dealt. - + - Multiplier for normal bullet damage. + Seconds interval between damage dealt. + i.e., will not cause damage if less than this amount of time passed since the last damage. - + - Multiplier for bullet acceleration due to gravity. + Does this label fade out as the chat message gets older? - + - Movement speed multiplier while the gun is aiming down sights. + Chat message values to show. - + - If true, gun can damage entities with Invulnerable tag. Defaults to false. + Should only be used by . + For example: "Condition_##" where ## is an index. - + - Name to use when instantiating attachment prefab. - By default the asset guid is used, but it can be overridden because some - modders rely on the name for Unity's legacy animation component. For example - in Toothy Deerryte's case there were a lot of duplicate animations to work - around the guid naming, simplified by overriding name. + Nelson 2025-03-11: not *super* happy about having this in here. Needed for UI_Requirements. - + - Returns true if calibers list contains provided caliber ID. + Nelson 2025-03-11: not *super* happy about having this in here. Needed for UI_Requirements. - + - Returns true if calibers list contains any of the provided caliber IDs. + If set, only show this condition in the UI when conditions with these indices are met. + For example don't show "arrest the criminal (name)" until "investigate crime" is completed. - + - Note: If barricade is attached to a vehicle this is the local rotation. + Is this condition influenced by a given quest flag? + Used by level objects to determine if local player's flag change may affect visibility. - + - Extensions to the built-in Physics class. - - Shares similar functionality to the SDG.Framework.Utilities.PhysicsUtility class, but that should be moved here - because the "framework" is unused and and the long name is annoying. + Replacement for isAssociatedWithFlag to fix quest conditions and somewhat improve perf. - + - Wrapper that respects landscape hole volumes. + Intended to replace filling data from constructor. - + - Wrapper that respects landscape hole volumes. + Intended to replace filling data from constructor. Legacy is for backwards compatibility with Condition_#_Key + format, whereas V2 uses the list and dictionary features. - + - Wrapper that respects landscape hole volumes. + Hack to prevent hitting volume rate limit because (at least as of 2022-05-24) we do not have an event for finished dragging. - + - Wrapper that respects landscape hole volumes. + Hide existing icon until refresh. + Experimented with doing this for every refresh, but it looks bad in particular for hotbar. - + - Button in a list of levels. + Tree activation is time-sliced, so this does not necessarily match whether the region is active. - + - Button in the list of levels for server browser filters. + Can this tree be damaged? + Allows holiday restrictions to be taken into account. (Otherwise holiday trees could be destroyed out of season.) - + - Button in the list of levels for the map editor. + When adding or removing entries remember to update NetMessages size and regenerate NetCode! - + - Base class for IMGUI implementations of primitive building block widgets. + Server sent a ping. - + - Position passed into the GUI draw methods. + Server replying to our ping. - + - Hashes for Windows, Linux, and Mac asset bundles. - Only loaded on the dedicated server. Null otherwise. + Server is shutting down shortly. - + - Does given hash match any of the platform hashes? + Create game object for player. - + - Compares client asset bundle hash with server known hashes. + Destroy game object for player. - + - Called by asset startup to cache which bundles are eligible for hashing. + Download these files before loading the level. - + - Used in a test scene to quickly test all Glazier features. + Server wants additional info before accepting us. - + - Reference type for testing SleekList. + Server has accepted us and will create a player game object. - + - Uses the Win32 API to force a console to be created and destroyed. + Server rejected us, we will go back to the menu. - + - Should we manually create and destroy a Win32 console? - Useful for IO on Windows desktop, but not as much for dedicated machines. + Banned either during connect or gameplay. - + - Allocate Windows console if enabled. + Kicked during gameplay. - + - Free Windows console if enabled. + Should be converted to an RPC. Leftover from prior to net messaging code. - + - A CTRL+C signal was received, either from keyboard input or from a signal generated by the GenerateConsoleCtrlEvent function. + Should be converted to an RPC. Leftover from prior to net messaging code. - + - A CTRL+BREAK signal was received, either from keyboard input or from a signal generated by GenerateConsoleCtrlEvent. + Server sending BattlEye payload to client. - + - A signal that the system sends to all processes attached to a console when the user closes the console - (either by clicking Close on the console window's window menu, or by clicking the End Task button command from Task Manager). + Infrequent notification of queue position. - + - Tracks whether we should show the "NEW" label on listings and item store button. + Server calling an RPC. - + - Track that player has seen the new crafting blueprints. + Enumerate elements that are not in the pool. - + - Track that player has seen the page with all new listings. + Sanity check all returned elements have a gameObject. - + - Has player seen the given listing? + Allows Unity events to call in airdrops. - + - Track that the player has seen the given listing. + If set, this item is prioritized over equipped cosmetics. Used by item inspect menu. + Admittedly, this is very hacked-together. Hopefully rewriting this file someday? - + - Absolute path to directory containing bundle and .dat file. + Is cosmetic or skin equipped? - + - Name of the actual asset bundle file, e.g. Hawaii.unity3d - Asset bundle should be next to this config file. + Get SteamID of vehicle's driver, or nil if not driven. - + - assetBundleName without final .* extension. + Crashed into something, if applicable take self damage from collision. - + - Prefixed to all asset paths loaded from asset bundle. - Final path is built from assetPrefix + pathRelativeToBundlesFolder + assetName, - e.g. Assets/Hawaii/Bundles + /Objects/Large/House/ + Object.prefab + Read commands from standard input, and write logs to standard output. - + - Custom asset bundle version used by Unturned to detect whether imports need - fixing up because they were exported from an older version of Unity. + Each Update we consume a key press from the console buffer if available. + Unfortunately ReadLine is not an option without blocking output, so we maintain our own pending input. - + - Get absolute path to asset bundle file. + Maps region coord to a list of sub-road renderers in that region. + Unlike older "region" features, coord can be outside of the old bounds. + Not used in the editor or the dedicated server. - + - Get absolute path to file with per-platform hashes. + Max draw distance outside editor. - + - Insert path prefix if set. + Called by navmesh baking to complete pending object changes that may affect which nav objects are enabled. - + - When to use this instead of formatAssetPath? MasterBundleReference and AudioReference repeatedly invoke - this string formatting (e.g., footstep sounds) and benefit from not generating that garbage. + Extra text added to tooltip. - + - Loaded asset bundle. + Merging the devkit, legacy, and housing transform handles into one place. - + - Hash of loaded asset bundle file. - This is per-platform, so the server loads a hash file with all platform hashes. + Position and plane handles for each axis. - + - True if the server .hash file exists. - Hash file is not used by client, but client uses whether it exists to decide whether to include asset bundle hash in asset hash. + Disc handles for each axis. - + - Hashes for Windows, Linux, and Mac asset bundles. - Only loaded on the dedicated server. Null otherwise. + Scale handles for each axis. - + - On the surface level this is rather silly. - The primary reason for it is reducing garbage created by repeated calls to formatAssetPath. - Theoretically we could use this for caching redirected paths if/when that feature is added. + Position handles on each side of box. - + - Load the underlying asset bundle. + Scale handles on each side of box which both move and resize the box. - + - If true, the associated asset bundle couldn't be loaded and was instead copied from another config. + Invoked when handle is clicked so that tool can save selection transform relative to pivot. + This avoids floating point precision loss of applying delta for each Transformed event. - + - If the type name has been redirected this method will be called recursively until the most recent name is found and returned. + Invoked when handle is dragged and value actually changes. - + - After the key "limit" is loaded we stop reading. + Invoked when handle is dragged and value actually changes. - + - Path to the folder which contains the Unity player executable. + Preferred mode only takes effect while not dragging. + Bounds modes fall back to non-bounds modes if bounds are not set. - + - Called by loading after landscapes (and legacy conversion) have been loaded. + Pivot only takes effect while not dragging. This is to help ensure + the caller does not depend on the internal pivot values. - + - True is solid and false is empty. + Somewhat hacky, useful to make the "copy-paste transform" feature easier to implement. + Invoke tranformed callback as if pivot were manually dragged to the new position and rotation. - + - Marked true when level editor or legacy hole volumes modify hole data. - Defaults to false in which case holes do not need to be saved. - - Initially this was not going to be marked by hole volumes because they can re-generate the holes, but saving - hole volume cuts is helpful when upgrading to remove hole volumes from a map. + Called before raycasting into the regular physics scene to give transform tool priority. - + - If true, SetHeightsDelayLOD was called without calling SyncHeightmap yet. + Update properties that depend on the transform of the camera relative to our handles. - + - If true, SetHolesDelayLOD was called without calling SyncTexture yet. + Center of handle. - + - Heightmap-only data used in level editor. Refer to Landscape.DisableHoleColliders for explanation. + Rotation of handle. - + - Call this when done changing material references to grab their textures and pass them to the terrain renderer. + True if pivotBounds is non-zero. - + - If a heightmap coordinate is out of bounds the tile/heightamp coordinate will be adjusted so that it is in bounds again. + Mouse currently over this handle. - + - If a splatmap coordinate is out of bounds the tile/splatmap coordinate will be adjusted so that it is in bounds again. + Mouse currently dragging this handle. - + - Hacky workaround for height and material brushes in editor. As far as I can tell in Unity 2019 LTS there is no method to ignore - holes when raycasting against terrain (e.g. when painting holes), so we use a duplicate TerrainData without holes in the editor. + Direction from camera toward pivot. - + - Is point (on XZ plane) inside a masked-out pixel? + Multiplier according to distance between camera and pivot to keep handles a constant on-screen size. - - If the highest weight layer is ignoreLayer then the next highest will be returned. - - - If the highest weight layer is ignoreLayer then the next highest will be returned. - - + - Appends heightmap vertices to points list. + Multiplier to flip axis handles according to which side the camera is on. - + - Appends heightmap vertices to points list. + Pivot rotation when rotation drag started. - + - Call this after you're done adding new tiles. + Rotating around this axis. - + - Call this to sync a new tile up with nearby tiles. + Direction from circle center to edge point. - + - Capturing ortho view of map, so we raise the terrain to max quality. + Point on the edge of the circle. - + - Finished capturing ortho view of map, so we restore the terrain to preferred quality. + Drag along this tangent to the circle. - + - Nelson 2025-03-10: I want to experiment whether this fixes a strange terrain hole painting bug (public issue - #4851) without potentially introducing crashes for other players. (Per an earlier, undated comment we'd - run into a SetHolesDelayLOD-related crash in 2019 LTS.) + If true then level should convert old node types to volumes. - + - Directly blend current value toward target value. + If true then level should convert old non-volumes types to devkit objects. - + - Only blend current value toward target value if current is greater than target. + Hash of nodes file. + Prevents using the level editor to make noLight nodes visible. - + - Only blend current value toward target value if current is less than target. + Remove any existing item alert widgets. - + - If true, write to LevelHierarchy file. - False for externally managed objects like legacy lighting WaterVolume. + Open fullscreen alert showcasing newly granted items. + Uses first item for title color, so items should be sorted by priority. - + - If true, editor tools can select and transform. - False for items like the object-owned culling volumes. + Open fullscreen alert showcasing newly granted items. - + - Hold onto collider and gameobject separately because collider isn't necessarily attached to gameobject. + Handle esc/back key press. + Still really messy, but this used to be inside a huge nested if/elseif in Update. - + - Volume doesn't override fog. + Despite being newer code, this is obviously not ideal. Previously the news request was using the Steam HTTP + API which might have been the cause of some crashes, so it was quickly converted to Unity web request instead. - + - Volume fog settings are the same at all times of day. + Can be added to any GameObject to receive weather events: + - Day/Night + - Full Moon + - Rain + - Snow - + - Volume fog settings vary throughout the day. + Invoked when night changes to day. - + - Kept because lots of modders have been using this script in Unity, - so removing legacy effect id would break their content. + Invoked when day changes to night. - + - If per-weather mask AND is non zero the weather will blend in. + Invoked when a zombie full-moon event starts. - + - Kept for backwards compatibility with fog volumes created in Unity / by mods. + Invoked when a zombie full-moon event finishes. - + - Distinguishes from zero falloff which may be useful deep in a cave. + Invoked when rain starts to fall. - + - Higher priority volumes override lower priority volumes. + Invoked when rain finishes falling. - + - When falloff is OFF, how long to fade in audio by time. + Invoked when snow starts to fall. - + - When falloff is OFF, how long to fade out audio by time. + Invoked when snow finishes falling. - + - When falloff is OFF, how long to fade in audio by time. + String table specifically for Unity physics material names. + Implemented so that tires can more efficiently replicate which ground material they are touching. - + - When falloff is OFF, how long to fade out audio by time. + Get an ID that can be used to reference a physics material name over the network. If given material name + isn't supported (e.g., not registered in a PhysicsMaterialAsset or over max material limit) returns + instead. - + - When falloff is OFF, how long to fade in lighting by time. + Get name of a physics material from network ID. Returns null if ID is null, e.g., if the sent name wasn't + registered or was over the max material limit. - + - When falloff is OFF, how long to fade out lighting by time. + Called when resetting network state. - + - Used by lighting to get the currently active effect. + Called on server and singleplayer before loading level. - + - Open a new transaction group which stores multiple undo/redoable actions, for example this would be called before moving an object. + Number of bits needed to replicate PhysicsMaterialNetId. - + - Close the pending transaction and finalize any change checks. + Component in the root Menu scene. + Additively loads decoration levels without modifying main scene. - + - Clear the undo/redo queues. + Prevents static member from being initialized during MonoBehaviour construction. (Unity warning) - + - If false this transaction is ignored. If there were no changes at all in the group it's discarded. + Unfortunately EditorPrefs cannot be used in constructor. - + - Called when history buffer is too long so this transaction is discarded. + If Unturned is loading this asset bundle from a Steam workshop file but the file ID does not match then + loading will be canceled. Makes it somewhat harder to copy/re-upload without permission. - + + + Same as ownerWorkshopFileId for cases where the asset bundle is allowed in multiple uploads. + + Uploading the same asset bundle multiple times is not ideal because the game doesn't handle + multiple of them with the same name well, and Unity logs an error if an asset bundle with the + same files is already loaded. That being said, the game doesn't handle dependencies between + workshop files well either (as of 2023-01-12), so this is perhaps the lesser of two evils. + + My understanding is that some mod creators license their work to multiple servers that upload + the files and this property will make it easier so it doesn't need to be re-exported multiple times. + + + - Save the state of all the fields and properties on this object to the current transaction group so that they can be checked for changes once the transaction has ended. + If set, we are responsible for destroying texture. - + - Kept because lots of modders have been using this script in Unity, - so removing legacy effect id would break their content. + Is a point safely within the level bounds? + Also checks player clip volumes if legacy borders are disabled. - + - Called when we position, rotate or scale this transform. + Is given Y (vertical) coordinate within level's height range? + Maps using landscapes have a larger range than older maps. - - Identical to this object. + + + Notify menus that levels list has changed. + Used when creating/deleting levels, as well as following workshop changes. + - + - Devkit objects are now converted to regular objects and excluded from the file when re-saving. + Initialized along with level asset. - + - Hacked to check horizontal distance. + Get level's cached asset, if any. - + - Nelson 2024-06-10: Changed this from guid to string because Unity serialization doesn't support guids - and neither does the inspector. (e.g., couldn't duplicate reward volume without re-assigning guid) + Should loading code proceed with redirects? + Disabled by level and when in the editor. - + - If true, vehicles overlapping volume will check conditions and (if met) grant rewards to passengers. + Placeholder created between unloading the main menu and loading into game or editor. - + - ModuleHook looks for module entry/exit points, then calls when enabled and when disabled. + Loading screen music. - + - Register components of this module. + Clip to play to fade out loop. - + - Cleanup after this module. + Useful to narrow down why a player is getting kicked for modified level files when joining a server. - + - Holds module configuration. + Display version string of the currently loaded level. - + - Whether to load assemblies. + Version string of the currently loaded level packed into an integer. - + - Directory containing Module file, set when loading. + Refreshes known levels and attempts to redirect level reference if it no longer exists. - + - Path to the Module file, set when loading. + Find level matching both name AND workshop file ID (can be zero). - + - Used for module dependencies. + Load level details from Level.dat in directory path. - + - Nicely formatted version, converted into . + Server list allows player to enter a map name when searching, so we try to find a local + copy of the level for version number comparison. (Server map version might differ.) - + - Used for module dependencies. + New map filter uses lowercase map name and doesn't need startswith. - + - Modules that must be loaded before this module. + Search all map folders to add any previously unregistered maps. - + - Relative file paths of .dlls to load. + May be out of date by one frame. - + - Wraps module assembly and handles initialization. + Currently used by vehicles to deactivate some rendering features when outside rendering distance. + Uses "frozen" position if applicable, otherwise the camera position from the most recent Update. This means + it could be out-of-date, but for LOD purposes it should be "good enough." - + - True when config is enabled and dependencies are enabled. + Horizontal distance before road begins tapering off into the terrain. - + - Metadata. + Size along the "up" axis. - + - Assembly files loaded. + Distance along the terrain surface normal to move each road vertex. - + - Types in the assemblies of this module. Refer to this for types rather than the assemblies to avoid exception and garbage. + Multiplier for how far along the road before texture repeats. - + - How far along the initialization to shutdown lifecycle this module is. + Defaults to None, in which case the backwards-compatible chart classification is used. - + - Runs before everything else to find and load modules. + Physics material to assign to road colliders. + Replaces the "concrete" toggle in the older editor. - + - Temporarily contains Unturned's code untils it's moved into modules. + Manages render queue for transparent materials on non-stationary objects. + Updates one material per frame. - + - Temporarily contains types. + Callback when camera above/under water changes. - + - Should module assemblies be loaded? + Directory the game files are installed in. For the editor this is the /Builds/Shared directory. + Windows and Linux: contains the executable and the Unturned_Data directory. + MacOS: contains the Unturned.app bundle. - + - Called once after all startup enabled modules are loaded. Not called when modules are initialized due to enabling/disabling. + Item ID of barricade to spawn after landing. - + - Called once after all modules are shutdown. Not called when modules are shutdown due to enabling/disabling. + Barricade to spawn after landing. - + - Find modules containing an assembly with the Both_Required role. + Cargo spawn table legacy ID. - Modules to append to. - + - Find module using dependency name. + Kill any players inside the spawned interactable box. + Uses hardcoded size of 4 x 4 x 4. - - + - These are *.dll files discovered in the modules folder. + Called from the server to override salvage duration. + Only used by plugins. - + - Should missing DLLs be logged? - Opt-in because RocketMod has its own handler. + Override salvage duration without admin. + Only used by plugins. - + - Should vanilla search for *.dll files? - Can be turned off in case it conflicts with third-party search mechanism. + Outlined object is not necessarily the focused object, so we track it to disable later if focus is destroyed. - + - If set, search for .dll and .module files in this directory instead of in Unturned/Modules. + Search up hierarchy for most specific Target transform. - + - Event for plugin frameworks (e.g., Rocket) to override AssemblyResolve handling. + Was focus non-null during last update? Used to detect when focus was destroyed. - + - Depending on the platform, assemblies are found in different directories. + If updating this method please remember to update the support article: + https://support.smartlydressedgames.com/hc/en-us/articles/13452208765716 - Root folder for modules. - + - Search Modules directory for .dll files and save their AssemblyName to discoveredNameToPath. + Does name contain rich text tags? + Some players were abusing rich text enabled servers by inserting admin colors into their steam name. - + - Search Modules directory for .module files and load them. + Only set in play mode for determing if we should cache brute force lengths. - + - Orders configs by dependency and removes those that are missing files. + If set, road properties are taken from this asset instead of the older road properties editor. - + - Sorts modules by dependencies. + Not using rate limit attribute because this is potentially called for hundreds of structures at once, + and only admins will actually be allowed to apply the transform. - + - Nicely formatted version, converted into . + See BarricadeRegion.FindBarricadeByRootFast comment. - + - Used for module dependencies. + For code which does not know whether transform exists and/or even is part of a house. + See BarricadeRegion.FindBarricadeByRootFast comment. - + - Requested by Trojaner. LoadFile locks the file while in use which prevents OpenMod from updating itself. + Steam APIs returned uint32 IPv4 addresses in the past, so Unturned code depends on them in some places. + Ideally these uses should be updated for IPv6 support going forward. + For the meantime this method converts from the new format to the old format for backwards compatibility. - + - Equivalent to MonoBehaviour.Update + Nelson 2025-02-24: Warning that this is invoked *before* the item is actually removed from the items list. + (public issue #4894) - + + checks whether a space contains any filled slots + + + checks whether an item can be dragged and takes into account if the item overlaps its old self + + - Equivalent to MonoBehaviour.FixedUpdate + checks whether the spot currently used by the old item is big enough to fit the new item - + - Useful when caller is not a MonoBehaviour, or coroutine should not be owned by a component which might get - deactivated. For example attached effects destroy timer should happen regardless of parent deactivation. + Please use SearchContents instead! To perform an equivalent search: + • Set ItemType to type. + • Set IncludeEmpty to false. + • Set IncludeMaxQuality to true. - + - Stop a coroutine started by InvokeAfterDelay. + Please use SearchContents instead! To perform an equivalent search: + • Set ItemType to type. + • Set IncludeEmpty to false. + • Set IncludeMaxQuality to true. + • Set CaliberId to caliber. + • Set IncludeUnspecifiedCaliber to allowZeroCaliber. - + - For use with PoolablePool when no special construction is required. + Please use SearchContents instead! To perform an equivalent search: + • Set AssetRef to id. + • Set IncludeEmpty to findEmpty. + • Set IncludeMaxQuality to findHealthy. - + - Called when this instance is getting claimed. + Please use SearchContents instead! To perform an equivalent search: + • Set MaxResultsCount to 1. + • Set AssetRef to id. + • Set IncludeEmpty to false. + • Set IncludeMaxQuality to true. - + - Called when this instance is returned to the pool. + Find client with given RPC channel ID. - + - Number of items in underlying queue. + Remaps asset load requests into a large asset bundle rather than small individual asset bundles. - + - Pool of objects that implement the IPoolable interface. - - Useful for types that do not need special construction, - and want notification when claimed and released. + Config that contains the actual large AssetBundle. - + - Not necessarily cheap to calculate - probably best to cache. + Asset path relative to the master AssetBundle. - + - Internal cubic meter volume. + Note: inventory service does not support exchanging multiple items simultaneously. - + - Surface square meters area. + 2023-01-25: fixing killing self with explosive to track kill under + the assumption that this is only used for tracking stats. (public issue #2692) - + - Nelson 2024-11-11: Collider may have been destroyed by an unexpected mod script configuration (or perhaps - simply missing in the first place). Should fix/prevent public issue #4749. + Exposes the same API as the older Block class used by existing netcode, but implemented using new bit reader/writer. - + - Replacement foliage storage with all tiles in a single file. - - In the level editor all tiles are loaded into memory, whereas during gameplay the relevant tiles - are loaded as-needed by a worker thread. + Get net ID only if transform is directly registered, not if transform is the child of a registered transform. - + - Entry point for worker thread loop. + Log every registered pairing. - + - Order is important because TileBecameRelevant is called from the closest tile outward. + Called before loading level. - + - Offsets into blob for per-tile data. + Reverse pairing specifically for building net id + relative path name. - + - Tiles save an index into this list rather than guid. + Interface between the dedicated server command I/O and per-platform console. - + - Offset from header data. + Called when this implementation is setup by command window. - + - Data-only FoliageInstanceList shared between threads. + Called when this implementation is deleted or application quits. - + - Data-only FoliageTile shared between threads. + Called each Unity update. - + - Ready to be released to the worker thread during the next lock. + Broadcasts when the enter key is pressed. - + - Mutex lock. Only used in the main thread Update loop and worker thread loop. + Print white message. - + - SHARED BY BOTH THREADS! - Coordinates requested by main thread for worker thread to read. - This is a list because while main thread is busy the worker thread can continue reading. + Print yellow message. - + - SHARED BY BOTH THREADS! - Tiles read by worker thread ready to be copied into actual foliage tiles on main thread. + Print red message. - + - SHARED BY BOTH THREADS! - Main thread has finished using this tile data and it can be released back to the pool on the worker thread. - This is a list because main thread could have populated multiple foliage tiles while the worker thread was busy reading. + Export JSON report of Unturned's assets for economy usage. - + - Lifecycle: - 1. Worker thread claims or allocates data. - 2. Worker thread passes data to main thread. - 3. Main thread copies data over to actual foliage tile. - 4. Main thread passes data back to worker thread. - 5. Worker thread releases data back to pool. + If true, contains child transform named Effect for mythical attachment. - + - Does this tile contain any placed foliage? + Attachment item IDs that get skinned specially. - + - If true, mesh is not loaded when clutter is turned off in graphics menu. - Defaults to false. + Is there a fallback material for attachments that respects their main metallic areas? - + - Foliage to use during the Christmas event instead. + Is there a fallback material without any special features? - + - Foliage to use during the Halloween event instead. + Is there a replacement mesh? - + - Get asset ref to replace this one for holiday, invalid to disable, or null if it should not be redirected. + Dawn and dusk skins pull per-lighting colors. - + - Responsible for reading and writing persistent foliage data. + Extensions to the built-in Physics class. + + Shares similar functionality to the SDG.Framework.Utilities.PhysicsUtility class, but that should be moved here + because the "framework" is unused and and the long name is annoying. - + - Called after creating instance for level, prior to any loading. - Not called when creating the auto-upgrade instance for editorSaveAllTiles. + Wrapper that respects landscape hole volumes. - + - Called prior to destroying instance. + Wrapper that respects landscape hole volumes. - + - Called when tile wants to be drawn. + Wrapper that respects landscape hole volumes. - + - Called when tile no longer wants to be drawn. + Wrapper that respects landscape hole volumes. - + - Called during Unity's Update loop. + Invoked when timer expires. - + - Load known tiles during level load. + Number of seconds to use when SetDefaultTimer is invoked. - + - Save tiles during level save. + Should timer loop when SetDefaultTimer is invoked? - - Should angle limits and subtractive volumes be respected? Disabled when manually placing individually. - If true, trees do a sphere overlap to prevent placement inside objects. - - + - Pick a point inside the bounds to test for foliage placement. The base implementation is completely random, but a blue noise implementation could be very nice. + Stop pending timer from triggering. - + - Legacy implementation of foliage storage, with one file per tile. + Handle to stop the coroutine. - - True if other IFoliageSurface methods can be called. - - + - Settings configured when starting the bake. + If using a map or mods from the workshop, this class monitors them for changes so the server can be restarted. - + - Implementation of tile data storage. + Request status of workshop items. - + - Nelson 2025-04-22: instanced foliage rendering is a decent chunk of CPU time. In retrospect this seems like - an obvious optimization: Graphics.DrawMeshInstanced accepts up to 1023* instances per call. Each tile - groups instances in lists of up to 1023*, but often isn't that high. Now, we collect instances until we - hit the 1023* limit. This is particularly useful for sparse variants like colored flowers. - With a consistent camera transform ("/copycameratransform") on an upcoming map remaster I went from between - 0.72-0.8 ms on my PC to 0.55-0.6 ms! - *Nelson 2025-07-14: refer to NON_UNIFORM_SCALE_INSTANCES_PER_BATCH. + Called the next tick after update(s) detected. - + - 2022-04-26: drawTiles previously looped over a square [-N, +N] from the upper-left to the bottom-right, - and each tile checked radial distance. We can improve over this by pre-computing the radial offsets and - starting from the center to improve responsiveness. N is [1, 5] + Called when a queried item's update timestamp is newer than our initially loaded version. - - + - Nelson 2025-07-14: although Graphics.DrawMeshInstanced accepts 1023 instances, it will split them into max - batches of [1, 511, 511] if shader does not have: #pragma instancing_options assumeuniformscaling - So, we might as well do our own splitting of batches to avoid batches of 1. + Called when results from a call to submitQueryRequest are available. - - Must be within [0, MAX_MATRICES_PER_BATCH] range. - - + - Version number associated with this particular system instance. + Called once timer reaches interval. - + - Automatically placing foliage onto tiles in editor. + Were update(s) detected that should be handled on next tick? - + - 2022-04-26: this used to be environment layer, but "scope focus foliage" can draw outside that render distance - so we now use the sky layer which is visible up to the far clip plane. + Are we done monitoring? + Default finished once an update is detected. - + - Whether add can be called from the inspector. + Interval between query submissions. - + - Whether remove can be called from the inspector. + Accumulated time before submitting query after passing interval. - + - Called when the inspector adds an element. + Callback from Steam when results from a call to submitQueryRequest are available. - + - Called when the inspector removes an element. + Almost every menu has a container element for its contents which spans the entire screen. This element is then + animated into and out of view. In the IMGUI implementation this was fine because containers off-screen were not + processed, but with uGUI they were still considered active. To solve the uGUI performance overhead this class + was introduced to disable visibility after animating out of view. - + - Called when the inspector sets an element to a different value. + Experience to add or subtract when used. Defaults to zero. - + - Whether add can be called from the inspector. + Canned beans have skins from April Fools. - + - Whether remove can be called from the inspector. + Some new code common to SteamPending and SteamPlayer. - + - All water tiles and the planar reflection component reference this material. + Realtime the first ping request was received. - + - If true rain will be occluded below the surface on the Y axis. + Number of ping requests the server has received from this client. - + - Flag for legacy sea level. + Called when a ping request is received from this client. - + - Water volume marked as being sea level. + Realtime passed since the first ping request was received from this client. - - Null if under old water level, otherwise the volume. + + + Average number of ping requests received from this client per second. + Begins tracking 10 seconds after the first ping request was received, or -1 if average is unknown yet. + - + - Find the water elevation underneath point, or above point if underwater. + Only set on server. Associates player with their connection. - + - Reads data into the data array. + Used when kicking player in queue to log what backend system might be failing. - The file path to read from. - The array to read into. - Whether the read succesfully executed. - + - Writes data out of data array. + View a package on the store. - The file path to write to. - The array to write from. - The length of the array with data. - Whether the write succesfully executed. + Package to view. - + - Checks the size of a file. + Information about currently connected server. - The file path to check. - The size of the file. - Whether the check succesfully executed. - + - Checks whether the path already exists. + Whether a server is currently connected to. - The file path to check. - Whether the file exists. - Whether the check succesfully executed. - + - Deletes the path. + Whether connection attempts are being made. - The file path to delete. - Whether the deletion succesfully executed. - + - For once the provider interface actually came in useful! - Fakes loading the Steam remote storage files from a separate folder. + Network buffer memory stream. - + - Triggered when the user's statistics are available. + Network buffer memory stream reader. - + - Checks the current user's statistics with this name. + Network buffer memory stream writer. - The name of the statistic. - The value of the statistic. - Whether the check succesfully executed. - + - Assigns the current user's statistics with this name. + Connect to a server. - The name of the statistic. - The value of the statistic. - Whether the check succesfully executed. + Server to join. - + - Checks the current user's statistics with this name. + Disconnect from current server. - The name of the statistic. - The value of the statistic. - Whether the check succesfully executed. - + - Assigns the current user's statistics with this name. + Receive a packet from an entity across the network. - The name of the statistic. - The value of the statistic. - Whether the check succesfully executed. + Sender of data. + + + Whether any data was read. - + - Requests the user's statistics. + Send a packet to an entity across the network. - Whether the refresh succesfully executed. + Recipient of data. + Packet to send. + Size of data in array. - + - Triggered when the global statistics are available. + Send a packet to an entity across the network. + Recipient of data. + Packet to send. + Size of data in array. + Type of send to use. - + - Checks the global total of the statistic with this name. + Current client multiplayer implementation. - The name of the statistic. - The value of the statistic. - Whether the check succesfully executed. - + - Checks the global total of the statistic with this name. + Current server multiplayer implementation. - The name of the statistic. - The value of the statistic. - Whether the check succesfully executed. - + - Requests the global statistics. + Information about currently hosted server. - Whether the refresh succesfully executed. - + - Current user statistics implementation. + Whether a server is open. - + - Current global statistics implementation. + Network buffer memory stream. - + - Current client multiplayer implementation. + Network buffer memory stream reader. - + - Current server multiplayer implementation. + Network buffer memory stream writer. - + - Information about currently connected server. + Open a new server. - + - Whether a server is currently connected to. + Close an existing server. - + - Whether connection attempts are being made. + Receive a packet from an entity across the network. + Sender of data. + + + Whether any data was read. - + - Network buffer memory stream. + Send a packet to an entity across the network. + Recipient of data. + Packet to send. + Size of data in array. - + - Network buffer memory stream reader. + Send a packet to an entity across the network. + Recipient of data. + Packet to send. + Size of data in array. + Type of send to use. - + - Network buffer memory stream writer. + Triggered when the user's statistics are available. - + - Connect to a server. + Checks the current user's statistics with this name. - Server to join. + The name of the statistic. + The value of the statistic. + Whether the check succesfully executed. - + - Disconnect from current server. + Assigns the current user's statistics with this name. + The name of the statistic. + The value of the statistic. + Whether the check succesfully executed. - + - Receive a packet from an entity across the network. + Checks the current user's statistics with this name. - Sender of data. - - - Whether any data was read. + The name of the statistic. + The value of the statistic. + Whether the check succesfully executed. - + - Send a packet to an entity across the network. + Assigns the current user's statistics with this name. - Recipient of data. - Packet to send. - Size of data in array. + The name of the statistic. + The value of the statistic. + Whether the check succesfully executed. - + - Send a packet to an entity across the network. + Requests the user's statistics. - Recipient of data. - Packet to send. - Size of data in array. - Type of send to use. + Whether the refresh succesfully executed. - + - Information about currently hosted server. + Triggered when the global statistics are available. - + - Whether a server is open. + Checks the global total of the statistic with this name. + The name of the statistic. + The value of the statistic. + Whether the check succesfully executed. - + - Network buffer memory stream. + Checks the global total of the statistic with this name. + The name of the statistic. + The value of the statistic. + Whether the check succesfully executed. - + - Network buffer memory stream reader. + Requests the global statistics. + Whether the refresh succesfully executed. - + - Network buffer memory stream writer. + Current user statistics implementation. - + - Open a new server. + Current global statistics implementation. - + - Close an existing server. + Whether the user has their overlay enabled. - + - Receive a packet from an entity across the network. + Initialize this service's external API. Should be called before using. - Sender of data. - - - Whether any data was read. - + - Send a packet to an entity across the network. + Update this service's external API. Should be called every frame. - Recipient of data. - Packet to send. - Size of data in array. - + - Send a packet to an entity across the network. + Shutdown this service's external API. Should be called before closing the program. - Recipient of data. - Packet to send. - Size of data in array. - Type of send to use. @@ -20794,60 +21178,70 @@ Item amounts to be generated. Called when the exchange is completed. - - - Whether the user has their overlay enabled. - - - + - View a package on the store. + For once the provider interface actually came in useful! + Fakes loading the Steam remote storage files from a separate folder. - Package to view. - + - Checks whether the current user has an achievement with this name. + Reads data into the data array. - The name of the achievement. - Whether the user has this achievement. - Whether the check succesfully executed. + The file path to read from. + The array to read into. + Whether the read succesfully executed. - + - Assigns the current user an achievement with this name. + Writes data out of data array. - The name of the achievement. - Whether the assignment succesfully executed. + The file path to write to. + The array to write from. + The length of the array with data. + Whether the write succesfully executed. - + - Whether the user has their overlay enabled. + Checks the size of a file. + The file path to check. + The size of the file. + Whether the check succesfully executed. - + - Initialize this service's external API. Should be called before using. + Checks whether the path already exists. + The file path to check. + Whether the file exists. + Whether the check succesfully executed. - + - Update this service's external API. Should be called every frame. + Deletes the path. + The file path to delete. + Whether the deletion succesfully executed. - + - Shutdown this service's external API. Should be called before closing the program. + Checks whether the current user has an achievement with this name. + The name of the achievement. + Whether the user has this achievement. + Whether the check succesfully executed. - + - Used to show a warning when a lot of servers are blocked by curation list. + Assigns the current user an achievement with this name. + The name of the achievement. + Whether the assignment succesfully executed. - + - Reset after starting connection attempt, so set to true afterwards to auto join the server. + Whether the user has their overlay enabled. @@ -20867,24 +21261,6 @@ from lowest rarity to highest rarity and should match entries in quality. - - - Response data from IInventoryService GetInventory web API. - - One player's inventory became so large that the Steam client's built-in GetInventory fails, - so as temporary fix we can send them a json file with their inventory. - - - - - Json string representation of the contained items. - - - - - Parse response from json file. - - Details of a workshop item that the game may want to refer to later. @@ -20904,7 +21280,7 @@ - Some workshop thieves use an empty title, in which case we show the file ID as title text. + Some workshop copyright infringers use an empty title, in which case we show the file ID as title text. @@ -21035,105 +21411,34 @@ Called when subscribed items callback was successful to register all compatible files. - - - Called when subscribed items callback did not execute as expected, - maybe because steam's servers are offline. In this case we can't check - compatibility so we register all the locally subscribed items as compatible. - - - - - Register any localization-type workshop content before waiting for the steam callbacks. - Important so that localizations are available for loading screens and whatnot during startup. - Any items we register now will be skipped later. - - - - - If specified, player's workshop file subscriptions are not registered at startup. - - - - - Map of subscriptions added/removed by the player through the in-game client API, as opposed to the web browser. - - - - - Called by us when we subscribe to an item from in-game. - If item already exists on-disk steam doesn't always call onItemInstalled, so we do our own check and potentially load. - - - - - Current achievements implementation. - - - - - Current browser implementation. - - - - - Current cloud implementation. - - - - - Current community implementation. - - - - - Current economy implementation. - - - - - Current matchmaking implementation. - - - - - Current multiplayer implementation. - - - - - Current statistics implementation. - - - - - Current store implementation. - - - + - Current translation implementation. + Called when subscribed items callback did not execute as expected, + maybe because steam's servers are offline. In this case we can't check + compatibility so we register all the locally subscribed items as compatible. - + - Current workshop implementation. + Register any localization-type workshop content before waiting for the steam callbacks. + Important so that localizations are available for loading screens and whatnot during startup. + Any items we register now will be skipped later. - + - Initialize this provider's external API. Should be called before using provider features. + If specified, player's workshop file subscriptions are not registered at startup. - Thrown if initializing fails. - + - Update this provider's external API. Should be called every frame if using provider features. + Map of subscriptions added/removed by the player through the in-game client API, as opposed to the web browser. - + - Shutdown this provider's external API. Should be called before closing the program if using provider features. + Called by us when we subscribe to an item from in-game. + If item already exists on-disk steam doesn't always call onItemInstalled, so we do our own check and potentially load. @@ -21261,51 +21566,108 @@ Not called on dedicated server. - + + + Response data from IInventoryService GetInventory web API. + + One player's inventory became so large that the Steam client's built-in GetInventory fails, + so as temporary fix we can send them a json file with their inventory. + + + - Implementing as a struct wrapping the connection handle would remove the cost of looking up the connection, - but implementing as a class makes it cheap to cache information like the remote identity. + Json string representation of the contained items. - + - Find game connection associated with Steam connection. + Parse response from json file. - + - Must close the handle to free up resources. + Current achievements implementation. - + - Must close the handle to free up resources. + Current browser implementation. - + - Defaults to true. If false, skip Steam Networking Sockets creation of regular IP socket. + Current cloud implementation. - + - Defaults to true. If false, skip Steam Networking Sockets creation of non-FakeIP P2P socket. - (this is the socket used by "server codes") + Current community implementation. - + - Must close the handle to free up resources. + Current economy implementation. - + - Must close the handle to free up resources. + Current matchmaking implementation. - + - Recycled array for every read call. + Current multiplayer implementation. + + + + + Current statistics implementation. + + + + + Current store implementation. + + + + + Current translation implementation. + + + + + Current workshop implementation. + + + + + Initialize this provider's external API. Should be called before using provider features. + + Thrown if initializing fails. + + + + Update this provider's external API. Should be called every frame if using provider features. + + + + + Shutdown this provider's external API. Should be called before closing the program if using provider features. + + + + + Used to show a warning when a lot of servers are blocked by curation list. + + + + + Reset after starting connection attempt, so set to true afterwards to auto join the server. + + + + + Dummy connection used in singleplayer. @@ -21331,7 +21693,7 @@ - Thanks DiFFoZ! Ensures GC does not release the delegate. + Ensures GC does not release the delegate. @@ -21349,19 +21711,71 @@ Overrides k_ESteamNetworkingConfig_EnableDiagnosticsUI. + + + Must close the handle to free up resources. + + + + + Must close the handle to free up resources. + + + + + Recycled array for every read call. + + + + + Implementing as a struct wrapping the connection handle would remove the cost of looking up the connection, + but implementing as a class makes it cheap to cache information like the remote identity. + + + + + Find game connection associated with Steam connection. + + + + + Must close the handle to free up resources. + + + + + Must close the handle to free up resources. + + + + + Defaults to true. If false, skip Steam Networking Sockets creation of regular IP socket. + + + + + Defaults to true. If false, skip Steam Networking Sockets creation of non-FakeIP P2P socket. + (this is the socket used by "server codes") + + Implementation using .NET Berkeley sockets. + + + Implementation using .NET Berkeley sockets. + + Implements message boundaries on top of a TCP stream socket. - + - Implementation using .NET Berkeley sockets. + SteamNetworking is deprecated. @@ -21369,16 +21783,174 @@ SteamNetworking is deprecated. - + - SteamNetworking is deprecated. + Hacky workaround to fix item skin material leak. Unfortunately none of the original item skin code destroyed + instantiated materials, and did not keep a reference to the instantiated materials, so until that code gets a + rewrite this will take care of cleanup. - + + + Used to capture promotional images. + + Unity does not allow components in the editor assembly, so this component is in the game assembly but only compiled in the editor. + + + + + Test to compare differrent Unity instancing meshes. + + Unity does not allow components in the editor assembly, so this component is in the game assembly but only compiled in the editor. + + + - Dummy connection used in singleplayer. + Debug component in the editor to see if GetRandomForwardVectorInCone seems correct. :) + Not much of a mathematician. :( + + + + + Nelson 2025-04-30: carrying this over from whatever very old version of the A* Pathfinding Project the game was + using because it has a few hacked-in behaviors the newer components don't. Ideally, we should write a custom + movement component using the newer AIBase class. + + Determines how often it will search for new paths. + If you have fast moving targets or AIs, you might want to set it to a lower value. + The value is in seconds between path requests. + + + Target to move towards. + The AI will try to follow/move towards this target. + It can be a point on the ground where the player has clicked in an RTS for example, or it can be the player object in a zombie game. + + + Enables or disables searching for paths. + Setting this to false does not stop any active path requests from being calculated or stop it from continuing to follow the current path. + \see #canMove + + + Enables or disables movement. + \see #canSearch + + + Maximum velocity. + This is the maximum speed in world units per second. + + + Rotation speed. + Rotation is calculated using Quaternion.SLerp. This variable represents the damping, the higher, the faster it will be able to rotate. + + + Distance from the target point where the AI will start to slow down. + * Note that this doesn't only affect the end point of the path + * but also any intermediate points, so be sure to set #forwardLook and #pickNextWaypointDist to a higher value than this + + + Determines within what range it will switch to target the next waypoint in the path + + + Target point is Interpolated on the current segment in the path so that it has a distance of #forwardLook from the AI. + See the detailed description of AIPath for an illustrative image + + + Distance to the end point to consider the end of path to be reached. + When this has been reached, the AI will not move anymore until the target changes and OnTargetReached will be called. + + + Do a closest point on path check when receiving path callback. + Usually the AI has moved a bit between requesting the path, and getting it back, and there is usually a small gap between the AI + and the closest node. + If this option is enabled, it will simulate, when the path callback is received, movement between the closest node and the current + AI position. This helps to reduce the moments when the AI just get a new path back, and thinks it ought to move backwards to the start of the new path + even though it really should just proceed forward. + + + Cached Seeker component + + + Cached Transform component + + + Time when the last path request was sent + + + Current path which is followed + + + Cached CharacterController component + + + Current index in the path which is current target + + + Holds if the end-of-path is reached + \see TargetReached + + + Only when the previous path has been returned should be search for a new path + + + Returns if the end-of-path has been reached + \see targetReached + + + Initializes reference variables. + * If you override this function you should in most cases call base.Awake () at the start of it. + * + + + Run at start and when reenabled. + Starts RepeatTrySearchPath. + + \see Start + + + Requests a path to the target + + + Called when a requested path has finished calculation. + A path is first requested by #SearchPath, it is then calculated, probably in the same or the next frame. + Finally it is returned to the seeker which forwards it to this function.\n + + + Point to where the AI is heading. + Filled in by #CalculateVelocity + + + Relative direction to where the AI is heading. + Filled in by #CalculateVelocity + + + Calculates desired velocity. + Finds the target path segment and returns the forward direction, scaled with speed. + A whole bunch of restrictions on the velocity is applied to make sure it doesn't overshoot, does not look too far ahead, + and slows down when close to the target. + /see speed + /see endReachedDistance + /see slowdownDistance + /see CalculateTargetPoint + /see targetPoint + /see targetDirection + /see currentWaypointIndex + + + Rotates in the specified direction. + Rotates around the Y-axis. + \see turningSpeed + + + Calculates target point from the current line segment. + \param p Current position + \param a Line segment start + \param b Line segment end + The returned point will lie somewhere on the line segment. + \see #forwardLook + \todo This function uses .magnitude quite a lot, can it be optimized? + Does initialOverlaps array contain hit collider? @@ -21391,10 +21963,10 @@ - Perform a move, then do a capsule cast to determine if Unity PhysX went through a wall. + Perform a move, then do a capsule cast to determine if physics simulation went through a wall. Required when disabling overlap recovery because there are issues when walking toward slopes that bend inward. - To test if Unity works properly in the future; walk toward the inside of a barracks building in the PEI base. + To test if physics simulation handles this better in the future: walk toward the inside of a barracks building in the PEI base. @@ -21419,32 +21991,5 @@ rates there may be multiple FixedUpdates per frame. - - - Used to capture promotional images. - - Unity does not allow components in the editor assembly, so this component is in the game assembly but only compiled in the editor. - - - - - Test to compare differrent Unity instancing meshes. - - Unity does not allow components in the editor assembly, so this component is in the game assembly but only compiled in the editor. - - - - - Hacky workaround to fix item skin material leak. Unfortunately none of the original item skin code destroyed - instantiated materials, and did not keep a reference to the instantiated materials, so until that code gets a - rewrite this will take care of cleanup. - - - - - Debug component in the editor to see if GetRandomForwardVectorInCone seems correct. :) - Not much of a mathematician. :( - - diff --git a/redist/redist-server-publicized/RocketModFix.Unturned.Redist.Server.nuspec b/redist/redist-server-publicized/RocketModFix.Unturned.Redist.Server.nuspec index bb17c65f..7674f92d 100644 --- a/redist/redist-server-publicized/RocketModFix.Unturned.Redist.Server.nuspec +++ b/redist/redist-server-publicized/RocketModFix.Unturned.Redist.Server.nuspec @@ -2,7 +2,7 @@ RocketModFix.Unturned.Redist.Server.Publicized - 3.25.9.2 + 3.25.10.0 Unturned 3 Server-side redistributables. Standalone and always up-to-date. diff --git a/redist/redist-server-publicized/SDG.Glazier.Runtime.dll b/redist/redist-server-publicized/SDG.Glazier.Runtime.dll index a9c9985e..7a78c9d3 100755 Binary files a/redist/redist-server-publicized/SDG.Glazier.Runtime.dll and b/redist/redist-server-publicized/SDG.Glazier.Runtime.dll differ diff --git a/redist/redist-server-publicized/SDG.HostBans.Runtime.dll b/redist/redist-server-publicized/SDG.HostBans.Runtime.dll index c13a509e..7630b9b4 100755 Binary files a/redist/redist-server-publicized/SDG.HostBans.Runtime.dll and b/redist/redist-server-publicized/SDG.HostBans.Runtime.dll differ diff --git a/redist/redist-server-publicized/SDG.NetPak.Runtime.dll b/redist/redist-server-publicized/SDG.NetPak.Runtime.dll index 4a6699ea..15b070b2 100755 Binary files a/redist/redist-server-publicized/SDG.NetPak.Runtime.dll and b/redist/redist-server-publicized/SDG.NetPak.Runtime.dll differ diff --git a/redist/redist-server-publicized/SDG.NetPak.Runtime.xml b/redist/redist-server-publicized/SDG.NetPak.Runtime.xml index f4215536..973d5d5f 100755 --- a/redist/redist-server-publicized/SDG.NetPak.Runtime.xml +++ b/redist/redist-server-publicized/SDG.NetPak.Runtime.xml @@ -9,57 +9,78 @@ Indicates net reader/writer implementation should be generated. - + - Uses "smallest three" optimization described by Glenn Fiedler: https://gafferongames.com/post/snapshot_compression/ - Quoting here in case the link moves: "Since we know the quaternion represents a rotation its length must - be 1, so x^2+y^2+z^2+w^2 = 1. We can use this identity to drop one component and reconstruct it on the - other side. For example, if you send x,y,z you can reconstruct w = sqrt(1 - x^2 - y^2 - z^2). You might - think you need to send a sign bit for w in case it is negative, but you don’t, because you can make w always - positive by negating the entire quaternion if w is negative (in quaternion space (x,y,z,w) and (-x,-y,-z,-w) - represent the same rotation.) Don’t always drop the same component due to numerical precision issues. - Instead, find the component with the largest absolute value and encode its index using two bits [0, 3] - (0=x, 1=y, 2=z, 3=w), then send the index of the largest component and the smallest three components over - the network (hence the name). On the other side use the index of the largest bit to know which component - you have to reconstruct from the other three." + Packs bits into a 32-bit buffer value, and from there into a byte array. GafferOnGames recommends this approach + rather than "farting across a buffer at byte level like it's 1985". - + - Similar to the quaternion optimization, but needs a sign bit for the largest value. + Lightweight error when exceptions are disabled. Bitwise OR to prevent different errors from clobbering each other. - + - Default intBitCount of 13 allows a range of [-4096, +4096). + Unpacks bits from a byte array into a 32-bit buffer value. GafferOnGames recommends this approach rather than + "farting across a buffer at byte level like it's 1985". - + - Write 8-bit per channel color excluding alpha. + Lightweight error when exceptions are disabled. Bitwise OR to prevent different errors from clobbering each other. - + - Write 8-bit per channel color including alpha. + Call to ReadBits or ReadBytes would have overflowed our buffer. - + - Note: "Special" here refers to the -90 rotation on the X axis. :) - If quaternion is only a rotation around the Y axis (yaw) which is common for barricades and structures, - write only yaw. Otherwise, write full quaternion. + Buffer passed into ReadBytes would have overflowed. - + - Packs bits into a 32-bit buffer value, and from there into a byte array. GafferOnGames recommends this approach - rather than "farting across a buffer at byte level like it's 1985". + AlignToByte bits should be zero. - + - Lightweight error when exceptions are disabled. Bitwise OR to prevent different errors from clobbering each other. + Buffer passed into SaveState would have overflowed. + + + + + Imprecise because sent byte length is rounded up from bit length, but should help find particularly + egregious reading errors. + + + + + Number of bytes until end of segment is reached. + + + + + Save remaining data to resume reading later. Used by net invokables to defer invocation. + + + + + Used by invocation messages to show more error context rather than the default. + + + + + Used by NetInvokable loopback to copy buffer from writer to reader. + + + + + Assumes length is greater than zero! + Moves reader forward according to length. @@ -113,53 +134,6 @@ Read only yaw if quaternion was flat, full quaternion otherwise. - - - For example bitCount of 7 allows range [-64, +64). - - - - - Values outside the range are clamped into range. - For example intBitCount of 7 allows range [0, 128). - - - - - Values outside the range are clamped into range. - For example intBitCount of 7 allows range [-64, +64). - - - - - Encode a float in the range [0.0, 1.0]. Endpoints are encoded exactly, but not the midpoint (0.5). - - - - - Encode a float in the range [-1.0, +1.0]. Endpoints and midpoint (0.0) are encoded exactly. - - - - - Encode radians wrapped into the range [0, TWO_PI). - - - - - Encode degrees wrapped into the range [0, 360). - - - - - Placeholder allowing user assembly to compile before specialized implementation is generated. - - - - - Ideally should not be used by new code. - - For example bitCount of 7 allows range [-64, +64). @@ -197,95 +171,121 @@ Ideally should not be used by new code. - + - Unpacks bits from a byte array into a 32-bit buffer value. GafferOnGames recommends this approach rather than - "farting across a buffer at byte level like it's 1985". + Uses "smallest three" optimization described by Glenn Fiedler: https://gafferongames.com/post/snapshot_compression/ + Quoting here in case the link moves: "If v is the absolute value of the largest quaternion component, + the next largest possible component value occurs when two components have the same absolute value and the + other two components are zero. The length of that quaternion (v,v,0,0) is 1, therefore v^2 + v^2 = 1, + 2v^2 = 1, v = 1/sqrt(2). This means you can encode the smallest three components in [-0.707107,+0.707107] + instead of [-1,+1] giving you more precision with the same number of bits." - + - Lightweight error when exceptions are disabled. Bitwise OR to prevent different errors from clobbering each other. + Maximum number of bits to read/write for string byte count without overflowing the string buffer. - + - Call to ReadBits or ReadBytes would have overflowed our buffer. + Maximum number of UTF8 bytes for string. + Before the "null or empty" flag was added the length had to be able to represent 0, but now the receiver + can infer that the byte count is at least 1. - + - Buffer passed into ReadBytes would have overflowed. + encoderShouldEmitUTF8Identifier enables byte order mark (BOM) which is unnecessary for UTF8. + throwOnInvalidBytes allows reader to discard bad string packets. - + - AlignToByte bits should be zero. + For example bitCount of 7 allows range [-64, +64). - + - Buffer passed into SaveState would have overflowed. + Values outside the range are clamped into range. + For example intBitCount of 7 allows range [0, 128). - + - Imprecise because sent byte length is rounded up from bit length, but should help find particularly - egregious reading errors. + Values outside the range are clamped into range. + For example intBitCount of 7 allows range [-64, +64). - + - Number of bytes until end of segment is reached. + Encode a float in the range [0.0, 1.0]. Endpoints are encoded exactly, but not the midpoint (0.5). - + - Save remaining data to resume reading later. Used by net invokables to defer invocation. + Encode a float in the range [-1.0, +1.0]. Endpoints and midpoint (0.0) are encoded exactly. - + - Used by invocation messages to show more error context rather than the default. + Encode radians wrapped into the range [0, TWO_PI). - + - Used by NetInvokable loopback to copy buffer from writer to reader. + Encode degrees wrapped into the range [0, 360). - + - Assumes length is greater than zero! - Moves reader forward according to length. + Placeholder allowing user assembly to compile before specialized implementation is generated. - + + + Ideally should not be used by new code. + + + Uses "smallest three" optimization described by Glenn Fiedler: https://gafferongames.com/post/snapshot_compression/ - Quoting here in case the link moves: "If v is the absolute value of the largest quaternion component, - the next largest possible component value occurs when two components have the same absolute value and the - other two components are zero. The length of that quaternion (v,v,0,0) is 1, therefore v^2 + v^2 = 1, - 2v^2 = 1, v = 1/sqrt(2). This means you can encode the smallest three components in [-0.707107,+0.707107] - instead of [-1,+1] giving you more precision with the same number of bits." + Quoting here in case the link moves: "Since we know the quaternion represents a rotation its length must + be 1, so x^2+y^2+z^2+w^2 = 1. We can use this identity to drop one component and reconstruct it on the + other side. For example, if you send x,y,z you can reconstruct w = sqrt(1 - x^2 - y^2 - z^2). You might + think you need to send a sign bit for w in case it is negative, but you don’t, because you can make w always + positive by negating the entire quaternion if w is negative (in quaternion space (x,y,z,w) and (-x,-y,-z,-w) + represent the same rotation.) Don’t always drop the same component due to numerical precision issues. + Instead, find the component with the largest absolute value and encode its index using two bits [0, 3] + (0=x, 1=y, 2=z, 3=w), then send the index of the largest component and the smallest three components over + the network (hence the name). On the other side use the index of the largest bit to know which component + you have to reconstruct from the other three." - + - Maximum number of bits to read/write for string byte count without overflowing the string buffer. + Similar to the quaternion optimization, but needs a sign bit for the largest value. - + - Maximum number of UTF8 bytes for string. - Before the "null or empty" flag was added the length had to be able to represent 0, but now the receiver - can infer that the byte count is at least 1. + Default intBitCount of 13 allows a range of [-4096, +4096). - + - encoderShouldEmitUTF8Identifier enables byte order mark (BOM) which is unnecessary for UTF8. - throwOnInvalidBytes allows reader to discard bad string packets. + Write 8-bit per channel color excluding alpha. + + + + + Write 8-bit per channel color including alpha. + + + + + Note: "Special" here refers to the -90 rotation on the X axis. :) + If quaternion is only a rotation around the Y axis (yaw) which is common for barricades and structures, + write only yaw. Otherwise, write full quaternion. diff --git a/redist/redist-server-publicized/SDG.NetTransport.dll b/redist/redist-server-publicized/SDG.NetTransport.dll index 9a7878c2..2e44b2f2 100755 Binary files a/redist/redist-server-publicized/SDG.NetTransport.dll and b/redist/redist-server-publicized/SDG.NetTransport.dll differ diff --git a/redist/redist-server-publicized/SystemEx.dll b/redist/redist-server-publicized/SystemEx.dll index 9526835d..fdb6a31a 100755 Binary files a/redist/redist-server-publicized/SystemEx.dll and b/redist/redist-server-publicized/SystemEx.dll differ diff --git a/redist/redist-server-publicized/UnityEx.dll b/redist/redist-server-publicized/UnityEx.dll index 1da7030a..b8fda6d7 100755 Binary files a/redist/redist-server-publicized/UnityEx.dll and b/redist/redist-server-publicized/UnityEx.dll differ diff --git a/redist/redist-server-publicized/UnturnedDat.dll b/redist/redist-server-publicized/UnturnedDat.dll index 9219357e..d77fbc50 100755 Binary files a/redist/redist-server-publicized/UnturnedDat.dll and b/redist/redist-server-publicized/UnturnedDat.dll differ diff --git a/redist/redist-server-publicized/com.rlabrecque.steamworks.net.dll b/redist/redist-server-publicized/com.rlabrecque.steamworks.net.dll index 6617154b..40ec6abd 100755 Binary files a/redist/redist-server-publicized/com.rlabrecque.steamworks.net.dll and b/redist/redist-server-publicized/com.rlabrecque.steamworks.net.dll differ diff --git a/redist/redist-server-publicized/manifest.sha256.json b/redist/redist-server-publicized/manifest.sha256.json index 496e6fd3..4b29d43c 100644 --- a/redist/redist-server-publicized/manifest.sha256.json +++ b/redist/redist-server-publicized/manifest.sha256.json @@ -1,13 +1,13 @@ { - "SDG.HostBans.Runtime.dll": "bba74cb1501121e2cf196e4058a33cdf36534fe19f7b128e3c7c689dad50df18", - "com.rlabrecque.steamworks.net.dll": "18472606a1e899af960f48799d9404e4e83ab56ebf56b891c742d4b069c1d370", - "Assembly-CSharp.dll": "3e8ebf20f2332cdd4e69918ab9d4c93998e74c2296b90f139956cf743c8c0095", - "SDG.NetTransport.dll": "d44ad1bf6732b380f33ffd48bbfec0cfc05e5e7c73d30092e6b08db18a3ef524", - "Assembly-CSharp.xml": "c0024ce5d054dfd2e6ef37900533f2e66d4629ee7e60c225fa51c3f696708491", - "SDG.NetPak.Runtime.xml": "032c8d2d0a3e1f15ef1139b98f5370eb1fb94d65bf01c4462a0c0e6578bb705a", - "SystemEx.dll": "c47c3ead2c48924a1b6ed776342612058d019bf942ec2fbbfb612d295666963f", - "UnturnedDat.dll": "a17f1a6f053a9404d248f240a23621e061baf306c3daf8d53148feeb619148e5", - "SDG.NetPak.Runtime.dll": "3bc5319a211e2cef78c5eab36e04cd34b27c793d2e05526af4bd0db75444f225", - "UnityEx.dll": "5b2e6fa72a65fd58c9b809074aba9f8be57aca33c617754223601be5e6a31479", - "SDG.Glazier.Runtime.dll": "db1c52b2ec3806c6693fc5756f1cc4c380dcec872f333c450f44999273e522a0" + "SDG.HostBans.Runtime.dll": "8dee797f51bc71d963956dd8c5a9dcb20cb28b4d78f7277dff1ac5c04c41dd5a", + "com.rlabrecque.steamworks.net.dll": "be82f615a25dc536c0629a14b786bb6c7122b12fc097db64d1062a86e16c6239", + "Assembly-CSharp.dll": "5d261f768e0886f2dad81b079024f04a6d16ec4681e9058135934bcb2d1bf7be", + "SDG.NetTransport.dll": "718ae0c6417d1fb299c3c393276335f9806e8f0d3f342d87604f289bd0aa697e", + "Assembly-CSharp.xml": "e5c29583ce52f96b7a6853fc2790b785577cf09c2cbb8c267a32a9d7dadad70b", + "SDG.NetPak.Runtime.xml": "f9592fc449fbf9564e4d5d6b28d2d6c9cda75e94bc38250e65c1a1ff064aad11", + "SystemEx.dll": "c24f230d8a69a6da27acb6624ece0f88644acfe2aa27b362298c8951bd8d1967", + "UnturnedDat.dll": "5df9a82b0bdabdb43da09b6975e1497e2b9524537ba362da2ea9a23ae2a075d9", + "SDG.NetPak.Runtime.dll": "d9eef486901b39ca115f514d61f93e09392b0cc0956160cd479bcd6bc43b56d2", + "UnityEx.dll": "595dfdfe0678517b0b735054a7bbe3cc8de2fddf80b2d855512f4f4f70e6a029", + "SDG.Glazier.Runtime.dll": "320ed9315da9cb92bc8aa37cef6db127324de0a722ad793a6740977c14f2bb50" } \ No newline at end of file diff --git a/redist/redist-server-publicized/version.json b/redist/redist-server-publicized/version.json index 46fb2288..4f57e14b 100644 --- a/redist/redist-server-publicized/version.json +++ b/redist/redist-server-publicized/version.json @@ -1,7 +1,7 @@ { - "GameVersion": "3.25.9.2", - "BuildId": "20243005", - "NuGetVersion": "3.25.9.2", - "FilesHash": "700515F7883F4D40BE91A81750FAAA6CE9594B198F5C2716AE795BA142D29CE6", - "LastUpdated": "2025-10-03T20:51:56.4111231Z" + "GameVersion": "3.25.10.0", + "BuildId": "21056629", + "NuGetVersion": "3.25.10.0", + "FilesHash": "7CB582DA09EE5CF443CC14824BF82F973B8217B0B4F9BD4357917686E5E9F855", + "LastUpdated": "2025-12-04T16:55:58.2083264Z" } \ No newline at end of file