mirror of
https://github.com/metrostroi-repo/MetrostroiAddon.git
synced 2026-05-02 00:42:29 +00:00
Merge pull request #407 from metrostroi-repo/#324
Resolve #324 Fixed door signaling Eint-KVL
This commit is contained in:
@@ -1269,7 +1269,7 @@ function ENT:Think()
|
|||||||
else
|
else
|
||||||
self.DoorLoopStates[id] = math.Clamp((self.DoorLoopStates[id] or 0) - 6*self.DeltaTime,0,1)
|
self.DoorLoopStates[id] = math.Clamp((self.DoorLoopStates[id] or 0) - 6*self.DeltaTime,0,1)
|
||||||
end
|
end
|
||||||
self:SetSoundState(sid.."r",self.DoorLoopStates[id],0.66+self.DoorLoopStates[id]*0.2)
|
self:SetSoundState(sid.."r",self.DoorLoopStates[id],0.5+self.DoorLoopStates[id]*0.2)
|
||||||
local n_l = "door"..i.."x"..k--.."a"
|
local n_l = "door"..i.."x"..k--.."a"
|
||||||
--local n_r = "door"..i.."x"..k.."b"
|
--local n_r = "door"..i.."x"..k.."b"
|
||||||
local dlo = 1
|
local dlo = 1
|
||||||
@@ -1280,7 +1280,7 @@ function ENT:Think()
|
|||||||
dlo = self.Anims[n_l].oldspeed/14
|
dlo = self.Anims[n_l].oldspeed/14
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
self:Animate(n_l,state,0,1, dlo*14,false)--0.8 + (-0.2+0.4*math.random()),0)
|
self:Animate(n_l,state,0.01,1, dlo*14,false)--0.8 + (-0.2+0.4*math.random()),0)
|
||||||
--self:Animate(n_r,state,0,1, dlo*14,false)--0.8 + (-0.2+0.4*math.random()),0)
|
--self:Animate(n_r,state,0,1, dlo*14,false)--0.8 + (-0.2+0.4*math.random()),0)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|||||||
@@ -335,8 +335,8 @@ function TRAIN_SYSTEM:SolveAllInternalCircuits(Train)
|
|||||||
local BD = 1-Train.BD.Value
|
local BD = 1-Train.BD.Value
|
||||||
if isKVL then
|
if isKVL then
|
||||||
Train:WriteTrainWire(15,T[-15]*Train.RD.Value)
|
Train:WriteTrainWire(15,T[-15]*Train.RD.Value)
|
||||||
Panel.SD = T[-15]*T[15]
|
|
||||||
Train.RD:TriggerInput("Set",BO*Train.BD.Value)
|
Train.RD:TriggerInput("Set",BO*Train.BD.Value)
|
||||||
|
Panel.SD = BO*BD
|
||||||
else
|
else
|
||||||
Train:WriteTrainWire(15,BD*(1-Train.KU11.Value))
|
Train:WriteTrainWire(15,BD*(1-Train.KU11.Value))
|
||||||
Panel.SD = (S["D1"]+BO*Train.KU11.Value)*(T[15]*(1-Train.KU11.Value)+BD)
|
Panel.SD = (S["D1"]+BO*Train.KU11.Value)*(T[15]*(1-Train.KU11.Value)+BD)
|
||||||
|
|||||||
Reference in New Issue
Block a user