SFItem.SFWLaser

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
00068
00069
00070
00071
00072
00073
00074
00075
00076
00077
00078
00079
00080
00081
00082
00083
//=============================================================================
// Spatial Fear
// Class: SFWLaser
// Description: Weapon upgrade: LaserSight improves accuracy.
//
// Created by: Ivan Tanzuira
// Modified by: Markus Nuebel
//=============================================================================
class SFWLaser expands SFPickup;

#exec MESH IMPORT MESH=SFWLaser ANIVFILE=MODELS\SFWLaser_a.3d DATAFILE=MODELS\SFWLaser_d.3d X=0 Y=0 Z=0
#exec MESH ORIGIN MESH=SFWLaser X=0 Y=0 Z=0

#exec MESH SEQUENCE MESH=SFWLaser SEQ=All      STARTFRAME=0 NUMFRAMES=1
#exec MESH SEQUENCE MESH=SFWLaser SEQ=SFWLaser STARTFRAME=0 NUMFRAMES=1

#exec TEXTURE IMPORT NAME=JSFWLaser1 FILE=TEXTURES\SFWLaser1.PCX GROUP=Skins FLAGS=2 // 1 - Default

#exec MESHMAP NEW   MESHMAP=SFWLaser MESH=SFWLaser
#exec MESHMAP SCALE MESHMAP=SFWLaser X=0.05 Y=0.05 Z=0.1

#exec MESHMAP SETTEXTURE MESHMAP=SFWLaser NUM=1 TEXTURE=JSFWLaser1

// Called when the upgrade is activated
// Upgrades the players speed with the configured amount
function Activate()
{
	local SFPlayer	oPlayer;

	// Get the player reference
	oPlayer	= SFPlayer(Owner);
	if(None == oPlayer)
		return;

	// Bring up the weapon selection window
	SFHUD(oPlayer.myHUD).showWeaponSelection(Self);

	// Call to base class
	Super.Activate();

}

state Activated
{
	function Endstate()
	{
		bActive = false;
	}

	function BeginState()
	{
		PlaySound(ActivateSound,,4.0);

		// Upgrade already done, remove item from belt
		SFHUD(SFPlayer(Owner).myHUD).removeFromActiveItemBelt(Self);

		UsedUp();
	}

Begin:
}

state DeActivated
{
Begin:
}

defaultproperties
{
     ItemDescription="Laser Sight:\nAn Additional Weapon Element. The installation of this weapon element will provide a laser sight to aid in the locating of targets."
     ItemIcon=Texture'SfResource1.Icons.LaserSightIco'
     bIsActiveItem=True
     bActivatable=True
     ItemName="Laser Sight"
     PlayerViewMesh=LodMesh'SFItem.SFWLaser'
     PickupViewMesh=LodMesh'SFItem.SFWLaser'
     PickupSound=Sound'UnrealShare.Pickups.GenPickSnd'
     ActivateSound=Sound'UnrealI.Pickups.fFieldh2'
     RemoteRole=ROLE_DumbProxy
     Mesh=LodMesh'SFItem.SFWLaser'
     AmbientGlow=32
}

class file time: 12/7/2003 3:58:26 PM - creation time: 12/7/2003 4:03:46 PM
Created with UnCodeX