Overview | Package | Class | Source | Class tree | Glossary | UnrealScript Documentation |
previous class next class | frames no frames |
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 |
/** * Copyright 1998-2008 Epic Games, Inc. All Rights Reserved. */ /** * This volume is used to control which levels are loaded/unloaded during * gameplay. */ class TriggerStreamingLevel extends Trigger; /** Holds the various settings needed to un/load a streaming level */ struct LevelStreamingData { /** Whether the level should be loaded */ var() bool bShouldBeLoaded; /** Whether the level should be visible if it is loaded */ var() bool bShouldBeVisible; /** Whether we want to force a blocking load */ var() bool bShouldBlockOnLoad; /** The level that will be streamed in */ var() LevelStreaming Level; }; /** Holds the list of levels to load/unload when triggered */ var() editinline array<LevelStreamingData> Levels; /** * Loads & unloads the specified streaming levels when triggered * * @param Other the actor generating the event * @param HitLocation the location of the touch * @param HitNormal the normal generated at the touch */ event Touch(Actor Other, PrimitiveComponent OtherComp, vector HitLocation, vector HitNormal) { local PlayerController PlayerCon; local int Index; Super.Touch(Other,OtherComp,HitLocation,HitNormal); // Iterate through the levels un/loading them for (Index = 0; Index < Levels.Length; Index++) { // Notify each player of the change in level load status foreach WorldInfo.AllControllers(class'PlayerController',PlayerCon) { // Set the blocking flag Levels[Index].Level.bShouldBlockOnLoad = Levels[Index].bShouldBlockOnLoad; // Now un/load the level PlayerCon.LevelStreamingStatusChanged( Levels[Index].Level, Levels[Index].bShouldBeLoaded, Levels[Index].bShouldBeVisible, Levels[Index].bShouldBlockOnLoad); } } } defaultproperties { Begin Object Class=CylinderComponent Name=CollisionCylinder ObjName=CollisionCylinder Archetype=CylinderComponent'Engine.Default__Trigger:CollisionCylinder' ObjectArchetype=CylinderComponent'Engine.Default__Trigger:CollisionCylinder' End Object CylinderComponent=CollisionCylinder Begin Object Class=SpriteComponent Name=Sprite ObjName=Sprite Archetype=SpriteComponent'Engine.Default__Trigger:Sprite' ObjectArchetype=SpriteComponent'Engine.Default__Trigger:Sprite' End Object Components(0)=Sprite Components(1)=CollisionCylinder CollisionComponent=CollisionCylinder Name="Default__TriggerStreamingLevel" ObjectArchetype=Trigger'Engine.Default__Trigger' } |
Overview | Package | Class | Source | Class tree | Glossary | UnrealScript Documentation |
previous class next class | frames no frames |