Skip to content

RTCW MP

Zack Middleton edited this page Nov 10, 2015 · 20 revisions

RTCW-MP engine features missing from Spearmint.

Not required to be usable

I'm not sure if I want to add these. Translation support should use gettext, not a legacy one-off game translation system. It may be possible to add RTCW-style translation support in VMs, I haven't looked into it.

  • Translation support
  • Auto update
  • Open URL

Missing CGame API calls

  • trap_S_StartSoundEx

  • Splines camera support

    • Used by searchlights on mp_dam (in game of the year map pack) and SP.
    • ZTM: I plan to put it in CGame.

Modified CGame API calls

  • trap_S_AddLoopingSound in RTCW does not use entityNum, allowing adding looping sounds for flame chunks which do not have individual server entities.

Missing API calls that are only used by SP?

  • trap_S_GetVoiceAmplitude (not used in MP, used in SP)
  • Get tag (only needed for SP, plus I want to change the game code so it isn't needed)
  • Missing some bot system calls (only needed for SP, MP doesn't have bots)

Renderer

Devil

These are available in devil branch for Spearmint 0.2.

  • Custom dlight shaders.
  • Missing fireRiseDir in refEntity_t for alphaGen normalzfade and negative deform wave frequency.
  • Missing API for setting MDS (e.g. player model) torso axis and animation frame/oldframe/backlerp.

Missing

  • Missing option to force adding dlight when they are disabled, for dynamite trail.

    • ZTM: I'm not a big fan of 'disabled' not meaning 'disabled'. Could have a separate cgame cvar for drop all dlights except dynamite light.
  • Some stuff from tr_types.h

    • REFLAG_FORCE_LOD. Use low level of detail. It's used when a entity is on fire. I think it might be for visual effect, not performance, but I'm not sure.
    • (SP only) RDF_SNOOPERVIEW makes lightmaps be replaced with white, disables dlights, and disables fog blocks (global GL fog is not disabled). Maybe add RDF_NOLIGHTMAPS and RDF_NOWORLDFOG, and separately manually drop dlights in cgame or add RDF_NODLIGHTS? This is only used in Single Player with Garand's scope mode.
  • refEntity_t::fadeStartTime and fadeEndTime fades RGBA, forces blendfunc blend, forces cull front.

    • This might be replaceable using RF_RGB_TINT/RF_FORCE_ENT_ALPHA and shaderRGBA.
    • However, it lacks forcing cull front and prevents the shader's rgbGen and alphaGen from being used (I'm not sure if that is important).
    • Maybe there should be RF_RGB_MOD and RF_ALPHA_MOD to scale instead of set the RGBA? (It would still interfere with rgbGen/alphaGen entity though.)

Model bounds overrides

Missing overriding model bounds. Does RTCW data actually needs these? Probably not.

"Hack for Bug using plugin generated model"

MD3 with radius of 1 use mins=-128, maxs=128, radius=256. The following MP MD3s have a radius of 1. No SP MD3s have a radius of 1 (probably because they were converted into MDCs with the hacked values).

models/mapobjects/vehicles/lander1w.md3
models/mapobjects/vehicles/lander.md3
models/multiplayer/ammopack/v_ammopack_hand.md3
models/multiplayer/medpack/v_medpack_hand.md3
models/multiplayer/pliers/v_pliers_hand.md3
models/multiplayer/smokegrenade/v_smokegrenade_hand.md3
models/multiplayer/syringe/v_syringe_hand.md3

The lander md3s definitely have the wrong bounds, though I don't think radius 256 isn't big enough to cover models either. The landers on mp_beach are compiled into the BSP, so the md3s aren't loaded. The _hand.md3 model don't need bounds since they are not drawing, only used for tag positions.

Sherman / MG42

MD3/MDC that name contains "sherman" or "mg42" use mins=-128, maxs=128, radius=256.

  • There are no md3/mdc models with sherman in the filename.
  • models/mapobjects/weapons/mg42a.mdc and models/mapobjects/weapons/mg42b.mdc already have these values.
  • models/multiplayer/mg42/mg42.md3 has lower values.
models/multiplayer/mg42/mg42.md3
frame 1: radius = 39.829609, mins = -34.937500,-2.656250,-12.562500, maxs = 37.703125,2.640625,4.046875
frame 2/3: radius = 40.011345, mins = -35.515625,-2.656250,-18.234375, maxs = 34.812500,2.640625,9.046875

When disabling the bounds override for models/multiplayer/mg42/mg42.md3 in RTCW MP, there doesn't seem to be any culling issue for the MG42 (in-place weapon on maps, see mp_beach for example). I don't think this hack is needed.

Not required?

I don't think these are needed, but might find out otherwise when the game or mods are ported.

  • Dlight overdraw argument allows drawing the dlight image multiple times. I think it can be replaced by ET's dlight intensity. I haven't tested and compared results however.
  • tcGen firerisenv aka TCGEN_FIRERISEENV_MAPPED
    • No shaders in RTCW SP/MP use this. It allows specifying a direction for environment mapping using refEntity_t::fireRiseDir. It is slightly different than the regular environment mapping which calculates direction based on dir between viewOrigin and each vertex.

Port notes

  • Console background needs to be changed for RTCW-MP in CGame VM.
  • r_flareFade is 5 in RTCW MP/SP but 7 in Q3.
Clone this wiki locally