OverrideHasInfiniteAmmo

Tracking Issue: #842

Tags: events

Allows listeners to override the result of HasInfiniteAmmo

OverrideHasInfiniteAmmo event

Param Value
EventID OverrideHasInfiniteAmmo
EventData XComLWTuple
EventSource XComGameState_Item
NewGameState none

Tuple contents

Index Name Type Direction
0 bHasInfiniteAmmo bool out

Listener template

static function EventListenerReturn OnOverrideHasInfiniteAmmo(Object EventData, Object EventSource, XComGameState GameState, Name EventID, Object CallbackObject)
{
    local XComGameState_Item ItemState;
    local XComLWTuple Tuple;
    local bool bHasInfiniteAmmo;

    ItemState = XComGameState_Item(EventSource);
    Tuple = XComLWTuple(EventData);

    // Your code here

    Tuple.Data[0].b = bHasInfiniteAmmo;

    return ELR_NoInterrupt;
}

Source code references