g_rogue_misc.cpp 632 B

12345678910111213141516171819202122232425262728
  1. // Copyright (c) ZeniMax Media Inc.
  2. // Licensed under the GNU General Public License 2.0.
  3. #include "../g_local.h"
  4. //======================
  5. // ROGUE
  6. USE(misc_nuke_core_use) (edict_t *self, edict_t *other, edict_t *activator) -> void
  7. {
  8. if (self->svflags & SVF_NOCLIENT)
  9. self->svflags &= ~SVF_NOCLIENT;
  10. else
  11. self->svflags |= SVF_NOCLIENT;
  12. }
  13. /*QUAKED misc_nuke_core (1 0 0) (-16 -16 -16) (16 16 16)
  14. toggles visible/not visible. starts visible.
  15. */
  16. void SP_misc_nuke_core(edict_t *ent)
  17. {
  18. gi.setmodel(ent, "models/objects/core/tris.md2");
  19. gi.linkentity(ent);
  20. ent->use = misc_nuke_core_use;
  21. }
  22. // ROGUE
  23. //======================