-
Notifications
You must be signed in to change notification settings - Fork 54
Open
Description
The CSQC getsurface functions fail in CSQC always because the modelindex is 0 (because it is not set).
To make it work, requires a single line of code ... (the world is always modelindex 1)
csprogs.c ===> CL_VM_Init ...
// set map description (use world entity 0)
PRVM_clientedictstring(prog->edicts, message) = PRVM_SetEngineString(prog, cl.worldmessage);
PRVM_clientedictfloat(prog->edicts, modelindex) = 1; // Baker: World is always 1 - August 14 2025 <=== this line
VectorCopy(cl.world.mins, PRVM_clientedictvector(prog->edicts, mins));
VectorCopy(cl.world.maxs, PRVM_clientedictvector(prog->edicts, maxs));
VectorCopy(cl.world.mins, PRVM_clientedictvector(prog->edicts, absmin));
VectorCopy(cl.world.maxs, PRVM_clientedictvector(prog->edicts, absmax));
I made it work in CSQC_Init I set world.modelindex = 1 --- the engine hates that and prints a warning, but makes it work with DarkPlaces 2014 or later version so at least I get to keep maximum compatibility.
Link to DarkPlaces 2014 or later mod using the above https://www.moddb.com/mods/zircon-engine/downloads/csqc-rain-snow-ultra-hd-for-almost-any-mod
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels
