Waveyjones
Based on game build 714014 | Last updated: 2026-03-07
Overview
waveyjones.lua defines the core prefabs and initialization logic for Wavey Jones, a boss creature in the Dangerous Sea event. It includes five interdependent prefabs: waveyjones (the main entity), waveyjones_arm, waveyjones_hand, waveyjones_hand_art, and waveyjones_marker. The component orchestrates the spawning of arms and hands, handles player proximity detection, triggers scare/relocate behavior, manages respawn timers, and coordinates animation and sound events. It relies heavily on entitytracker, updatelooper, playerprox, sanityaura, and timer components.
Usage example
-- Wavey Jones is automatically spawned as part of the Dangerous Sea event via waveyjones_marker
-- The marker is created by the game when the event starts; no direct prefab usage is required.
-- Example manual usage (not part of official flow):
local marker = SpawnPrefab("waveyjones_marker")
marker.Transform:SetPosition(x, y, z)
marker.components.entitytracker:TrackEntity("boat", boat)
Dependencies & tags
Components used: entitytracker, updatelooper, sanityaura, timer, playerprox, locomotor, transform, animstate, soundemitter, network
Tags added:
waveyjones:shadowwaveyjones_hand,waveyjones_hand_art,waveyjones_arm,waveyjones_marker:NOCLICKwaveyjones_hand_art:DECORwaveyjones_marker:NOBLOCK
Properties
No public properties defined directly on instances; interaction occurs through component methods and event listeners.
Main functions
Not applicable. This file defines prefabs via factory functions (fn, handfn, handartfn, armfn, markerfn) and helper functions; it does not expose a central component with callable methods.
Events & listeners
- Listens to:
onremove(all prefabs): Triggers cleanup (e.g., removing target,吓走 Jones, respawning logic).animover(waveyjones): Removeswaveyjonesafter scared animation ends.laugh(waveyjones): Triggers laughter behavior.timerdone(waveyjones_marker): Handles respawn timer completion.STATE_*events (waveyjones_hand_art): Control state transitions.onscared(waveyjones_hand,waveyjones_hand_art,waveyjones_arm): Removes or relocates affected entities.
- Pushes:
onscared(all arms/hands when scared): Broadcast when Wavey Jones is scared.trapped,released(waveyjones_hand): Fired when player enters or exits proximity.