2. Data transmission
Tanuden TIMS accepts data in the OpenTetsu API format via the POST method at http://127.0.0.1:58680/plugins/data.
Sending data
The following method allows you to send data to the Tanuden TIMS API. This method essentially acts as a patch above any data originally provided by TrainCrew.
TanudenTIMSAPI.SendData()Acceptable objects
Tanuden.Common.OpenTetsu
For data that conforms with OpenTetsu API standard
Tanuden.Common.PluginState
For additional data that is not in the OpenTetsu API standard. This includes the TASC lamps.
Examples
Custom speed limit
var gameData = new OpenTetsuData
{
TrainState = new TrainState
{
SpeedLimit = 60,
}
};
TanudenTIMSAPI.SendData(gameData);Move the ATC/ATS needle
TASC lamp operation
For the operation of the TASC lamps, if your application does not perform a sendData() update within 8 seconds from the last, the 「TASC故障」 lamp will automatically light up.
TASCランプの動作については、アプリケーションが前回から8秒以内にsendData()更新を行わなかった場合、自動的に「TASC故障」ランプが点灯します。
最終更新