Objects spawned directly in the world (init.c / CE) are real BuildingBase
entities, so attach a Search to them by classname - independent of the proxy
framework (which needs a parent house; CCTCursorParent rejects parentless
objects).
- ActionYASearchObj: object-targeted (CCTNonRuined) Search; resolves the entry
from target.GetObject().GetType() (substring), cooldown keyed by network id
- modded BuildingBase.SetActions: attaches it to classes matching a search entry
- Shared YAInteractionManager.PerformSearch() used by both proxy + object actions
- Re-add vending_machine (works for standalone-spawned vending machines)
Lets you make spawned loot boxes / vending machines lootable: add the classname
(or a substring) as a 'search' entry.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
YAInteractableEntry gains SearchChance (% chance a search yields anything),
SearchMin/SearchMax (item count on success), replacing the global roll
constants. Search rolls the chance first; on success spawns a random count in
[SearchMin, SearchMax] from the loot table. Defaults: lekarnicka 60% 1-2,
fridge 75% 1-2. Fields have inline defaults so older JSON loads safely.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Hospital vending machines resolve to target.GetObject()==null, so they can't be
detected or cleanly overridden. Ship sink + fridge + med cabinet (all working).
VendingTable loot kept for future re-add / reuse on a detectable furniture.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Editor + YAProxy scan show the vending proxy is 'vending_machine.NNN' (same
pattern as case_d/phonebox), not ZPF's override name 'sodamachine'. Update the
default so Search matches it.
Note: the old on-disk interactables.json used the pre-YAProxy schema
(ClassName/ComponentMatch), so ProxyName deserialized empty -> 0 interactables.
Deleting it (server) regenerates with the current schema.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
MissionServer.OnInit now confirms CfgPatches YAProxy exists before loading
config; if missing it warns and retries (10x/2s) then logs an actionable error.
Belt-and-suspenders for server-pack misconfiguration (requiredAddons already
hard-enforces the dependency).
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Replace the ZenProxyFramework dependency (broken on 1.29) with @YAProxy, our
self-contained proxy framework. Actions now extend YAProxyActionBase:
- Search / RepairSink / GatherWater resolve the targeted furniture proxy by
keyword and use the synced world position from YAProxy
- Confirmed proxy names from live test: case_sink_a, fridge, lekarnicka
(vending defaulted to 'sodamachine' pending confirmation)
- Registry lookup matches proxy names as substrings (handles '.001' suffix)
- Sink repaired-state + search/water cooldowns tracked server-side, keyed by
proxy world position / player UID (in-memory, reset on restart per v1 spec)
- Repair on Wrench/PipeWrench, GatherWater on Bottle_Base (item-based, load-
order safe); Search on PlayerBase
requiredAddons: YAProxy. Loot tables / settings JSON unchanged.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Furniture (sink/fridge/lekarnicka/vending) are house proxies, not entities, so
actions are now driven by ZenProxyFramework: actions target proxies by name
(GetZenProxyNameTarget), the proxy world position is synced to the server via
ActionData, repair spawns an invisible ZenProxySinkTest marker (presence =
repaired), and gather-water checks for it. Registry is keyed by proxy name;
loot tables / cooldowns / settings JSON kept.
NOTE: superseded approach - ZenProxyFramework does not compile on DayZ 1.29
(HouseType type-name collision). Next: a self-contained @YAProxy framework
(based on ZenProxyFramework + ShowMeInfoV2's geometry-LOD proxy scan) that
YAInteraction will depend on instead.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Two issues prevented the mod from running on the live server:
- Add $PBOPREFIX$.txt (=YAInteraction) matching the toolchain convention so
the packer mounts scripts at YAInteraction/... where config.cpp defs expect
them. Without it the script modules were silently never compiled.
- Replace GetGame().GetProfileFolder() (undefined function in this engine build,
caused a World module compile error) with the "$profile:" virtual path, the
portable idiom used by ZenRepairWells / TerjeMods.
Verified on the live server: modules compile, MissionServer.OnInit runs, and
settings.json + interactables.json are generated under profiles/YAInteraction/.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Move the registry, loot tables and scalar tunables out of hardcoded EnScript
into JSON loaded via DayZ's JsonFileLoader. Defaults are written to
<ProfileFolder>/YAInteraction/{settings.json,interactables.json} on first start
and read back (overriding code defaults) on subsequent starts.
- Add YAInteractionSettings (settings.json) and YAInteractionData
(interactables.json) serializable classes with inline defaults
- Add YAInteractionConfigLoader singleton: MakeDirectory + FileExist driven
load-or-save, plus client-safe in-code default fallback (EnsureDefaults)
- Load server-side via modded MissionServer.OnInit before players connect
- Gut YAInteractionConfig down to compile-time constants
- Rebuild manager lookups from loaded Data; update field names and float weights
- Remove redundant 5_Mission placeholder; update README
CF persistence and config hot-reload remain marked with // TODO (v2).
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Searchable furniture (med cabinet, fridge, vending machine) with weighted,
config-driven loot tables, and a two-stage repairable sink (repair then gather
water). Data-driven registry, in-memory cooldowns/repair state with v2 CF hooks.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>