Overview | Package | Class | Source | Class tree | Glossary | UnrealScript Documentation
previous class next class | frames no frames

# Tyrion.NearMissCollisionVolume

00001 00002 00003 00004 00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031
00032
00033
00034
00035
00036
00037
00038
00039
00040
00041
00042
00043
00044
00045
00046
00047
00048
00049
00050
00051
00052
00053
00054
00055
00056
00057
00058
00059
00060
00061
00062
00063
00064
00065
00066
00067

    //=====================================================================
    // NearMissCollisionVolume
    //=====================================================================

    class NearMissCollisionVolume extends Engine.Actor
    	native;

    //=====================================================================
    // Constants

    //=====================================================================
    // Variables

    var Pawn pawn;							// reference back to the character/turret this collision volume is attached to (or None)
    var AI_NearMissSensor nearMissSensor;	// reference back to the sensor to notify

    //=====================================================================

    //---------------------------------------------------------------------

    function Touch( actor Other )
    {
    	local Projectile projectile;

    	projectile = Projectile(Other);
    	//log( Other.name @ "touched fat volume of" @ pawn.name @ "rookAttacker" @ projectile.rookAttacker );

    	if ( projectile != None && projectile.RookAttacker != pawn )
    	{
    		// when an AI gets hurt, activate it for it a bit so it can react regardless of it's LOD state
    		pawn.setLimitedTimeLODActivation( class'AI_Controller'.const.MAX_TICKS_TO_PROCESS_PAIN );

    		nearMissSensor.setObjectValue( other );
    	}
    }

    //---------------------------------------------------------------------

    function Destroyed()
    {
    	super.Destroyed();

    	//log( "@@@" @ nearMissSensor.name @ name @ pawn.name @ "DESTROYED!" );

    	nearMissSensor = None;
    }

    //=====================================================================

    defaultproperties
    {
    	remoteRole		  = ROLE_NONE
    	bSkipEncroachment = true
        bCollideActors    = true
        bCollideWorld     = false
        bBlockActors      = false
        bBlockPlayers     = false
        bProjTarget       = true

    	bHidden			= true
    	DrawType		= DT_None
    	bDisableTick	= true

    	CollisionHeight = 400
    	CollisionRadius = 600
    }

Overview | Package | Class | Source | Class tree | Glossary | UnrealScript Documentation
previous class next class | frames no frames

Class file time: ne 5.9.2004 15:54:24.000 - Creation time: st 23.5.2018 00:10:46.092 - Created with UnCodeX