mirror of
https://github.com/unixtensor/Roblox-Elevator-Game.git
synced 2025-12-15 21:51:55 +00:00
work on door opening possibility while the elevator is stopped
This commit is contained in:
@@ -28,7 +28,9 @@ type ElevatorAttributes = {
|
||||
}
|
||||
|
||||
type DoorAttributes = {
|
||||
Open: BoolValue
|
||||
Relay: {
|
||||
Open: BoolValue
|
||||
}
|
||||
}
|
||||
|
||||
export type RelayAlgorithmConstructor = ClassConstructor
|
||||
@@ -78,7 +80,7 @@ end
|
||||
function RelayAlgorithm:AddFloor(ElevatorGoingUp, RequestedLevel)
|
||||
self:RawInsert(ElevatorGoingUp, RequestedLevel)
|
||||
|
||||
return not self.ElevatorAttributes.Moving.Value and self.DoorAttributes.Open.Value
|
||||
return not self.ElevatorAttributes.Moving.Value and self.DoorAttributes.Relay.Open.Value
|
||||
end
|
||||
|
||||
return RelayAlgorithm
|
||||
Reference in New Issue
Block a user