MCPcopy Create free account
hub / github.com/DescentDevelopers/Descent3 / CreateCountermeasureFromObject

Function CreateCountermeasureFromObject

Descent3/WeaponFire.cpp:3389–3397  ·  view source on GitHub ↗

Given a parent object and a weapon id, creates that countermeasure

Source from the content-addressed store, hash-verified

3387
3388// Given a parent object and a weapon id, creates that countermeasure
3389void CreateCountermeasureFromObject(object *parent, int weapon_id) {
3390 ASSERT(parent != NULL);
3391 ASSERT(Weapons[weapon_id].used);
3392
3393 if (Game_mode & GM_MULTI)
3394 MultiSendRequestCountermeasure(parent - Objects, weapon_id);
3395 else
3396 FireWeaponFromObject(parent, weapon_id, 5);
3397}
3398
3399// Releases the guided missile of a passed in player
3400void ReleaseGuidedMissile(int slot) {

Callers 1

UseMethod · 0.85

Calls 2

FireWeaponFromObjectFunction · 0.85

Tested by

no test coverage detected