|
|
(5 intermediate revisions by 2 users not shown) |
Line 1: |
Line 1: |
− | <uscript>
| + | #REDIRECT [[User:00zX]] |
− | | + | |
− | //===================================================
| + | |
− | // Class: UTData_BloodLust
| + | |
− | // Creation date: 22/08/2008 05:21
| + | |
− | //---------------------------------------------------
| + | |
− | // Attribution-Noncommercial-Share Alike 2.5 Generic
| + | |
− | // http://creativecommons.org/licenses/by-nc-sa/2.5/
| + | |
− | //---------------------------------------------------
| + | |
− | class UTData_BloodLust extends UTData_FactoryReplacer;
| + | |
− | | + | |
− | defaultproperties{
| + | |
− | ReplacementFactories(0)=(FactoryGroup='SPowerup',ReplacedFactory="UTPickupFactory_UDamage", ReplacedWithFactory="UTPickupFactory_VDamage", ReplacedWithFactoryPath="Newtators.UTPickupFactory_VDamage")
| + | |
− | }
| + | |
− | | + | |
− | //===================================================
| + | |
− | // Class: UTD_GR_Vampire
| + | |
− | // Creation date: 27/11/2007 04:01
| + | |
− | // Last Updated: 15/01/2009 07:07
| + | |
− | //---------------------------------------------------
| + | |
− | // Attribution-Noncommercial-Share Alike 2.5 Generic
| + | |
− | // http://creativecommons.org/licenses/by-nc-sa/2.5/
| + | |
− | //---------------------------------------------------
| + | |
− | //Modified version of Epics VampireGameRules from 2k4
| + | |
− | //-Support for UT3's armour system
| + | |
− | //-Support for Infantry Vs Vehicle??
| + | |
− | //-Support for Vehicle Vs Vehicle
| + | |
− | //===================================================
| + | |
− | class UTD_GR_Vampire extends UTD_GameRules;
| + | |
− | | + | |
− | var() float ConversionRatio;
| + | |
− | var globalconfig bool bUseSuperHealth;
| + | |
− | var globalconfig bool bUseForVehicles; //Infantry Vs Vehicle || Vehicle Vs Vehicle Damage!
| + | |
− | | + | |
− | function DmgFromEnemyTeam(EnemyP, EnemyTeam, bEnemyIsInfantry, bool bEnemyIsBot){
| + | |
− | local int VampHealth, VampMaxHealth, VampSuperHealth, DifHealth;
| + | |
− | | + | |
− | VampHealth = EnemyP.Health;
| + | |
− | | + | |
− | if(bEnemyIsInfantry){
| + | |
− | if(!bUseSuperHealth){
| + | |
− | VampMaxHealth = EnemyP.HealthMax;
| + | |
− | | + | |
− | if(UTPawn(injured).ShieldBeltArmor > 0){}
| + | |
− | else if(UTPawn(injured).VestArmor > 0){
| + | |
− | ConversionRatio = 0.1875;
| + | |
− | EnemyP.Health = Min(VampHealth+Damage*ConversionRatio, Max(VampHealth,VampMaxHealth));
| + | |
− | }
| + | |
− | else if(UTPawn(injured).ThighpadArmor > 0){
| + | |
− | ConversionRatio = 0.125;
| + | |
− | EnemyP.Health = Min(VampHealth+Damage*ConversionRatio, Max(VampHealth,VampMaxHealth));
| + | |
− | }
| + | |
− | else if(UTPawn(injured).HelmetArmor > 0){
| + | |
− | ConversionRatio = 0.125;
| + | |
− | EnemyP.Health = Min(VampHealth+Damage*ConversionRatio, Max(VampHealth,VampMaxHealth));
| + | |
− | }
| + | |
− | else{
| + | |
− | ConversionRatio = 0.5;
| + | |
− | EnemyP.Health = Min(VampHealth+Damage*ConversionRatio, Max(VampHealth,VampMaxHealth));
| + | |
− | }
| + | |
− | }else{
| + | |
− | VampSuperHealth = UTPawn(instigatedBy.Pawn).SuperHealthMax;
| + | |
− | | + | |
− | if(UTPawn(injured).ShieldBeltArmor > 0){}
| + | |
− | else if(UTPawn(injured).VestArmor > 0){
| + | |
− | ConversionRatio = 0.375;
| + | |
− | EnemyP.Health = Min(VampHealth+Damage*ConversionRatio, Max(VampHealth,VampSuperHealth));
| + | |
− | }
| + | |
− | else if(UTPawn(injured).ThighpadArmor > 0){
| + | |
− | ConversionRatio = 0.250;
| + | |
− | EnemyP.Health = Min(VampHealth+Damage*ConversionRatio, Max(VampHealth,VampSuperHealth));
| + | |
− | }
| + | |
− | else if(UTPawn(injured).HelmetArmor > 0){
| + | |
− | ConversionRatio = 0.250;
| + | |
− | EnemyP.Health = Min(VampHealth+Damage*ConversionRatio, Max(VampHealth,VampSuperHealth));
| + | |
− | }
| + | |
− | else{
| + | |
− | ConversionRatio = 0.35;
| + | |
− | EnemyP.Health = Min(VampHealth+Damage*ConversionRatio, Max(VampHealth,VampSuperHealth));
| + | |
− | }
| + | |
− | }
| + | |
− | | + | |
− | DifHealth = instigatedBy.Pawn.Health - VampHealth;
| + | |
− | if(DifHealth != 0){
| + | |
− | PlayerController(instigatedBy).ReceiveLocalizedMessage(class'Newtators.VampireMsg', DifHealth);
| + | |
− | // `logd("Player Health: After: "$instigatedBy.Pawn.Health);
| + | |
− | {
| + | |
− | }else if(!bEnemyIsInfantry && bUseForVehicles){
| + | |
− | if(EnemyP == Vehicle(instigatedBy.Pawn)){
| + | |
− | | + | |
− | VampHealth = Vehicle(instigatedBy.Pawn).Health;
| + | |
− | VampMaxHealth = Vehicle(instigatedBy.Pawn).HealthMax;
| + | |
− | ConversionRatio = 0.5;
| + | |
− | Vehicle(instigatedBy.Pawn).HealDamage(Damage*ConversionRatio, instigatedBy, DamageType);
| + | |
− | DifHealth = Damage*ConversionRatio;
| + | |
− | PlayerController(instigatedBy).ReceiveLocalizedMessage(class'Newtators.VampireMsg', DifHealth);
| + | |
− | // `logd("Vehicle Health: After: "$Vehicle(instigatedBy.Pawn).Health);
| + | |
− | }
| + | |
− | }
| + | |
− | }
| + | |
− | | + | |
− | defaultproperties
| + | |
− | {
| + | |
− | GRClass=Class'MutatorFramework.UTGameRules_Info'
| + | |
− | }
| + | |
− | | + | |
− | //===================================================
| + | |
− | // Class: UTD_Game_Bloodlust
| + | |
− | // Creation date: 18/12/2007 04:30
| + | |
− | // Last updated: 23/12/2008 20:01
| + | |
− | //
| + | |
− | // Attribution-Noncommercial-Share Alike 2.5 Generic
| + | |
− | // http://creativecommons.org/licenses/by-nc-sa/2.5/
| + | |
− | //===================================================
| + | |
− | class UTD_GR_Bloodlust extends UTD_GR_Vampire;
| + | |
− | | + | |
− | /*function NetDamage(int OriginalDamage, out int Damage, pawn injured, Controller instigatedBy, vector HitLocation, out vector Momentum, class<DamageType> DamageType)
| + | |
− | {
| + | |
− | if(NextGameRules != None)
| + | |
− | NextGameRules.NetDamage(OriginalDamage,Damage,injured,instigatedBy,HitLocation,Momentum,DamageType);
| + | |
− | | + | |
− | if(instigatedBy != None && InstigatedBy.Pawn != None && injured != InstigatedBy.Pawn &&
| + | |
− | (UTInventoryManager(InstigatedBy.Pawn.InvManager).HasInventoryOfClass(class'Newtators.UTVDamage') != None))
| + | |
− | {
| + | |
− | ///
| + | |
− | Super.NetDamage(OriginalDamage,Damage,injured,instigatedBy,HitLocation,Momentum,DamageType);
| + | |
− | }
| + | |
− | }
| + | |
− | | + | |
− | function bool OverridePickupQuery(Pawn Other, class<Inventory> ItemClass, Actor Pickup, out byte bAllowPickup)
| + | |
− | {
| + | |
− | local UTInventoryManager InvMgr;
| + | |
− | | + | |
− | InvMgr = UTInventoryManager(Other.InvManager);
| + | |
− | | + | |
− | if(Pickup != None && UTPawn(Other) != None)
| + | |
− | {
| + | |
− | if(InvMgr.HasInventoryOfClass(class'Newtators.UTVDamage') != None)
| + | |
− | {
| + | |
− | if(Pickup.IsA('UTPickupFactory_HealthVial') ||
| + | |
− | Pickup.IsA('UTPickupFactory_SuperHealth') ||
| + | |
− | Pickup.IsA('UTPickupFactory_MediumHealth'))
| + | |
− | return true;
| + | |
− | }
| + | |
− | }
| + | |
− | | + | |
− | if((NextGameRules != None) && NextGameRules.OverridePickupQuery(Other, ItemClass, Pickup, bAllowPickup))
| + | |
− | return true;
| + | |
− | | + | |
− | return false;
| + | |
− | }*/
| + | |
− | | + | |
− | defaultproperties
| + | |
− | {
| + | |
− | bUseSuperHealth=True
| + | |
− | | + | |
− | FactoryReplacerDataClass=Class'Newtators.Data_Bloodlust'
| + | |
− | // ReplacementFactories(0)=(ReplacedFactory="UTPickupFactory_UDamage", ReplacedWithFactory="UTPickupFactory_VDamage", ReplacedWithFactoryPath="Newtators.UTPickupFactory_VDamage")
| + | |
− | }
| + | |
− | | + | |
− | //===================================================
| + | |
− | // Class: UTVDamage
| + | |
− | // Creation date: 18/12/2007 03:58
| + | |
− | // Last updated: 22/06/2008 10:09
| + | |
− | //---------------------------------------------------
| + | |
− | // Attribution-Noncommercial-Share Alike 2.5 Generic
| + | |
− | // http://creativecommons.org/licenses/by-nc-sa/2.5/
| + | |
− | //===================================================
| + | |
− | class UTVDamage extends UTTimedPowerup_Generic;
| + | |
− | | + | |
− | //TODO: Effects for the players eyes, might need to be in info to spawn
| + | |
− | //the sockets for the player.
| + | |
− | | + | |
− | /** The Particle System Template for the Beam */
| + | |
− | var particleSystem VampEyeTemplate[2];
| + | |
− | | + | |
− | /** Holds the Emitter for the Beam */
| + | |
− | var ParticleSystemComponent VampEyeEmitter[2];
| + | |
− | | + | |
− | /** Where to attach the Beam */
| + | |
− | var name VampEyeSockets[2];
| + | |
− | | + | |
− | /** post processing applied while holding this powerup */
| + | |
− | var vector PP_Scene_MidTones;
| + | |
− | var vector PP_Scene_Shadows;
| + | |
− | | + | |
− | //TODO: Some kind of kewl semi transparent material for the player.
| + | |
− | | + | |
− | simulated static function AddWeaponOverlay(UTGameReplicationInfo GRI)
| + | |
− | {
| + | |
− | GRI.WeaponOverlays[2] = default.OverlayMaterialInstance;
| + | |
− | GRI.VehicleWeaponEffects[2] = default.VehicleWeaponEffect;
| + | |
− | }
| + | |
− | | + | |
− | /** adds or removes our bonus from the given pawn */
| + | |
− | /*simulated function AdjustPawn(UTPawn P, bool bRemoveBonus)
| + | |
− | {
| + | |
− | if(P != None && Role == ROLE_Authority)
| + | |
− | {
| + | |
− | if(!bRemoveBonus){}
| + | |
− | else{}
| + | |
− | }
| + | |
− | }*/
| + | |
− | | + | |
− | //SkeletalMeshComponent(Mesh).AttachComponentToSocket( BeamEmitter[CurrentFireMode],BeamSockets[CurrentFireMode] );
| + | |
− | //Mesh.GetSocketWorldLocationAndRotation('RocketSocket',RocketSocketL, RocketSocketR);
| + | |
− | | + | |
− | //SkeletalMeshComponent(Mesh).Attachments[i]
| + | |
− | | + | |
− | //native final function AttachComponent(ActorComponent Component,name BoneName,optional vector RelativeLocation,optional rotator RelativeRotation,optional vector RelativeScale);
| + | |
− | //native final function DetachComponent(ActorComponent Component);
| + | |
− | //native final function SkeletalMeshSocket GetSocketByName( Name InSocketName );
| + | |
− | | + | |
− | /** applies and removes any post processing effects while holding this item */
| + | |
− | simulated function AdjustPPEffects(Pawn P, bool bRemove)
| + | |
− | {
| + | |
− | local UTPlayerController PC;
| + | |
− | | + | |
− | if(P != None){
| + | |
− | PC = UTPlayerController(P.Controller);
| + | |
− | if(PC == None && P.DrivenVehicle != None){
| + | |
− | PC = UTPlayerController(P.DrivenVehicle.Controller);
| + | |
− | }
| + | |
− | if (PC != None){
| + | |
− | if(bRemove){
| + | |
− | PC.PostProcessModifier.Scene_HighLights -= PP_Scene_Highlights;
| + | |
− | PC.PostProcessModifier.Scene_MidTones -= PP_Scene_MidTones;
| + | |
− | PC.PostProcessModifier.Scene_Shadows -= PP_Scene_Shadows;
| + | |
− | }else{
| + | |
− | PC.PostProcessModifier.Scene_HighLights += PP_Scene_Highlights;
| + | |
− | PC.PostProcessModifier.Scene_MidTones += PP_Scene_MidTones;
| + | |
− | PC.PostProcessModifier.Scene_Shadows += PP_Scene_Shadows;
| + | |
− | }
| + | |
− | }
| + | |
− | }
| + | |
− | }
| + | |
− | | + | |
− | defaultproperties
| + | |
− | {
| + | |
− | AssignWeaponOverlay=2 //my values start here
| + | |
− | | + | |
− | PickupMessage="BLOODLUST!" //"VAMPYRIC DAMAGE!"
| + | |
− | | + | |
− | TimeRemaining=45.000000
| + | |
− | RespawnTime=96.000000
| + | |
− | | + | |
− | // PowerupFadingSound=SoundCue'Newtators_Pickups.VDamage.Cue.Invis_VDamage_Loop'
| + | |
− | PowerupFireSound=SoundCue'Newtators_Pickups.VDamage.Cue.VDamage_FireSound'
| + | |
− | PickupSound=SoundCue'Newtators_Pickups.VDamage.Cue.Necris_IHunger_VDamage'
| + | |
− | | + | |
− | // PowerupAmbientSound=SoundCue'A_Pickups_Powerups.PowerUps.A_Powerup_Invisibility_PowerLoopCue'
| + | |
− | PowerupAmbientSound=SoundCue'Newtators_Pickups.VDamage.Cue.Invis_VDamage_Loop'
| + | |
− | PowerupOverSound=SoundCue'Newtators_Pickups.VDamage.Cue.Invis_VDamage_End2'
| + | |
− | | + | |
− | OverlayMaterialInstance=Material'Newtators_Pickups.VDamage.M_VDamage_Overlay'
| + | |
− | VehicleWeaponEffect=(Mesh=StaticMesh'Envy_Effects.Mesh.S_VH_Powerups',Material=Material'Envy_Effects.Energy.Materials.M_VH_Beserk')
| + | |
− | PowerupStatName="POWERUPTIME_BLOODLUST"
| + | |
− | IconCoords=(U=792.000000,V=41.000000,UL=43.000000,VL=58.000000)
| + | |
− | | + | |
− | PP_Scene_HighLights=(X=-0.100000,Y=0.080000,Z=0.080000)//(X=0.180000,Y=0.200000,Z=0.200000)
| + | |
− | PP_Scene_MidTones=(X=-0.060000,Y=0.060000,Z=0.060000)//(X=-0.080000,Y=0.060000,Z=0.060000)
| + | |
− | PP_Scene_Shadows=(X=-0.030000,Y=0.030000,Z=0.030000)//(X=-0.040000,Y=0.030000,Z=0.030000)
| + | |
− | | + | |
− | bRenderOverlays=True
| + | |
− | bReceiveOwnerEvents=True
| + | |
− | | + | |
− | bCanDenyPowerup=False
| + | |
− | Begin Object Class=StaticMeshComponent Name=MeshComponentV ObjName=MeshComponentV Archetype=StaticMeshComponent'Engine.Default__StaticMeshComponent'
| + | |
− | StaticMesh=StaticMesh'PICKUPS.UDamage.Mesh.S_Pickups_UDamage'
| + | |
− | Materials(0)=Material'Newtators_Pickups.VDamage.Materials.M_Vdamage_Base'
| + | |
− | Materials(1)=Material'Newtators_Pickups.VDamage.Materials.M_Vdamage_Add'
| + | |
− | // CullDistance=8000.000000
| + | |
− | // CachedCullDistance=8000.000000
| + | |
− | bUseAsOccluder=False
| + | |
− | CastShadow=False
| + | |
− | bForceDirectLightMap=True
| + | |
− | bCastDynamicShadow=False
| + | |
− | CollideActors=False
| + | |
− | BlockRigidBody=False
| + | |
− | Translation=(X=0.000000,Y=0.000000,Z=5.000000)
| + | |
− | Scale3D=(X=0.600000,Y=0.800000,Z=0.600000)//Scale3D=(X=0.600000,Y=0.600000,Z=0.600000)
| + | |
− | End Object
| + | |
− | DroppedPickupMesh=MeshComponentV
| + | |
− | PickupFactoryMesh=MeshComponentV
| + | |
− | Begin Object Class=UTParticleSystemComponent Name=PickupParticles ObjName=PickupParticles Archetype=UTParticleSystemComponent'UTGame.Default__UTParticleSystemComponent'
| + | |
− | Template=ParticleSystem'Newtators_Pickups.VDamage.Effects.P_Pickups_VDamage_Idle'
| + | |
− | bAutoActivate=False
| + | |
− | Translation=(X=0.000000,Y=0.000000,Z=5.000000)
| + | |
− | SecondsBeforeInactive=1.0f
| + | |
− | End Object
| + | |
− | DroppedPickupParticles=PickupParticles
| + | |
− | }
| + | |
− | | + | |
− | //===================================================
| + | |
− | // Class: UTBooster
| + | |
− | // Creation date: 18/12/2007 02:23
| + | |
− | // Last updated: 22/06/2008 10:09
| + | |
− | //---------------------------------------------------
| + | |
− | // Attribution-Noncommercial-Share Alike 2.5 Generic
| + | |
− | // http://creativecommons.org/licenses/by-nc-sa/2.5/
| + | |
− | //===================================================
| + | |
− | class UTBooster extends UTTimedPowerup_Generic;
| + | |
− | | + | |
− | var UTPawn Pawnt;
| + | |
− | | + | |
− | | + | |
− | simulated static function AddWeaponOverlay(UTGameReplicationInfo GRI){}
| + | |
− | | + | |
− | /** adds or removes our bonus from the given pawn */
| + | |
− | simulated function AdjustPawn(UTPawn P, bool bRemoveBonus)
| + | |
− | {
| + | |
− | if(P != None && Role == ROLE_Authority)
| + | |
− | {
| + | |
− | Pawnt = P;
| + | |
− | | + | |
− | if(!bRemoveBonus)
| + | |
− | {
| + | |
− | Pawnt.Spawn(class'Newtators.UTInfo_Booster',Pawnt);
| + | |
− | SetTimer(4.6, True, 'GiveHealth');
| + | |
− | }
| + | |
− | else
| + | |
− | {
| + | |
− | SetTimer(0.6, False, 'GiveHealth');
| + | |
− | }
| + | |
− | }
| + | |
− | }
| + | |
− | | + | |
− | function GiveHealth()
| + | |
− | {
| + | |
− | if(Pawnt != None)
| + | |
− | {
| + | |
− | if(Pawnt.Health >= Pawnt.SuperHealthMax)
| + | |
− | Pawnt.Health = Pawnt.SuperHealthMax;
| + | |
− | else
| + | |
− | Pawnt.Health = Pawnt.Health + 10;
| + | |
− | }
| + | |
− | }
| + | |
− | | + | |
− | defaultproperties
| + | |
− | {
| + | |
− | TimeRemaining=45.000000 //30,60
| + | |
− | WarningTime=6.000000
| + | |
− | RespawnTime=110.000000 //90
| + | |
− | | + | |
− | bCanDenyPowerup=True
| + | |
− | bHavePowerup=True
| + | |
− | | + | |
− | PowerupFadingSound=SoundCue'Newtators_Pickups.Booster.Cue.BoosterFading'
| + | |
− | PickupSound=SoundCue'Newtators_Pickups.Booster.Cue.BoosterPickup'
| + | |
− | PowerupAmbientSound=SoundCue'Newtators_Pickups.Booster.Cue.BoosterLoop'
| + | |
− | // PowerupOverSound=SoundCue'Newtators_Pickups.VDamage.Cue.Invis_VDamage_End2'
| + | |
− | | + | |
− | /*
| + | |
− | OverlayMaterialInstance=Material'PICKUPS.Berserk.M_Berserk_Overlay'
| + | |
− | VehicleWeaponEffect=(Mesh=StaticMesh'Envy_Effects.Mesh.S_VH_Powerups',Material=Material'Envy_Effects.Energy.Materials.M_VH_Beserk')
| + | |
− | HudIndex=1
| + | |
− | PowerupOverSound=SoundCue'A_Pickups_Powerups.PowerUps.A_Powerup_Berzerk_EndCue'*/
| + | |
− | PowerupStatName="POWERUPTIME_BOOSTER"
| + | |
− | IconCoords=(U=744.000000,UL=35.000000,VL=55.000000)
| + | |
− | PP_Scene_HighLights=(X=0.000000,Y=0.300000,Z=0.000000)//(X=-0.150000,Y=0.180000,Z=-0.150000)
| + | |
− | // bRenderOverlays=True
| + | |
− | bReceiveOwnerEvents=True
| + | |
− | PickupMessage="BOOSTER!"
| + | |
− | // PickupSound=SoundCue'A_Pickups_Powerups.PowerUps.A_Powerup_Berzerk_PickupCue'
| + | |
− | Begin Object Class=StaticMeshComponent Name=MeshComponentA ObjName=MeshComponentA Archetype=StaticMeshComponent'Engine.Default__StaticMeshComponent'
| + | |
− | StaticMesh=StaticMesh'PICKUPS.Berserk.Mesh.S_Pickups_Berserk'
| + | |
− | Materials(0)=Material'Newtators_Pickups.Booster.Materials.M_Booster'
| + | |
− | CullDistance=8000.000000
| + | |
− | CachedCullDistance=8000.000000
| + | |
− | bUseAsOccluder=False
| + | |
− | CastShadow=False
| + | |
− | bForceDirectLightMap=True
| + | |
− | bCastDynamicShadow=False
| + | |
− | CollideActors=False
| + | |
− | BlockRigidBody=False
| + | |
− | Translation=(X=0.000000,Y=0.000000,Z=5.000000)
| + | |
− | Scale3D=(X=0.700000,Y=0.700000,Z=0.700000)
| + | |
− | // Name="MeshComponentA"
| + | |
− | // ObjectArchetype=StaticMeshComponent'Engine.Default__StaticMeshComponent'
| + | |
− | End Object
| + | |
− | DroppedPickupMesh=MeshComponentA
| + | |
− | PickupFactoryMesh=MeshComponentA
| + | |
− | | + | |
− | /* Begin Object Class=UTParticleSystemComponent Name=BerserkParticles ObjName=BerserkParticles Archetype=UTParticleSystemComponent'UTGame.Default__UTParticleSystemComponent'
| + | |
− | Template=ParticleSystem'PICKUPS.Berserk.Effects.P_Pickups_Berserk_Idle'
| + | |
− | bAutoActivate=False
| + | |
− | Translation=(X=0.000000,Y=0.000000,Z=5.000000)
| + | |
− | Name="BerserkParticles"
| + | |
− | ObjectArchetype=UTParticleSystemComponent'UTGame.Default__UTParticleSystemComponent'
| + | |
− | End Object
| + | |
− | DroppedPickupParticles=BerserkParticles*/
| + | |
− | // Name="Default__UTBooster"
| + | |
− | // ObjectArchetype=UTTimedPowerup_Generic'MutatorFramework.Default__UTTimedPowerup_Generic'
| + | |
− | }
| + | |
− | | + | |
− | //===================================================
| + | |
− | // Class: EnergyLeechMsg
| + | |
− | // Creation date: 10/06/2008 17:08
| + | |
− | //---------------------------------------------------
| + | |
− | // Attribution-Noncommercial-Share Alike 2.5 Generic
| + | |
− | // http://creativecommons.org/licenses/by-nc-sa/2.5/
| + | |
− | //===================================================
| + | |
− | class EnergyLeechMsg extends VampireMsg;
| + | |
− | | + | |
− | var(Message) color Gold, Silver;
| + | |
− | | + | |
− | /*static function string GetString(
| + | |
− | optional int Switch,
| + | |
− | optional bool bPRI1HUD,
| + | |
− | optional PlayerReplicationInfo RelatedPRI_1,
| + | |
− | optional PlayerReplicationInfo RelatedPRI_2,
| + | |
− | optional Object OptionalObject
| + | |
− | )
| + | |
− | {
| + | |
− | if(Switch > 0)
| + | |
− | return "+"$Switch;
| + | |
− | else
| + | |
− | return ""$Switch;
| + | |
− | }*/
| + | |
− | | + | |
− | static function color GetColor(
| + | |
− | optional int Switch,
| + | |
− | optional PlayerReplicationInfo RelatedPRI_1,
| + | |
− | optional PlayerReplicationInfo RelatedPRI_2,
| + | |
− | optional Object OptionalObject
| + | |
− | )
| + | |
− | {
| + | |
− | if(Switch > 0)
| + | |
− | return default.Gold;
| + | |
− | | + | |
− | return default.Silver;
| + | |
− | }
| + | |
− | | + | |
− | defaultproperties
| + | |
− | {
| + | |
− | Gold=(B=10,G=80,R=170,A=255)
| + | |
− | Silver=(B=100,G=100,R=100,A=255)
| + | |
− | // bBeep=False
| + | |
− | // Lifetime=1.000000
| + | |
− | // PosY=0.650000 //0.650000
| + | |
− | // FontSize=2
| + | |
− | }
| + | |
− | | + | |
− | //===================================================
| + | |
− | // Class: VampireMsg
| + | |
− | // Creation date: 10/06/2008 11:48
| + | |
− | // Last updated: 10/06/2008 11:48
| + | |
− | //---------------------------------------------------
| + | |
− | // Attribution-Noncommercial-Share Alike 2.5 Generic
| + | |
− | // http://creativecommons.org/licenses/by-nc-sa/2.5/
| + | |
− | //===================================================
| + | |
− | class VampireMsg extends LocalMessage;
| + | |
− | | + | |
− | var(Message) color Green, Red;
| + | |
− | | + | |
− | static function string GetString(
| + | |
− | optional int Switch,
| + | |
− | optional bool bPRI1HUD,
| + | |
− | optional PlayerReplicationInfo RelatedPRI_1,
| + | |
− | optional PlayerReplicationInfo RelatedPRI_2,
| + | |
− | optional Object OptionalObject
| + | |
− | )
| + | |
− | {
| + | |
− | if(Switch > 0)
| + | |
− | return "+"$Switch;
| + | |
− | else
| + | |
− | return ""$Switch;
| + | |
− | }
| + | |
− | | + | |
− | static function color GetColor(
| + | |
− | optional int Switch,
| + | |
− | optional PlayerReplicationInfo RelatedPRI_1,
| + | |
− | optional PlayerReplicationInfo RelatedPRI_2,
| + | |
− | optional Object OptionalObject
| + | |
− | )
| + | |
− | {
| + | |
− | if(Switch > 0)
| + | |
− | return default.Green;
| + | |
− | | + | |
− | return default.Red;
| + | |
− | }
| + | |
− | | + | |
− | defaultproperties
| + | |
− | {
| + | |
− | Green=(B=0,G=255,R=0,A=255)
| + | |
− | Red=(B=0,G=0,R=255,A=255)
| + | |
− | bBeep=False
| + | |
− | Lifetime=1.000000
| + | |
− | PosY=0.650000 //0.650000
| + | |
− | FontSize=2
| + | |
− | }
| + | |
− | | + | |
− | | + | |
− | //===================================================
| + | |
− | // Class: UTUIFrontEnd_VehicleTeamSwap
| + | |
− | // Creation Date: 04/12/2007 22:21
| + | |
− | //---------------------------------------------------
| + | |
− | // Attribution-Noncommercial-Share Alike 2.5 Generic
| + | |
− | // http://creativecommons.org/licenses/by-nc-sa/2.5/
| + | |
− | //===================================================
| + | |
− | class UTUIFrontEnd_VehicleTeamSwap extends UTUIFrontEnd_Generic;
| + | |
− | | + | |
− | var transient UTUICollectionCheckBox bBlueIsNecris;
| + | |
− | var transient UTUICollectionCheckBox bRedIsNecris;
| + | |
− | | + | |
− | event SceneActivated(bool bInitialActivation)
| + | |
− | {
| + | |
− | Super.SceneActivated(bInitialActivation);
| + | |
− | | + | |
− | if(bInitialActivation)
| + | |
− | {
| + | |
− | bRedIsNecris = UTUICollectionCheckBox(FindChild('cbxTeam2', true));
| + | |
− | bBlueIsNecris = UTUICollectionCheckBox(FindChild('cbxTeam1', true));
| + | |
− | | + | |
− | bRedIsNecris.SetValue(class'Newtators.UTMutator_VehicleTeamSwap'.default.TeamCore[0].bTeamIsNecris);
| + | |
− | bBlueIsNecris.SetValue(class'Newtators.UTMutator_VehicleTeamSwap'.default.TeamCore[1].bTeamIsNecris);
| + | |
− | }
| + | |
− | }
| + | |
− | | + | |
− | /** Callback for when the user accepts the changes. */
| + | |
− | function OnAccept()
| + | |
− | {
| + | |
− | class'Newtators.UTMutator_VehicleTeamSwap '.default.TeamCore[0].bTeamIsNecris = bRedIsNecris.IsChecked();
| + | |
− | class'Newtators.UTMutator_VehicleTeamSwap '.default.TeamCore[1].bTeamIsNecris = bBlueIsNecris.IsChecked();
| + | |
− | class'Newtators.UTMutator_VehicleTeamSwap '.static.StaticSaveConfig();
| + | |
− | | + | |
− | CloseScene(self);
| + | |
− | }
| + | |
− | | + | |
− | defaultproperties
| + | |
− | {
| + | |
− | MutTitle="Vehicle Team Swap"
| + | |
− | }
| + | |
− | | + | |
− | //===================================================
| + | |
− | // Class: UTUIFrontEnd_VehicleReplacerMenu
| + | |
− | // Creation Date: 30/11/2007 22:21
| + | |
− | // Last Updated: 10/08/2008 23:11
| + | |
− | //---------------------------------------------------
| + | |
− | // Attribution-Noncommercial-Share Alike 2.5 Generic
| + | |
− | // http://creativecommons.org/licenses/by-nc-sa/2.5/
| + | |
− | //===================================================
| + | |
− | class UTUIFrontEnd_VehicleReplacerMenu extends UTUIFrontEnd_Generic
| + | |
− | dependson(UTMutator_VehicleReplacer);
| + | |
− | | + | |
− | //---------------------------------------------------
| + | |
− | /** List of available maps. */
| + | |
− | //var transient UIList AvailableList;
| + | |
− | | + | |
− | /** The last focused UI List. */
| + | |
− | //var transient UIList LastFocused;
| + | |
− | | + | |
− | /** Label describing the currently selected map. */
| + | |
− | //var transient UILabel DescriptionLabel;
| + | |
− | | + | |
− | /** Reference to the menu datastore */
| + | |
− | //var transient UTUIDataStore_MenuItems MenuDataStore;
| + | |
− | //---------------------------------------------------
| + | |
− | | + | |
− | /** Replacement info. */
| + | |
− | var transient array<ReplacementInfo> VehiclesToReplace;
| + | |
− | | + | |
− | /** Reference to option list. */
| + | |
− | var transient UTUIOptionList OptionList;
| + | |
− | | + | |
− | /** Reference to the options datastore. */
| + | |
− | var transient UTUIDataStore_Options OptionsDataStore;
| + | |
− | | + | |
− | /** Reference to the string list datastore. */
| + | |
− | var transient UTUIDataStore_StringList StringListDataStore;
| + | |
− | | + | |
− | /** Reference to the menu item datastore. */
| + | |
− | //var transient UTUIDataStore_MenuItems MenuItemDataStore;
| + | |
− | var transient UTUIDataStore_NewMenuItems VehicleDataStore;
| + | |
− | | + | |
− | /** List of possible Vehicle classes. */
| + | |
− | var transient array<string> VehicleClassNames;
| + | |
− | var transient array<string> VehicleFriendlyNames;
| + | |
− | var transient array<UTUIDataProvider_Vehicles> VehicleProviders;
| + | |
− | | + | |
− | //var GameResourceDataProvider ProviderInfo;
| + | |
− | //---------------------------------------------------
| + | |
− | | + | |
− | event PostInitialize()
| + | |
− | {
| + | |
− | Super.PostInitialize();
| + | |
− | | + | |
− | //---------------------------------------------------
| + | |
− | // Store widget references
| + | |
− | /*
| + | |
− | AvailableList = UIList(FindChild('lstAvailable', true));
| + | |
− | LastFocused = AvailableList;
| + | |
− | AvailableList.OnValueChanged = OnAvailableList_ValueChanged;
| + | |
− | AvailableList.OnSubmitSelection = OnAvailableList_SubmitSelection;
| + | |
− | AvailableList.NotifyActiveStateChanged = OnAvailableList_NotifyActiveStateChanged;
| + | |
− | AvailableList.OnRawInputKey = OnMapList_RawInputKey;
| + | |
− | | + | |
− | DescriptionLabel = UILabel(FindChild('lblDescription', true));
| + | |
− | | + | |
− | // Get reference to the menu datastore
| + | |
− | MenuDataStore = UTUIDataStore_MenuItems(GetCurrentUIController().DataStoreManager.FindDataStore('UTMenuItems'));
| + | |
− | */
| + | |
− | // LoadMapCycle();
| + | |
− | | + | |
− | //---------------------------------------------------
| + | |
− | // `log("PostInitialize()",,'VehicleReplacer');
| + | |
− | VehiclesToReplace = class'UTMutator_VehicleReplacer'.default.VehiclesToReplace;
| + | |
− | | + | |
− | OptionList = UTUIOptionList(FindChild('lstOptions', true));
| + | |
− | OptionList.OnAcceptOptions=OnAcceptOptions;
| + | |
− | | + | |
− | // Get datastore references
| + | |
− | OptionsDataStore = UTUIDataStore_Options(FindDataStore('UTOptions'));
| + | |
− | StringListDataStore = UTUIDataStore_StringList(FindDataStore('UTStringList'));
| + | |
− | // MenuItemDataStore = UTUIDataStore_MenuItems(FindDataStore('UTMenuItems'));
| + | |
− | // VehicleDataStore = UTUIDataStore_Vehicle(FindDataStore('Vehicle'));
| + | |
− | VehicleDataStore = new(self) class'Newtators.UTUIDataStore_NewMenuItems';
| + | |
− | | + | |
− | BuildVehicleOptions();
| + | |
− | }
| + | |
− | | + | |
− | //---------------------------------------------------
| + | |
− | /** Updates the description label. */
| + | |
− | /*function UpdateDescriptionLabel()
| + | |
− | {
| + | |
− | local string NewDescription;
| + | |
− | local int SelectedItem;
| + | |
− | | + | |
− | SelectedItem = LastFocused.GetCurrentItem();
| + | |
− | | + | |
− | if(class'UTUIMenuList'.static.GetCellFieldString(LastFocused, 'Description', SelectedItem, NewDescription))
| + | |
− | {
| + | |
− | DescriptionLabel.SetDataStoreBinding(NewDescription);
| + | |
− | }
| + | |
− | }*/
| + | |
− | | + | |
− | //---------------------------------------------------
| + | |
− | /** Actiated event for the scene. */
| + | |
− | event SceneActivated(bool bInitialActivation)
| + | |
− | {
| + | |
− | // `log("SceneActivated()",,'VehicleReplacer');
| + | |
− | Super.SceneActivated(bInitialActivation);
| + | |
− | | + | |
− | OptionList.SetFocus(none);
| + | |
− | }
| + | |
− | | + | |
− | /** Callback for when the option list is accepted. */
| + | |
− | function OnAcceptOptions(UIScreenObject InObj, int PlayerIndex)
| + | |
− | {
| + | |
− | OnAccept();
| + | |
− | }
| + | |
− | | + | |
− | /** Builds the vehicle option lists. */
| + | |
− | function BuildVehicleOptions()
| + | |
− | {
| + | |
− | local int VehicleIdx;
| + | |
− | local int SelectedIdx;
| + | |
− | local int NameIdx;
| + | |
− | local array<UTUIResourceDataProvider> OutProviders;
| + | |
− | local array<UTUIResourceDataProvider> VehicleOptions;
| + | |
− | local bool bAddVehicle;
| + | |
− | local string ClassPath;
| + | |
− | | + | |
− | // Build a list of vehicles
| + | |
− | VehicleProviders.length = 0;
| + | |
− | VehicleClassNames.length = 0;
| + | |
− | VehicleFriendlyNames.length = 0;
| + | |
− | | + | |
− | // `log("BuildVehicleOptions()",,'VehicleReplacer');
| + | |
− | | + | |
− | VehicleDataStore.GetAllResourceDataProviders(class'UTUIDataProvider_Vehicles', OutProviders);
| + | |
− | // if(MenuItemDataStore.GetProviderSet('Vehicles', OutProviders))
| + | |
− | // if(VehicleDataStore.GetProviderSet('Vehicle', OutProviders))
| + | |
− | // {
| + | |
− | for(VehicleIdx=0; VehicleIdx<OutProviders.length; VehicleIdx++)
| + | |
− | {
| + | |
− | bAddVehicle=true;
| + | |
− | | + | |
− | ClassPath = UTUIDataProvider_Vehicles(OutProviders[VehicleIdx]).ClassName;
| + | |
− | // `log("Class1: "$ClassPath,,'VehicleReplacer');
| + | |
− | // Remove content weapons from console
| + | |
− | // if (class'WorldInfo'.static.IsConsoleBuild() && Left(ClassPath, 14) ~= "UTGameContent.")
| + | |
− | // {
| + | |
− | // bAddVehicle=false;
| + | |
− | // }
| + | |
− | | + | |
− | if(bAddVehicle)
| + | |
− | {
| + | |
− | VehicleProviders.AddItem(UTUIDataProvider_Vehicles(OutProviders[VehicleIdx]));
| + | |
− | VehicleClassNames.AddItem(ClassPath);
| + | |
− | VehicleFriendlyNames.AddItem(UTUIDataProvider_Vehicles(OutProviders[VehicleIdx]).FriendlyName);
| + | |
− | }
| + | |
− | }
| + | |
− | // }
| + | |
− | | + | |
− | // Generate weapon set if we havent already.
| + | |
− | OptionsDataStore.GetSet('ReplacerVehicles', VehicleOptions);
| + | |
− | | + | |
− | if(VehicleOptions.length==0)
| + | |
− | {
| + | |
− | OptionsDataStore.AppendToSet('ReplacerVehicles', VehicleFriendlyNames.length);
| + | |
− | OptionsDataStore.GetSet('ReplacerVehicles', VehicleOptions);
| + | |
− | | + | |
− | // Generate set of options and set of possible values
| + | |
− | for(VehicleIdx=0; VehicleIdx<VehicleFriendlyNames.length; VehicleIdx++)
| + | |
− | {
| + | |
− | ClassPath = GetClassFieldName(VehicleClassNames[VehicleIdx]);
| + | |
− | | + | |
− | UTUIDataProvider_MenuOption(VehicleOptions[VehicleIdx]).DataStoreMarkup = "<UTStringList:"$ClassPath$">";
| + | |
− | UTUIDataProvider_MenuOption(VehicleOptions[VehicleIdx]).CustomFriendlyName = VehicleFriendlyNames[VehicleIdx];
| + | |
− | // `log("Generate:: Class: "$ClassPath$", Name: "$VehicleFriendlyNames[VehicleIdx],,'VehicleReplacer');
| + | |
− | | + | |
− | StringListDataStore.Empty(name(ClassPath));
| + | |
− | for(NameIdx=0; NameIdx<VehicleFriendlyNames.length; NameIdx++)
| + | |
− | {
| + | |
− | StringListDataStore.AddStr(name(ClassPath), VehicleFriendlyNames[NameIdx]);
| + | |
− | }
| + | |
− | | + | |
− | StringListDataStore.SetCurrentValueIndex(name(ClassPath), VehicleIdx);
| + | |
− | }
| + | |
− | | + | |
− | OptionList.bRegenOptions=true;
| + | |
− | }
| + | |
− | else
| + | |
− | {
| + | |
− | for(VehicleIdx=0; VehicleIdx<VehicleFriendlyNames.length; VehicleIdx++)
| + | |
− | {
| + | |
− | ClassPath = GetClassFieldName(VehicleClassNames[VehicleIdx]);
| + | |
− | // `log("Class: "$ClassPath,,'VehicleReplacer');
| + | |
− | StringListDataStore.SetCurrentValueIndex(name(ClassPath), VehicleIdx);
| + | |
− | }
| + | |
− | }
| + | |
− | | + | |
− | // Set defaults
| + | |
− | for(VehicleIdx=0; VehicleIdx<VehiclesToReplace.length; VehicleIdx++)
| + | |
− | {
| + | |
− | for(SelectedIdx=0; SelectedIdx<VehicleClassNames.length; SelectedIdx++)
| + | |
− | {
| + | |
− | if(VehiclesToReplace[VehicleIdx].NewClassPath==VehicleClassNames[SelectedIdx])
| + | |
− | {
| + | |
− | ClassPath = GetClassFieldName(string(VehiclesToReplace[VehicleIdx].OldClassName));
| + | |
− | // `log("default Class: "$ClassPath,,'VehicleReplacer');
| + | |
− | StringListDataStore.SetCurrentValueIndex(name(ClassPath), SelectedIdx);
| + | |
− | }
| + | |
− | }
| + | |
− | }
| + | |
− | | + | |
− | OptionList.RefreshAllOptions();
| + | |
− | }
| + | |
− | | + | |
− | /** @return string Returns a fieldname given a weapon class name. */
| + | |
− | function string GetClassFieldName(string ClassName)
| + | |
− | {
| + | |
− | ClassName = Right(ClassName, Len(ClassName) - InStr(ClassName, ".") - 1);
| + | |
− | ClassName = Repl(ClassName, ".", "_");
| + | |
− | ClassName = "ReplaceVehicle_"$ClassName;
| + | |
− | return ClassName;
| + | |
− | }
| + | |
− | | + | |
− | /** Callback for when the user accepts the changes. */
| + | |
− | function OnAccept()
| + | |
− | {
| + | |
− | local int VehicleIdx;
| + | |
− | local string ClassPath;
| + | |
− | local int SelectedIdx;
| + | |
− | | + | |
− | // `log("OnAccept()",,'VehicleReplacer');
| + | |
− | | + | |
− | VehiclesToReplace.length=0;
| + | |
− | | + | |
− | for(VehicleIdx=0; VehicleIdx<VehicleClassNames.length; VehicleIdx++)
| + | |
− | {
| + | |
− | ClassPath=GetClassFieldName(VehicleClassNames[VehicleIdx]);
| + | |
− | SelectedIdx=StringListDataStore.GetCurrentValueIndex(name(ClassPath));
| + | |
− | // `log("Class"$SelectedIdx$": "$ClassPath,,'VehicleReplacer');
| + | |
− | | + | |
− | if(SelectedIdx!=VehicleIdx)
| + | |
− | {
| + | |
− | VehiclesToReplace.length=VehiclesToReplace.length+1;
| + | |
− | VehiclesToReplace[VehiclesToReplace.length-1].NewClassPath = VehicleProviders[SelectedIdx].ClassName;
| + | |
− | // `log("Vehicle New Class: "$VehiclesToReplace[VehiclesToReplace.length-1].NewClassPath,,'VehicleReplacer');
| + | |
− | VehiclesToReplace[VehiclesToReplace.length-1].OldClassName = name(Right(VehicleProviders[VehicleIdx].ClassName, Len(VehicleProviders[VehicleIdx].ClassName) - InStr(VehicleProviders[VehicleIdx].ClassName, ".") - 1));
| + | |
− | // `log("Vehicle Old Class: "$VehiclesToReplace[VehiclesToReplace.length-1].OldClassName,,'VehicleReplacer');
| + | |
− | }
| + | |
− | }
| + | |
− | | + | |
− | class'UTMutator_VehicleReplacer'.default.VehiclesToReplace = VehiclesToReplace;
| + | |
− | class'UTMutator_VehicleReplacer'.static.StaticSaveConfig();
| + | |
− | | + | |
− | CloseScene(self);
| + | |
− | }
| + | |
− | | + | |
− | defaultproperties
| + | |
− | {
| + | |
− | MutTitle="Vehicle Replacer"
| + | |
− | Begin Object /*Class=UIComp_Event*/ Name=SceneEventComponent ObjName=SceneEventComponent Archetype=UIComp_Event'UTGame.Default__UTUIFrontEnd:SceneEventComponent'
| + | |
− | ObjectArchetype=UIComp_Event'UTGame.Default__UTUIFrontEnd:SceneEventComponent'
| + | |
− | End Object
| + | |
− | EventProvider=SceneEventComponent
| + | |
− | }
| + | |
− | | + | |
− | //===================================================
| + | |
− | // Class: UTUIFrontEnd_VampireMenu
| + | |
− | // Creation Date: 30/11/2007 22:21
| + | |
− | //---------------------------------------------------
| + | |
− | // Attribution-Noncommercial-Share Alike 2.5 Generic
| + | |
− | // http://creativecommons.org/licenses/by-nc-sa/2.5/
| + | |
− | //===================================================
| + | |
− | class UTUIFrontEnd_VampireMenu extends UTUIFrontEnd_Generic;
| + | |
− | | + | |
− | var transient UTUICollectionCheckBox bSuperHealth, bVehicleVamp;
| + | |
− | | + | |
− | event SceneActivated(bool bInitialActivation)
| + | |
− | {
| + | |
− | Super.SceneActivated(bInitialActivation);
| + | |
− | | + | |
− | if (bInitialActivation)
| + | |
− | {
| + | |
− | bSuperHealth = UTUICollectionCheckBox(FindChild('cbxHealth', true));
| + | |
− | bSuperHealth.SetValue(class'Newtators.UTGameRules_Vampire'.default.bUseSuperHealth);
| + | |
− | bVehicleVamp = UTUICollectionCheckBox(FindChild('cbxVehicles', true));
| + | |
− | bVehicleVamp.SetValue(class'Newtators.UTGameRules_Vampire'.default.bUseForVehicles);
| + | |
− | }
| + | |
− | }
| + | |
− | | + | |
− | /** Callback for when the user accepts the changes. */
| + | |
− | function OnAccept()
| + | |
− | {
| + | |
− | class'Newtators.UTGameRules_Vampire'.default.bUseSuperHealth = bSuperHealth.IsChecked();
| + | |
− | class'Newtators.UTGameRules_Vampire'.default.bUseForVehicles = bVehicleVamp.IsChecked();
| + | |
− | class'Newtators.UTGameRules_Vampire'.static.StaticSaveConfig();
| + | |
− | | + | |
− | CloseScene(self);
| + | |
− | }
| + | |
− | | + | |
− | defaultproperties
| + | |
− | {
| + | |
− | MutTitle="Vampire"
| + | |
− | }
| + | |
− | | + | |
− | //===================================================
| + | |
− | // Class: UTUIFrontEnd_HoardingMenu
| + | |
− | // Creation Date: 01/02/2008 02:14
| + | |
− | //---------------------------------------------------
| + | |
− | // Attribution-Noncommercial-Share Alike 2.5 Generic
| + | |
− | // http://creativecommons.org/licenses/by-nc-sa/2.5/
| + | |
− | //===================================================
| + | |
− | class UTUIFrontEnd_HoardingMenu extends UTUIFrontEnd_Generic;
| + | |
− | | + | |
− | var transient UTUICollectionCheckBox bHoardArmour;
| + | |
− | var transient UTUICollectionCheckBox bHoardHealth;
| + | |
− | var transient UTUICollectionCheckBox bHoardPowerups;
| + | |
− | var transient UTUICollectionCheckBox bHoardAmmo;
| + | |
− | var transient UTUICollectionCheckBox bHoardWeapons;
| + | |
− | | + | |
− | event SceneActivated(bool bInitialActivation)
| + | |
− | {
| + | |
− | Super.SceneActivated(bInitialActivation);
| + | |
− | | + | |
− | if (bInitialActivation)
| + | |
− | {
| + | |
− | bHoardArmour = UTUICollectionCheckBox(FindChild('cbxHoardArmour', true));
| + | |
− | bHoardHealth = UTUICollectionCheckBox(FindChild('cbxHoardHealth', true));
| + | |
− | bHoardPowerups = UTUICollectionCheckBox(FindChild('cbxHoardPowerups', true));
| + | |
− | bHoardAmmo = UTUICollectionCheckBox(FindChild('cbxHoardAmmo', true));
| + | |
− | bHoardWeapons = UTUICollectionCheckBox(FindChild('cbxHoardWeapons', true));
| + | |
− | | + | |
− | bHoardArmour.SetValue(class'Newtators.UTGameRules_Hoarding'.default.bCanHoardArmour);
| + | |
− | bHoardHealth.SetValue(class'Newtators.UTGameRules_Hoarding'.default.bCanHoardHealth);
| + | |
− | bHoardPowerups.SetValue(class'Newtators.UTGameRules_Hoarding'.default.bCanHoardPowerups);
| + | |
− | bHoardAmmo.SetValue(class'Newtators.UTGameRules_Hoarding'.default.bCanHoardAmmo);
| + | |
− | bHoardWeapons.SetValue(class'Newtators.UTMutator_NoHoarding'.default.bHoardWeaponStay);
| + | |
− | }
| + | |
− | }
| + | |
− | | + | |
− | /** Callback for when the user accepts the changes. */
| + | |
− | function OnAccept()
| + | |
− | {
| + | |
− | class'Newtators.UTGameRules_Hoarding'.default.bCanHoardArmour = bHoardArmour.IsChecked();
| + | |
− | class'Newtators.UTGameRules_Hoarding'.default.bCanHoardHealth = bHoardHealth.IsChecked();
| + | |
− | class'Newtators.UTGameRules_Hoarding'.default.bCanHoardPowerups = bHoardPowerups.IsChecked();
| + | |
− | class'Newtators.UTGameRules_Hoarding'.default.bCanHoardAmmo = bHoardAmmo.IsChecked();
| + | |
− | class'Newtators.UTMutator_NoHoarding'.default.bHoardWeaponStay = bHoardWeapons.IsChecked();
| + | |
− | class'Newtators.UTGameRules_Hoarding'.static.StaticSaveConfig();
| + | |
− | | + | |
− | CloseScene(self);
| + | |
− | }
| + | |
− | | + | |
− | defaultproperties
| + | |
− | {
| + | |
− | MutTitle="Hoarding"
| + | |
− | }
| + | |
− | | + | |
− | //===================================================
| + | |
− | // Class: UTUIFrontEnd_EnergyLeechMenu
| + | |
− | // Creation Date: 30/11/2007 22:21
| + | |
− | //---------------------------------------------------
| + | |
− | // Attribution-Noncommercial-Share Alike 2.5 Generic
| + | |
− | // http://creativecommons.org/licenses/by-nc-sa/2.5/
| + | |
− | //===================================================
| + | |
− | class UTUIFrontEnd_EnergyLeechMenu extends UTUIFrontEnd_Generic;
| + | |
− | | + | |
− | var transient UTUICollectionCheckBox bShieldBelt;
| + | |
− | var transient UTUICollectionCheckBox bVestArmour;
| + | |
− | var transient UTUICollectionCheckBox bThighpadArmor;
| + | |
− | var transient UTUICollectionCheckBox bHelmetArmor;
| + | |
− | var transient UTUICollectionCheckBox bVehicleLeech;
| + | |
− | | + | |
− | event SceneActivated(bool bInitialActivation)
| + | |
− | {
| + | |
− | Super.SceneActivated(bInitialActivation);
| + | |
− | | + | |
− | if (bInitialActivation)
| + | |
− | {
| + | |
− | bShieldBelt = UTUICollectionCheckBox(FindChild('cbxShieldBelt', true));
| + | |
− | bVestArmour = UTUICollectionCheckBox(FindChild('cbxVestArmour', true));
| + | |
− | bThighpadArmor = UTUICollectionCheckBox(FindChild('cbxThighpadArmor', true));
| + | |
− | bHelmetArmor = UTUICollectionCheckBox(FindChild('cbxHelmetArmor', true));
| + | |
− | bVehicleLeech = UTUICollectionCheckBox(FindChild('cbxVehicles', true));
| + | |
− | bShieldBelt.SetValue(class'Newtators.UTGameRules_EnergyLeech'.default.bUseShieldBelt);
| + | |
− | bVestArmour.SetValue(class'Newtators.UTGameRules_EnergyLeech'.default.bUseVestArmour);
| + | |
− | bThighpadArmor.SetValue(class'Newtators.UTGameRules_EnergyLeech'.default.bUseThighpadArmor);
| + | |
− | bHelmetArmor.SetValue(class'Newtators.UTGameRules_EnergyLeech'.default.bUseHelmetArmor);
| + | |
− | bVehicleLeech.SetValue(class'Newtators.UTGameRules_EnergyLeech'.default.bUseForVehicles);
| + | |
− | }
| + | |
− | }
| + | |
− | | + | |
− | /** Callback for when the user accepts the changes. */
| + | |
− | function OnAccept()
| + | |
− | {
| + | |
− | class'Newtators.UTGameRules_EnergyLeech'.default.bUseShieldBelt = bShieldBelt.IsChecked();
| + | |
− | class'Newtators.UTGameRules_EnergyLeech'.default.bUseVestArmour = bVestArmour.IsChecked();
| + | |
− | class'Newtators.UTGameRules_EnergyLeech'.default.bUseThighpadArmor = bThighpadArmor.IsChecked();
| + | |
− | class'Newtators.UTGameRules_EnergyLeech'.default.bUseHelmetArmor = bHelmetArmor.IsChecked();
| + | |
− | class'Newtators.UTGameRules_EnergyLeech'.default.bUseForVehicles = bVehicleLeech.IsChecked();
| + | |
− | class'Newtators.UTGameRules_EnergyLeech'.static.StaticSaveConfig();
| + | |
− | | + | |
− | CloseScene(self);
| + | |
− | }
| + | |
− | | + | |
− | defaultproperties
| + | |
− | {
| + | |
− | MutTitle="Energy Leech"
| + | |
− | }
| + | |
− | | + | |
− | //===================================================
| + | |
− | // Class: UTUIFrontEnd_VehicleReplacerMenu
| + | |
− | // Creation Date: 30/11/2007 22:21
| + | |
− | // Last Updated: 01/02/2008 05:48
| + | |
− | //---------------------------------------------------
| + | |
− | // Attribution-Noncommercial-Share Alike 2.5 Generic
| + | |
− | // http://creativecommons.org/licenses/by-nc-sa/2.5/
| + | |
− | //===================================================
| + | |
− | class UTUIDataStore_NewMenuItems extends UTUIDataStore_MenuItems;
| + | |
− | | + | |
− | defaultproperties
| + | |
− | {
| + | |
− | // ElementProviderTypes(0)=(ProviderTag="Vehicles",ProviderClassName="Newtators.UTUIDataProvider_Vehicle")
| + | |
− | /* ElementProviderTypes(0)=
| + | |
− | ElementProviderTypes(1)=
| + | |
− | ElementProviderTypes(2)=
| + | |
− | ElementProviderTypes(3)=
| + | |
− | ElementProviderTypes(4)=
| + | |
− | ElementProviderTypes(5)=
| + | |
− | ElementProviderTypes(6)=
| + | |
− | ElementProviderTypes(7)=
| + | |
− | ElementProviderTypes(8)=
| + | |
− | ElementProviderTypes(9)=
| + | |
− | ElementProviderTypes(10)=
| + | |
− | ElementProviderTypes(11)= */
| + | |
− | // ElementProviderTypes(12)=(ProviderTag="DropDownVehicles",ProviderClassName="Newtators.UTUIDataProvider_Vehicles")
| + | |
− | Tag="Vehicles"
| + | |
− | Name="Default__UTUIDataStore_NewMenuItems"
| + | |
− | ObjectArchetype=UIDataStore_GameResource'UTGame.Default__UTUIDataStore_MenuItems'
| + | |
− | }
| + | |
− | | + | |
− | /**
| + | |
− | * Provides data for a UT3 vehicle.
| + | |
− | *
| + | |
− | * Copyright 1998-2007 Epic Games, Inc. All Rights Reserved
| + | |
− | */
| + | |
− | class UTUIDataProvider_Vehicles extends UTUIResourceDataProvider
| + | |
− | PerObjectConfig;
| + | |
− | | + | |
− | /** The Vehicle class path */
| + | |
− | var config string ClassName;
| + | |
− | | + | |
− | /** optional flags separated by pipes | that can be parsed by the UI as arbitrary options (for example, to exclude weapons from some menus, etc) */
| + | |
− | var config string Flags;
| + | |
− | | + | |
− | /** Friendly name for the vehicle */
| + | |
− | var config localized string FriendlyName;
| + | |
− | | + | |
− | /** Description for the vehicle */
| + | |
− | var config localized string Description;
| + | |
− | | + | |
− | /** String reference to the 3rd person mesh for this weapon. This mesh is used in the UI. */
| + | |
− | var config string MeshReference;
| + | |
− | | + | |
− | var config bool bNecrisVehicle;
| + | |
− | var config bool bTurret;
| + | |
− | | + | |
− | defaultproperties
| + | |
− | {
| + | |
− | bSearchAllInis=True
| + | |
− | // Name="Default__UTUIDataProvider_Vehicle"
| + | |
− | // ObjectArchetype=UTUIResourceDataProvider'UTGame.Default__UTUIResourceDataProvider'
| + | |
− | }
| + | |
− | | + | |
− | //===================================================
| + | |
− | // Class: UTSpeedBoots
| + | |
− | // Creation date: 29/11/2007 14:50
| + | |
− | //---------------------------------------------------
| + | |
− | // Attribution-Noncommercial-Share Alike 2.5 Generic
| + | |
− | // http://creativecommons.org/licenses/by-nc-sa/2.5/
| + | |
− | //===================================================
| + | |
− | class UTSpeedBoots extends UTTimedPowerup_Generic;
| + | |
− | | + | |
− | var float SpeedBoost; /// the Speed boost to give the owner
| + | |
− | var float MultiJumpBoost; /// the Z velocity boost to give the owner's double jumps
| + | |
− | | + | |
− | /** camera overlay effect - New blur effect, no motionblur sucks >:)*/
| + | |
− | //var PostProcessChain CameraEffect;
| + | |
− | | + | |
− | //TODO: If player stops then Ambient = none?
| + | |
− | //A_Vehicle_Hoverboard.Cue.A_Vehicle_Hoverboard_Jump
| + | |
− | | + | |
− | /** adds or removes our bonus from the given pawn */
| + | |
− | simulated function AdjustPawn(UTPawn P, bool bRemoveBonus){
| + | |
− | local UTJumpBootEffect SpeedEffect;
| + | |
− | local bool bCheckDoubleLanding;
| + | |
− | | + | |
− | if(P != None) {
| + | |
− | if(!bRemoveBonus) {
| + | |
− | `logd("Start Speed!",,'SpeedBoots');
| + | |
− | // DoMotionBlur(P);
| + | |
− | // ClientSetCameraEffect(P.Controller, true);
| + | |
− | | + | |
− | SpeedEffect = Spawn(class'Newtators.UTSpeedBootEffect', P,, P.Location, P.Rotation);
| + | |
− | // SpeedEffect.LifeSpan = 30.00000;
| + | |
− | // SpeedEffect.JumpingEffect = ParticleSystem'Newtators_Pickups.Particles.P_SpeedBoot_Effect';
| + | |
− | | + | |
− | P.AirControl = P.AirControl * SpeedBoost;
| + | |
− | P.GroundSpeed = P.GroundSpeed * SpeedBoost;
| + | |
− | P.WaterSpeed = P.WaterSpeed * SpeedBoost;
| + | |
− | P.AirSpeed = P.AirSpeed * SpeedBoost;
| + | |
− | P.MultiJumpBoost = P.MultiJumpBoost + MultiJumpBoost;
| + | |
− | | + | |
− | bCheckDoubleLanding = P.bStopOnDoubleLanding;
| + | |
− | P.bStopOnDoubleLanding = False;
| + | |
− | P.SlopeBoostFriction = -0.400000;
| + | |
− | // increase cost of high jump nodes so bots don't waste the boots for small shortcuts
| + | |
− | // if (P.Controller != None) P.Controller.HighJumpNodeCostModifier += 1000;
| + | |
− | } else {
| + | |
− | `logd("End Speed!",,'SpeedBoots');
| + | |
− | // DoMotionBlur(P);
| + | |
− | // ClientSetCameraEffect(P.Controller, false);
| + | |
− | | + | |
− | if(SpeedEffect != None)
| + | |
− | SpeedEffect.Destroyed();
| + | |
− | | + | |
− | P.AirControl = P.AirControl / SpeedBoost;
| + | |
− | P.GroundSpeed = P.GroundSpeed / SpeedBoost;
| + | |
− | P.WaterSpeed = P.WaterSpeed / SpeedBoost;
| + | |
− | P.AirSpeed = P.AirSpeed / SpeedBoost;
| + | |
− | P.MultiJumpBoost = P.MultiJumpBoost - MultiJumpBoost;
| + | |
− | | + | |
− | if(!bCheckDoubleLanding)
| + | |
− | P.bStopOnDoubleLanding = True;
| + | |
− | | + | |
− | P.SlopeBoostFriction = 0.200000;
| + | |
− | // increase cost of high jump nodes so bots don't waste the boots for small shortcuts
| + | |
− | // if (P.Controller != None) P.Controller.HighJumpNodeCostModifier -= 1000;
| + | |
− | }
| + | |
− | }
| + | |
− | }
| + | |
− | | + | |
− | /** turns on or off the camera effect */
| + | |
− | /*reliable client function ClientSetCameraEffect(Controller C, bool bEnabled)
| + | |
− | {
| + | |
− | local UTPlayerController PC;
| + | |
− | local LocalPlayer LP;
| + | |
− | // local MaterialEffect NewEffect;
| + | |
− | // local byte Team;
| + | |
− | local int i;
| + | |
− | | + | |
− | PC = UTPlayerController(C);
| + | |
− | if(PC != None)
| + | |
− | {
| + | |
− | LP = LocalPlayer(PC.Player);
| + | |
− | if(LP != None)
| + | |
− | {
| + | |
− | if(bEnabled)
| + | |
− | {
| + | |
− | LP.InsertPostProcessingChain(CameraEffect, INDEX_NONE, true);
| + | |
− | // NewEffect = MaterialEffect(LP.PlayerPostProcess.FindPostProcessEffect('SpeedbootsEffect'));
| + | |
− | // if(NewEffect != None)
| + | |
− | // {
| + | |
− | // Team = C.GetTeamNum();
| + | |
− | // NewEffect.Material = (Team < TeamCameraMaterials.length) ? TeamCameraMaterials[Team] : TeamCameraMaterials[0];
| + | |
− | // }
| + | |
− | }
| + | |
− | else
| + | |
− | {
| + | |
− | for(i = 0; i < LP.PlayerPostProcessChains.length; i++)
| + | |
− | {
| + | |
− | if(LP.PlayerPostProcessChains[i].FindPostProcessEffect('SpeedbootsEffect') != None)
| + | |
− | {
| + | |
− | LP.RemovePostProcessingChain(i);
| + | |
− | i--;
| + | |
− | }
| + | |
− | }
| + | |
− | }
| + | |
− | }
| + | |
− | }
| + | |
− | }
| + | |
− | | + | |
− | Simulated function DoMotionBlur(UTPawn P)
| + | |
− | {
| + | |
− | local LocalPlayer LocPlayer;
| + | |
− | local PostProcessEffect PPE;
| + | |
− | | + | |
− | LocPlayer = LocalPlayer(UTPlayerController(P.Controller).Player);
| + | |
− | if(LocPlayer != None)
| + | |
− | {
| + | |
− | PPE = LocPlayer.PlayerPostProcess.FindPostProcessEffect('MotionBlur');
| + | |
− | if(PPE != None)
| + | |
− | {
| + | |
− | PPE.bShowInGame = !PPE.bShowInGame;
| + | |
− | }
| + | |
− | | + | |
− | if(PPE.bShowInGame)
| + | |
− | {
| + | |
− | MotionBlurEffect(PPE).MaxVelocity = 1.000000;//2.0
| + | |
− | MotionBlurEffect(PPE).MotionBlurAmount = 0.400000;//0.5,2.5
| + | |
− | MotionBlurEffect(PPE).CameraRotationThreshold=90.000000;//45
| + | |
− | MotionBlurEffect(PPE).CameraTranslationThreshold = 100.000000;
| + | |
− | }
| + | |
− | else
| + | |
− | {
| + | |
− | MotionBlurEffect(PPE).MaxVelocity = 1.000000;
| + | |
− | MotionBlurEffect(PPE).MotionBlurAmount = 0.400000;
| + | |
− | MotionBlurEffect(PPE).CameraRotationThreshold = 90.000000;
| + | |
− | MotionBlurEffect(PPE).CameraTranslationThreshold = 10000.000000;
| + | |
− | }
| + | |
− | }
| + | |
− | }*/
| + | |
− | | + | |
− | // FootSound = SoundGroupClass.static.GetFootstepSound(FootDown, GetMaterialBelowFeet());
| + | |
− | | + | |
− | //TODO: Add sound effect for jumping and dodging
| + | |
− | /*simulated function OwnerEvent(name EventName)
| + | |
− | {
| + | |
− | if(Role == ROLE_Authority)
| + | |
− | {
| + | |
− | if(EventName == 'MultiJump')
| + | |
− | {
| + | |
− | Charges--;
| + | |
− | UTPawn(Owner).JumpBootCharge = Charges;
| + | |
− | Spawn(class'UTJumpBootEffect', Owner,, Owner.Location, Owner.Rotation);
| + | |
− | Owner.PlaySound(ActivateSound, false, true, false);
| + | |
− | }
| + | |
− | else if(EventName == 'Landed' && Charges <= 0)
| + | |
− | {
| + | |
− | Destroy();
| + | |
− | }
| + | |
− | }
| + | |
− | else if(EventName == 'MultiJump')
| + | |
− | {
| + | |
− | Owner.PlaySound(ActivateSound, false, true, false);
| + | |
− | }
| + | |
− | UTPawn(Owner).bDodging;
| + | |
− | }*/
| + | |
− | | + | |
− | defaultproperties
| + | |
− | {
| + | |
− | // CameraEffect=PostProcessChain'Newtators_Pickups.Speedboots.LensEffects.SpeedbootsPostProcess'
| + | |
− | | + | |
− | bCanDenyPowerup=True
| + | |
− | bHavePowerup=True
| + | |
− | SpeedBoost=1.4 //1.35,1.4, 1.45
| + | |
− | MultiJumpBoost=35.000000 //25
| + | |
− | TimeRemaining=30.000000
| + | |
− | RespawnTime=45.000000 //30.000000
| + | |
− | // PowerupAmbientSound=SoundCue'A_Vehicle_Hoverboard.Cue.A_Vehicle_Hoverboard_EngineCue'
| + | |
− | PowerupAmbientSound=SoundCue'Newtators_Pickups.Speedboots.Cue.SpeedbootsLoop'
| + | |
− | // PowerupSound=SoundCue'A_Pickups_Powerups.PowerUps.A_Powerup_Berzerk_WarningCue'
| + | |
− | HudIndex=4
| + | |
− | // PowerupOverSound=SoundCue'A_Vehicle_Hoverboard.Cue.A_Vehicle_Hoverboard_WaterDisruptCue'
| + | |
− | PowerupOverSound=SoundCue'Newtators_Pickups.Speedboots.Cue.SpeedbootsEnd'
| + | |
− | PowerupStatName="POWERUPTIME_SPEEDBOOTS"
| + | |
− | IconCoords=(U=744.000000,UL=35.000000,VL=55.000000)
| + | |
− | // PP_Scene_HighLights=(X=-0.150000,Y=-0.080000,Z=0.050000)
| + | |
− | PickupMessage="Speed Boots!"
| + | |
− | // bRenderOverlays=True
| + | |
− | bReceiveOwnerEvents=True
| + | |
− | MaxDesireability=1.000000
| + | |
− | // PickupSound=SoundCue'A_Pickups_Powerups.PowerUps.A_Powerup_JumpBoots_PickupCue'
| + | |
− | PickupSound=SoundCue'Newtators_Pickups.Speedboots.Cue.SpeedbootsPickup'
| + | |
− | Begin Object Class=StaticMeshComponent Name=StaticMeshComponent1 ObjName=StaticMeshComponent1 Archetype=StaticMeshComponent'Engine.Default__StaticMeshComponent'
| + | |
− | StaticMesh=StaticMesh'PICKUPS.JumpBoots.Mesh.S_UN_Pickups_Jumpboots002'
| + | |
− | Materials(0)=Material'Newtators_Pickups.SpeedBoots.Materials.M_SpeedBoots'
| + | |
− | bUseAsOccluder=False
| + | |
− | CastShadow=False
| + | |
− | bForceDirectLightMap=True
| + | |
− | bCastDynamicShadow=False
| + | |
− | CollideActors=False
| + | |
− | BlockRigidBody=False
| + | |
− | Translation=(X=0.000000,Y=0.000000,Z=-20.000000)
| + | |
− | Scale=1.700000
| + | |
− | Name="StaticMeshComponent1"
| + | |
− | ObjectArchetype=StaticMeshComponent'Engine.Default__StaticMeshComponent'
| + | |
− | End Object
| + | |
− | DroppedPickupMesh=StaticMeshComponent1
| + | |
− | PickupFactoryMesh=StaticMeshComponent1
| + | |
− | }
| + | |
− | | + | |
− | //===================================================
| + | |
− | // Class: UTSpeedBootEffect
| + | |
− | // Creation Date: 15/02/2008 18:12
| + | |
− | //---------------------------------------------------
| + | |
− | // Attribution-Noncommercial-Share Alike 2.5 Generic
| + | |
− | // http://creativecommons.org/licenses/by-nc-sa/2.5/
| + | |
− | //===================================================
| + | |
− | class UTSpeedBootEffect extends UTJumpBootEffect;
| + | |
− | | + | |
− | var UTEmitter RightFootEmitter, LeftFootEmitter;
| + | |
− | | + | |
− | simulated function AttachToOwner()
| + | |
− | {
| + | |
− | local vector SocketLocation;
| + | |
− | local rotator SocketRotation;
| + | |
− | | + | |
− | `logd("Emitter Controller Attached!",,'SpeedBoots');
| + | |
− | | + | |
− | if(OwnerPawn != None && OwnerPawn.Mesh != None)
| + | |
− | {
| + | |
− | if(OwnerPawn.Mesh.GetSocketWorldLocationAndRotation(OwnerPawn.PawnEffectSockets[0], SocketLocation, SocketRotation))
| + | |
− | {
| + | |
− | RightFootEmitter = Spawn(class'UTEmitter', OwnerPawn,, SocketLocation, SocketRotation);
| + | |
− | RightFootEmitter.LifeSpan=0;
| + | |
− | /* if(OwnerPawn.Mesh.bOwnerNoSee)
| + | |
− | {
| + | |
− | FootEmitter.ParticleSystemComponent.SetOwnerNoSee(true);
| + | |
− | }*/
| + | |
− | RightFootEmitter.SetBase(OwnerPawn,, OwnerPawn.Mesh, OwnerPawn.PawnEffectSockets[0]);
| + | |
− | RightFootEmitter.SetTemplate(JumpingEffect, true);
| + | |
− | }
| + | |
− | if(OwnerPawn.Mesh.GetSocketWorldLocationAndRotation(OwnerPawn.PawnEffectSockets[1], SocketLocation, SocketRotation))
| + | |
− | {
| + | |
− | LeftFootEmitter = Spawn(class'UTEmitter', OwnerPawn,, SocketLocation, SocketRotation);
| + | |
− | LeftFootEmitter.LifeSpan=0;
| + | |
− | /* if(OwnerPawn.Mesh.bOwnerNoSee)
| + | |
− | {
| + | |
− | FootEmitter.ParticleSystemComponent.SetOwnerNoSee(true);
| + | |
− | }*/
| + | |
− | LeftFootEmitter.SetBase(OwnerPawn,, OwnerPawn.Mesh, OwnerPawn.PawnEffectSockets[1]);
| + | |
− | LeftFootEmitter.SetTemplate(JumpingEffect, true);
| + | |
− | }
| + | |
− | }
| + | |
− | }
| + | |
− | | + | |
− | //event Destroyed()
| + | |
− | //event ShutDown()
| + | |
− | function Destroyed()
| + | |
− | {
| + | |
− | Super.Destroyed();
| + | |
− | | + | |
− | `logd("Emitter Controller Destroyed!",,'SpeedBoots');
| + | |
− | RightFootEmitter.ParticleSystemComponent.SecondsBeforeInactive = 0.000001;
| + | |
− | LeftFootEmitter.ParticleSystemComponent.SecondsBeforeInactive = 0.000001;
| + | |
− | /* RightFootEmitter.ShutDown();
| + | |
− | LeftFootEmitter.ShutDown();
| + | |
− | ShutDown();*/
| + | |
− | /* RightFootEmitter.bCurrentlyActive = false;
| + | |
− | LeftFootEmitter.bCurrentlyActive = false;
| + | |
− | RightFootEmitter.ParticleSystemComponent.DeactivateSystem();
| + | |
− | LeftFootEmitter.ParticleSystemComponent.DeactivateSystem();
| + | |
− | | + | |
− | RightFootEmitter.ParticleSystemComponent.SetActive(false);
| + | |
− | LeftFootEmitter.ParticleSystemComponent.SetActive(false);
| + | |
− | | + | |
− | RightFootEmitter.LifeSpan=0.001;
| + | |
− | LeftFootEmitter.LifeSpan=0.001;
| + | |
− | | + | |
− | LifeSpan=0.001;*/
| + | |
− | }
| + | |
− | | + | |
− | defaultproperties
| + | |
− | {
| + | |
− | LifeSpan=0.00000 //30
| + | |
− | JumpingEffect=ParticleSystem'Newtators_Pickups.Speedboots.Effects.P_SpeedBoot_Effect_C'
| + | |
− | }
| + | |
− | | + | |
− | //===================================================
| + | |
− | // Class: UTQuadJumpBoots
| + | |
− | // Creation date: 26/11/2007 12:00
| + | |
− | // Last updated: 19/05/2008 07:39
| + | |
− | //---------------------------------------------------
| + | |
− | // Attribution-Noncommercial-Share Alike 2.5 Generic
| + | |
− | // http://creativecommons.org/licenses/by-nc-sa/2.5/
| + | |
− | //---------------------------------------------------
| + | |
− | //Modified version of UTJumpBoots to support Quadjumps
| + | |
− | //TODO: add proper bot support so they know how high they can jump
| + | |
− | //===================================================
| + | |
− | class UTQuadJumpBoots extends UTJumpBoots;
| + | |
− | | + | |
− | var int JumpsBoost;
| + | |
− | | + | |
− | /** adds or removes our bonus from the given pawn */
| + | |
− | simulated function AdjustPawn(UTPawn P, bool bRemoveBonus)
| + | |
− | {
| + | |
− | if(P != None)
| + | |
− | {
| + | |
− | if(bRemoveBonus)
| + | |
− | {
| + | |
− | P.MaxMultiJump = 1;
| + | |
− | P.MultiJumpRemaining = 1;
| + | |
− | P.MultiJumpBoost=-45;
| + | |
− | P.JumpBootCharge = 0;
| + | |
− | | + | |
− | // increase cost of high jump nodes so bots don't waste the boots for small shortcuts
| + | |
− | if(P.Controller != None)
| + | |
− | P.Controller.HighJumpNodeCostModifier -= 400; //1000
| + | |
− | }
| + | |
− | else
| + | |
− | {
| + | |
− | P.MaxMultiJump = JumpsBoost;
| + | |
− | P.MultiJumpRemaining = JumpsBoost;
| + | |
− | P.MultiJumpBoost=MultiJumpBoost;
| + | |
− | P.JumpBootCharge = Charges;
| + | |
− | | + | |
− | // increase cost of high jump nodes so bots don't waste the boots for small shortcuts
| + | |
− | if(P.Controller != None)
| + | |
− | P.Controller.HighJumpNodeCostModifier += 400; //1000
| + | |
− | }
| + | |
− | }
| + | |
− | }
| + | |
− | | + | |
− | simulated function OwnerEvent(name EventName)
| + | |
− | {
| + | |
− | if(Role == ROLE_Authority)
| + | |
− | {
| + | |
− | if(EventName == 'MultiJump')
| + | |
− | {
| + | |
− | Charges--;
| + | |
− | UTPawn(Owner).JumpBootCharge = Charges;
| + | |
− | Spawn(class'UTJumpBootEffect', Owner,, Owner.Location, Owner.Rotation);
| + | |
− | Owner.PlaySound(ActivateSound, false, true, false);
| + | |
− | }
| + | |
− | | + | |
− | if(Charges <= 0)
| + | |
− | {
| + | |
− | Destroy();
| + | |
− | }
| + | |
− | }
| + | |
− | else if(EventName == 'MultiJump')
| + | |
− | {
| + | |
− | Owner.PlaySound(ActivateSound, false, true, false);
| + | |
− | }
| + | |
− | }
| + | |
− | | + | |
− | defaultproperties
| + | |
− | {
| + | |
− | JumpsBoost=3
| + | |
− | MultiJumpBoost=50.000000
| + | |
− | Charges=20
| + | |
− | ActivateSound=SoundCue'A_Pickups_Powerups.PowerUps.A_Powerup_JumpBoots_JumpCue'
| + | |
− | RanOutText="The Quad-Jump Boots have run out."
| + | |
− | bRenderOverlays=True
| + | |
− | bReceiveOwnerEvents=True
| + | |
− | bDropOnDeath=True
| + | |
− | RespawnTime=30.000000
| + | |
− | MaxDesireability=1.000000
| + | |
− | PickupMessage="Quad-Jump Boots"
| + | |
− | PickupSound=SoundCue'A_Pickups_Powerups.PowerUps.A_Powerup_JumpBoots_PickupCue'
| + | |
− | Begin Object Name=StaticMeshComponent1 ObjName=StaticMeshComponent1 Archetype=StaticMeshComponent'Engine.Default__StaticMeshComponent'
| + | |
− | StaticMesh=StaticMesh'PICKUPS.JumpBoots.Mesh.S_UN_Pickups_Jumpboots002'
| + | |
− | bUseAsOccluder=False
| + | |
− | CastShadow=False
| + | |
− | bForceDirectLightMap=True
| + | |
− | bCastDynamicShadow=False
| + | |
− | CollideActors=False
| + | |
− | BlockRigidBody=False
| + | |
− | Translation=(X=0.000000,Y=0.000000,Z=-20.000000)
| + | |
− | Scale=1.700000
| + | |
− | End Object
| + | |
− | DroppedPickupMesh=StaticMeshComponent1
| + | |
− | PickupFactoryMesh=StaticMeshComponent1
| + | |
− | }
| + | |
− | | + | |
− | //===================================================
| + | |
− | // Class: UTPickupFactory_SpeedBoots
| + | |
− | // Creation date: 19/05/2008 00:42
| + | |
− | //---------------------------------------------------
| + | |
− | // Attribution-Noncommercial-Share Alike 2.5 Generic
| + | |
− | // http://creativecommons.org/licenses/by-nc-sa/2.5/
| + | |
− | //===================================================
| + | |
− | class UTPickupFactory_SpeedBoots extends UTPickupFactory_JumpBoots;
| + | |
− | | + | |
− | defaultproperties
| + | |
− | {
| + | |
− | PickupStatName="PICKUPS_SPEEDBOOTS"
| + | |
− | InventoryType=Class'Newtators.UTSpeedBoots'
| + | |
− | bHasLocationSpeech=False //True
| + | |
− | BaseBrightEmissive=(R=0.500000,G=0.500000,B=0.500000,A=1.000000)
| + | |
− | BaseDimEmissive=(R=0.500000,G=0.500000,B=0.500000,A=1.000000)
| + | |
− | | + | |
− | bStatic=False //True
| + | |
− | bNoDelete=False //True
| + | |
− | }
| + | |
− | | + | |
− | //===================================================
| + | |
− | // Class: UTPickupFactory_Booster
| + | |
− | // Creation date: 19/05/2008 00:42
| + | |
− | //---------------------------------------------------
| + | |
− | // Attribution-Noncommercial-Share Alike 2.5 Generic
| + | |
− | // http://creativecommons.org/licenses/by-nc-sa/2.5/
| + | |
− | //===================================================
| + | |
− | class UTPickupFactory_Booster extends UTPickupFactory_Berserk;
| + | |
− | | + | |
− | defaultproperties
| + | |
− | {
| + | |
− | PickupStatName="PICKUPS_BOOSTER"
| + | |
− | InventoryType=Class'Newtators.UTBooster'
| + | |
− | Begin Object /*Class=UTParticleSystemComponent*/ Name=BerserkParticles ObjName=BerserkParticles Archetype=UTParticleSystemComponent'UTGame.Default__UTParticleSystemComponent'
| + | |
− | Template=ParticleSystem'Newtators_Pickups.Booster.Effects.P_Pickups_Booster_Idle'
| + | |
− | bAutoActivate=False
| + | |
− | Translation=(X=0.000000,Y=0.000000,Z=5.000000)
| + | |
− | End Object
| + | |
− | bHasLocationSpeech=False //True
| + | |
− | BaseBrightEmissive=(R=0.000000,G=20.000000,B=1.000000,A=1.000000)
| + | |
− | BaseDimEmissive=(R=0.000000,G=1.000000,B=0.100000,A=1.000000)
| + | |
− | | + | |
− | bStatic=False //True
| + | |
− | bNoDelete=False //True
| + | |
− | }
| + | |
− | | + | |
− | //===================================================
| + | |
− | // Class: UTMutator_VehicleTeamSwap
| + | |
− | // Creation date: 20/12/2008 21:03
| + | |
− | // Last updated: 20/12/2008 21:38
| + | |
− | //---------------------------------------------------
| + | |
− | // Attribution-Noncommercial-Share Alike 2.5 Generic
| + | |
− | // http://creativecommons.org/licenses/by-nc-sa/2.5/
| + | |
− | //===================================================
| + | |
− | class UTMutator_VehicleTeamSwap extends UTData_FactoryRepl
| + | |
− | | + | |
− | simulated function PostBeginPlay()
| + | |
− | {
| + | |
− | local UTOnslaughtGame_Content WarGame;
| + | |
− | local UTOnslaughtPowerCore WarCore[numTeams];
| + | |
− | local UTOnslaughtPowerCore TempWarCore;
| + | |
− | local UTVehicleFactory WarFactory;
| + | |
− | local byte i, k;//, m;
| + | |
− | local int j;
| + | |
− | | + | |
− | local bool bInPerMapList;
| + | |
− | local MapTeamSwapSettings NewMapSwapSettings;
| + | |
− | | + | |
− | // local MapExceptionSwapSet NewPerMapSwapSet;
| + | |
− | // local MapExceptionVehicleSet NewMapExctSwapSet[numTeams];
| + | |
− | // local int Index, MapIndex;
| + | |
− | //, VehicleIndex;
| + | |
− | | + | |
− | | + | |
− | Super.PostBeginPlay();
| + | |
− | | + | |
− | /** Checks for Warfare and if found processes Cores and Vehicle Factories */
| + | |
− | WarGame = UTOnslaughtGame_Content(WorldInfo.Game);
| + | |
− | if(WarGame == None)
| + | |
− | {
| + | |
− | `logd("Skipping Core checks, Gametype is not Warfare!",,'VehicleTeamSwap');
| + | |
− | // Destroy();
| + | |
− | }
| + | |
− | else
| + | |
− | {
| + | |
− | | + | |
− | class UTMutator_Vampire extends UTMutator_GameExpansion;
| + | |
− | | + | |
− | defaultproperties
| + | |
− | {
| + | |
− | GroupNames(0)="VAMPIRE"
| + | |
− | UTGameDataClass=Class'Newtators.UTD_Game_Vampire'
| + | |
− | }
| + | |
− | | + | |
− | //===================================================
| + | |
− | // Class: UTPickupFactory_VDamage
| + | |
− | // Creation date: 19/12/2007 08:47
| + | |
− | //---------------------------------------------------
| + | |
− | // Attribution-Noncommercial-Share Alike 2.5 Generic
| + | |
− | // http://creativecommons.org/licenses/by-nc-sa/2.5/
| + | |
− | //===================================================
| + | |
− | class UTPickupFactory_VDamage extends UTPickupFactory_UDamage;
| + | |
− | | + | |
− | defaultproperties
| + | |
− | {
| + | |
− | PickupStatName="PICKUPS_VDAMAGE"
| + | |
− | InventoryType=Class'Newtators.UTVDamage'
| + | |
− | Begin Object /*Class=UTParticleSystemComponent*/ Name=DamageParticles ObjName=DamageParticles Archetype=UTParticleSystemComponent'UTGame.Default__UTParticleSystemComponent'
| + | |
− | Template=ParticleSystem'Newtators_Pickups.VDamage.Effects.P_Pickups_VDamage_Idle'
| + | |
− | bAutoActivate=False
| + | |
− | Translation=(X=0.000000,Y=0.000000,Z=5.000000)
| + | |
− | // Name="DamageParticles"
| + | |
− | // ObjectArchetype=UTParticleSystemComponent'UTGame.Default__UTParticleSystemComponent'
| + | |
− | End Object
| + | |
− | bHasLocationSpeech=False //True
| + | |
− | BaseBrightEmissive=(R=50.000000,G=1.000000,B=0.000000,A=1.000000)
| + | |
− | BaseDimEmissive=(R=5.000000,G=0.100000,B=0.000000,A=1.000000)
| + | |
− | | + | |
− | bStatic=False //True
| + | |
− | bNoDelete=False //True
| + | |
− | }
| + | |
− | | + | |
− | class UTMutator_Translocator extends UTMutator_GameExpansion;
| + | |
− | | + | |
− | defaultproperties
| + | |
− | {
| + | |
− | GroupNames(0)="TRANSLOC"
| + | |
− | bAllowTranslocator=True
| + | |
− | bUseNewDefaultInventory=True
| + | |
− | NewDefaultInventory(0)=Class'UTGame.UTWeap_Enforcer';
| + | |
− | NewDefaultInventory(1)=Class'UTGame.UTWeap_ImpactHammer';
| + | |
− | NewDefaultInventory(2)=class'UTGameContent.UTWeap_Translocator_Content';
| + | |
− | }
| + | |
− | </uscript>
| + | |