LadyAliceMargatroid 056cac8df1 Moved dungen code to DunGenPlus
Added critical damage as a mechanic
Maid knife feed deals critical damage, then kills on second time
Added concept of treasure room with kitchen
Frames now only start at the player when not being looked
New attempt at snowglobe animations, it broke though
Added concept of indoor weathers
LethalConfig compability now changes the color of configs that my presets touch
Added jukebox
Changed modGUID
Removed AC compability
Falling into void deals critical damage and teleports, then kills on second time
Maid spawns revenant ghost on death
2024-08-02 08:56:09 -07:00

41 lines
1013 B
C#

using DunGen;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Runtime.Remoting.Contexts;
using System.Text;
using System.Threading.Tasks;
using UnityEngine;
namespace ScarletMansion.GamePatch.Components {
public class PathOpenup : MonoBehaviour {
public GameObject[] connectorGameObjects;
public GameObject[] blockerGameObjects;
public enum State {
NotSet,
UnActive,
Active
}
private State state;
public void UpdatePath(State newState){
if (newState < state) return;
var connect = newState == State.Active;
foreach(var connectorGameObject in connectorGameObjects) connectorGameObject.SetActive(connect);
foreach(var blockerGameObject in blockerGameObjects) blockerGameObject.SetActive(!connect);
state = newState;
}
public void CleanUp() {
var targets = state == State.Active ? blockerGameObjects : connectorGameObjects;
foreach(var t in targets) Destroy(t);
}
}
}