public EmploymentController(IEmployeeHandler employeeHandler, ITaskHandler taskHandler, IEmployerHandler employerHandler, ILevelHandler levelHandler) { _employeeHandler = employeeHandler; _employerHandler = employerHandler; _levelHandler = levelHandler; _taskHandler = taskHandler; }
public HomeController(IEmployeeHandler employeeHandler, IPersonHandler personHandler, ITaskHandler taskHandler, IEmployerHandler employerHandler, ILevelHandler levelHandler) { _employeeHandler = employeeHandler; _employerHandler = employerHandler; _levelHandler = levelHandler; _taskHandler = taskHandler; _personHandler = personHandler; }
public static void Create(ILevelHandler levelHandler, Vector3 pos, ushort type) { Explosion explosion = new Explosion(); explosion.OnActivated(new ActorActivationDetails { LevelHandler = levelHandler, Pos = pos, Params = new[] { type } }); levelHandler.AddActor(explosion); }
public ChainPiece(ILevelHandler levelHandler, Vector3 pos, PlatformType type) { this.levelHandler = levelHandler; Transform transform = AddComponent <Transform>(); Transform.Pos = pos; CollisionFlags = CollisionFlags.ForceDisableCollisions; RequestMetadata("MovingPlatform/" + type.ToString("G")); SetAnimation("Chain"); }
public ChainPiece(ILevelHandler levelHandler, Vector3 pos, int distance) { this.levelHandler = levelHandler; this.distance = distance; Transform transform = AddComponent <Transform>(); Transform.Pos = pos; CollisionFlags = CollisionFlags.ForceDisableCollisions; RequestMetadata("MovingPlatform/SpikeBall"); SetAnimation("Chain"); }
public TileMap(ILevelHandler levelHandler, string tilesetPath, ColorRgba[] tileMapPalette, bool hasPit) { this.levelHandler = levelHandler; this.hasPit = hasPit; tileset = new TileSet(tilesetPath, true, tileMapPalette); if (!tileset.IsValid) { throw new InvalidDataException("Tileset is corrupted"); } triggerState = new BitArray(TriggerCount); }
public TileMap(ILevelHandler levelHandler, string tilesetPath, bool hasPit) { this.levelHandler = levelHandler; this.hasPit = hasPit; IImageCodec codec = ImageCodec.GetRead(ImageCodec.FormatPng); tileset = new TileSet(tilesetPath); if (!tileset.IsValid) { throw new InvalidDataException("Tileset is corrupted"); } triggerState = new BitArray(TriggerCount); }
public void ReleaseResources() { if (tileset != null) { tileset.Dispose(); tileset = null; } layers = null; animatedTiles = null; activeCollapsingTiles = null; debrisList = null; levelHandler = null; }
public async void OnActivated(ILevelHandler levelHandler, Vector3 pos, string metadataPath, CollisionFlags collisionFlags) { initState = InitState.Initializing; this.levelHandler = levelHandler; this.flags = ActorInstantiationFlags.None; this.CollisionFlags = (collisionFlags & ~CollisionFlags.ApplyGravitation); double timeNow = NetTime.Now; for (int i = 0; i < stateBuffer.Length; i++) { stateBuffer[i].Time = timeNow - stateBuffer.Length + i; stateBuffer[i].Pos = pos.Xy; } posZ = pos.Z; health = int.MaxValue; friction = 1.5f; originTile = new Point2((int)(pos.X / 32), (int)(pos.Y / 32)); Transform transform = AddComponent <Transform>(); transform.Pos = pos; AddComponent(new LocalController(this)); //await OnActivatedAsync(details); await RequestMetadataAsync(metadataPath); if (initState == InitState.Initializing) { initState = InitState.Initialized; } }
public TaskController(ITaskHandler taskHandler, ILevelHandler levelHandler) { _levelHandler = levelHandler; _taskHandler = taskHandler; }
public LevelController(ILevelHandler levelHandler) { LevelHandler = levelHandler; }
public EventSpawner(ILevelHandler levelHandler) { this.levelHandler = levelHandler; InitializeSpawnableList(); }