This commit is contained in:
weizhihong 2023-10-17 17:51:32 +08:00
commit 836c34ada4
2 changed files with 2 additions and 1 deletions

View File

@ -12,6 +12,7 @@ import (
"joylink.club/rtsssimulation/fi"
"joylink.club/rtsssimulation/repository"
"joylink.club/rtsssimulation/repository/model/proto"
"log/slog"
)
func ChangeSignalState(simulation *VerifySimulation, mapId int32, signalDeviceId string, toAspect state.Signal_Aspect) {
@ -21,6 +22,7 @@ func ChangeSignalState(simulation *VerifySimulation, mapId int32, signalDeviceId
panic(fmt.Sprintf("信号机[%s]模型不存在", signalUid))
}
signalGroupCode := signalModel.(*repository.Signal).Code()
slog.Info("信号机操作", "uid", signalUid, "组合类型码", signalGroupCode)
switch signalGroupCode {
case consts.SIGNAL_2XH1:
changeSignal2XH1State(simulation.World, signalUid, toAspect)

View File

@ -403,7 +403,6 @@ func fillProtoRepository(repo *proto.Repository, storage *graphicData.RtssGraphi
Km: convertKm(data.KilometerSystem),
SectionId: sectionId,
TurnoutPort: turnoutPort,
//Code: data.,
}
repo.Signals = append(repo.Signals, converSignalUid(signal, uidsMap))
}