Activity

Algemene discussies over de simulator.

Moderators: senjer, Tom

rik079
Posts: 76
Joined: 11 Dec 2016, 14:56

Re: Activity

Post by rik079 » 06 Jan 2019, 18:44

Hoe kan ik het in een activity het nummer van een trein dat je met shift+* veranderd instellen?
(sorry voor al die vragen hoor :shock: )

User avatar
Sjoerd
Posts: 3433
Joined: 26 Dec 2014, 21:14
Location: Leiden

Re: Activity

Post by Sjoerd » 06 Jan 2019, 18:58

Voorbeeld:
<depart code="422" train="4225TP" target="TRD2" time="15:04:00" ai="true" track="T1" direction="1" units="5" signnumber="22"/>

In de depot-vertrek code dus. Dit is bedoeld als dienstwagennummer, dus je kunt het niet onderweg veranderen (ja, handmatig wel, maar niet door de AI)

Of zo:

<train pack="RET" file="5200-2002.xml" number="5259">
<car id="0" scrollsign1="28.0" scrollsign2="04"/>
<car id="1" scrollsign1="28.0" scrollsign2="04"/>
</train>

Dus bij het plaatsen van het materieel in het netwerk.
CEO of the Rijndam Electrical Transport company :D

rik079
Posts: 76
Joined: 11 Dec 2016, 14:56

Re: Activity

Post by rik079 » 12 Jan 2019, 18:55

Het werkt niet :shock:

User avatar
Sjoerd
Posts: 3433
Joined: 26 Dec 2014, 21:14
Location: Leiden

Re: Activity

Post by Sjoerd » 12 Jan 2019, 19:50

Niet als je het bij SG3's probeert; die hebben geen instelbaar dienstwagennummer (in de sim).
CEO of the Rijndam Electrical Transport company :D

rik079
Posts: 76
Joined: 11 Dec 2016, 14:56

Re: Activity

Post by rik079 » 13 Jan 2019, 17:57

Mijn activity bevat alleen LU stock

User avatar
Sjoerd
Posts: 3433
Joined: 26 Dec 2014, 21:14
Location: Leiden

Re: Activity

Post by Sjoerd » 13 Jan 2019, 18:30

Het werkt heel goed, dus kennelijk doe je toch iets verkeerd. Kijk gewoon naar hoe het in bestaande activiteiten is gedaan. Aan de hand van mijn bovenstaande berichten weet je naar wat voor coderegels je moet zoeken.
CEO of the Rijndam Electrical Transport company :D

rik079
Posts: 76
Joined: 11 Dec 2016, 14:56

Re: Activity

Post by rik079 » 13 Jan 2019, 18:51

Depot Molenwijk (concept)

Code: Select all

  <yard pack="Rijndam2020" file="DM.cty" departures="auto" arrivals="auto">
   <shedule name="OS_V" time="04:30:00" autodepartures="05:00:00" autoarrivals="07:15:00">
    <depart code="101" train="1011MP" target="MLW" time="05:17:10" ai="true" track="A01" direction="1" units="1" signnumber="11"/>
    <depart code="201" train="2011MC" target="MLW" time="05:19:10" ai="true" track="A02" direction="1" units="1" signnumber="21"/>
    <depart code="102" train="1021MP" target="MLW" time="05:22:10" ai="true" track="A01" direction="1" units="1" signnumber="12"/>
    <depart code="202" train="2021MC" target="MLW" time="05:24:10" ai="true" track="A02" direction="1" units="1" signnumber="22"/>
    <depart code="103" train="1031MP" target="MLW" time="05:27:10" ai="true" track="A01" direction="1" units="1" signnumber="13"/>
    <depart code="203" train="2031MC" target="MLW" time="05:29:10" ai="true" track="A02" direction="1" units="1" signnumber="23"/>
    <depart code="104" train="1041MP" target="MLW" time="05:32:10" ai="true" track="A03" direction="1" units="1" signnumber="14"/>
    <depart code="204" train="2041MC" target="MLW" time="05:34:10" ai="true" track="A02" direction="1" units="1" signnumber="24"/>
    <depart code="105" train="1051MP" target="MLW" time="05:37:10" ai="true" track="A03" direction="1" units="1" signnumber="15"/>
    <depart code="205" train="2051MC" target="MLW" time="05:39:10" ai="true" track="A02" direction="1" units="1" signnumber="25"/>
    <depart code="106" train="1061MP" target="MLW" time="05:42:10" ai="true" track="A03" direction="1" units="1" signnumber="16"/>
    <depart code="206" train="2061MC" target="MLW" time="05:44:10" ai="true" track="A02" direction="1" units="1" signnumber="26"/>
    <depart code="107" train="1071MP" target="MLW" time="05:47:10" ai="true" track="A04" direction="1" units="1" signnumber="17"/>
    <depart code="108" train="1081MP" target="MLW" time="05:52:10" ai="true" track="A04" direction="1" units="1" signnumber="18"/>
   </shedule>
  </yard>
En een aantal treinen:

Code: Select all

  <consist start="A03" position="260">
   <train pack="London" file="LUS7.xml" number="106"/>
   <car id="0" scrollsign1="28.0" scrollsign2="16"/>
  </consist>
  <consist start="A04">
   <train pack="London" file="LUS7.xml" number="107"/>
   <car id="0" scrollsign1="28.0" scrollsign2="17"/>
  </consist>
  <consist start="A04" position="130">
   <train pack="London" file="LUS7.xml" number="108"/>
   <car id="0" scrollsign1="28.0" scrollsign2="18"/>
  </consist>

  <consist start="A02">
   <train pack="London" file="LU1973_DE.xml" number="201"/>
   <car id="0" scrollsign1="28.0" scrollsign2="21"/>
  </consist>
  <consist start="A02" position="60"">
   <train pack="London" file="LU1973_DE.xml" number="202"/>
   <car id="0" scrollsign1="28.0" scrollsign2="22"/>
  </consist>
  <consist start="A02" position="120">
   <train pack="London" file="LU1973_DE.xml" number="203"/>
   <car id="0" scrollsign1="28.0" scrollsign2="23"/>
  </consist>
  <consist start="A02" position="180">
   <train pack="London" file="LU1973_DE.xml" number="204"/>
   <car id="0" scrollsign1="28.0" scrollsign2="24"/>
  </consist>
  <consist start="A02" position="240">
   <train pack="London" file="LU1973_DE.xml" number="205"/>
   <car id="0" scrollsign1="28.0" scrollsign2="25"/>
  </consist>
  <consist start="A02" position="300">
   <train pack="London" file="LU1973_DE.xml" number="206"/>
   <car id="0" scrollsign1="28.0" scrollsign2="26"/>
  </consist>

  <consist start="A05">
   <train pack="London" file="LU1995_A.xml" number="4011"/>
   <train pack="London" file="LU1995_B.xml" number="4012"/>
   <car id="0" scrollsign1="28.0" scrollsign2="41"/>
   <car id="1" scrollsign1="28.0" scrollsign2="41"/>
  </consist>
Wat doe ik fout dan?

User avatar
Sjoerd
Posts: 3433
Joined: 26 Dec 2014, 21:14
Location: Leiden

Re: Activity

Post by Sjoerd » 13 Jan 2019, 19:27

Je hebt XML fouten gemaakt.

Jouw code:

<consist start="A03" position="260">
<train pack="London" file="LUS7.xml" number="106"/>
<car id="0" scrollsign1="28.0" scrollsign2="16"/>
</consist>
Dat werkt niet. Dit is waarom:
Binnen de consist, die je start op spawnpoint A03 op positie 260, open je een regel voor het neerzetten van een trein (pack London, LUS7, nummer 106). En vervolgens sluit je die trein af met "/".
De simulator kijkt nu verder, en ziet instructies voor het instellen van de bestemming display van het voorste rijtuig van een trein.... Maar kan daar niets mee; je hebt in de vorige regel de opdrachten voor dat treinstel al afgesloten.
En daarna sluit je de consist af.
Effect; de trein is geplaatst, maar de opdrachtregel voor de bestemming display kon niet worden uitgevoerd, omdat de opbouw van de code die niet aan een treinstel koppelt.

Oke, dat is het probleem, door naar de oplossing :)

Code: Select all

  
 <consist start="A03" position="260">
   <train pack="London" file="LUS7.xml" number="106">
     <car id="0" scrollsign1="28.0" scrollsign2="16"/>
   </train>
 </consist>
Wat ik hier heb gedaan; de "/" aan het einde van de "train" regel is weg, waardoor de opdracht voor het treinstel nog geopend blijft.
Dan volgt jouw opdrachtregel voor de bestemming display (die voor zichzelf wel wordt afgesloten met "/", maar dat had je al gedaan).
En dan sluiten we de opdracht voor de trein af met </train>.
Nu valt de opdracht voor de bestemming display binnen de opdracht voor de trein zelf, en nu werkt het wel.

Overigens geldt dit nu alléén voor het voorste rijtuig. Als je de rifi's voor het achterste rijtuig ook wilt instellen, moet je de code iets uitbreiden;

Code: Select all

  
 <consist start="A03" position="260">
   <train pack="London" file="LUS7.xml" number="106">
     <car id="0" scrollsign1="28.0" scrollsign2="16"/>
     <car id="6" scrollsign1="28.0" scrollsign2="16"/>
   </train>
 </consist>
Denk er aan dat de simulator begint te tellen bij 0. Dus bij een treinstel van 7 rijtuigen worden die rijtuigen 0-6 genummerd. En gekoppelde metrostellen hebben elk hun eigen rijtuig-nummering; je kunt niet doornummeren.

Duidelijk zo? :)
Last edited by Sjoerd on 13 Jan 2019, 19:31, edited 1 time in total.
CEO of the Rijndam Electrical Transport company :D

rik079
Posts: 76
Joined: 11 Dec 2016, 14:56

Re: Activity

Post by rik079 » 13 Jan 2019, 19:29

Zeker! nu werkt het wel

rik079
Posts: 76
Joined: 11 Dec 2016, 14:56

Re: Activity

Post by rik079 » 14 Jan 2019, 16:03

Nu sluit de game zichzelf af als ik hem wil laden... doet ie niet als die dienstnunmmers er niet in staan...

Code: Select all

 
 <consists>
  <consist start="A01">
   <train pack="London" file="LUS7.xml" number="101">
    <car id="0" scrollsign1="0.0" scrollsign2="11"/>
    <car id="6" scrollsign1="0.0" scrollsign2="11"/>
   </train>
  </consist>

  <consist start="A01" position="130">
   <train pack="London" file="LUS7.xml" number="102">
    <car id="0" scrollsign1="0.0" scrollsign2="12"/>
    <car id="6" scrollsign1="0.0" scrollsign2="12"/>
   </train>
  </consist>

  <consist start="A01" position="260">
   <train pack="London" file="LUS7.xml" number="103">
    <car id="0" scrollsign1="0.0" scrollsign2="13"/>
    <car id="6" scrollsign1="0.0" scrollsign2="13"/>
   </train>
  </consist>

  <consist start="A03">
   <train pack="London" file="LUS7.xml" number="104">
    <car id="0" scrollsign1="0.0" scrollsign2="14"/>
    <car id="6" scrollsign1="0.0" scrollsign2="14"/>
   </train>
  </consist>

  <consist start="A03" position="130">
   <train pack="London" file="LUS7.xml" number="105">
    <car id="0" scrollsign1="0.0" scrollsign2="15"/>
    <car id="6" scrollsign1="0.0" scrollsign2="15"/>
   </train>
  </consist>

  <consist start="A03" position="260">
   <train pack="London" file="LUS7.xml" number="106">
    <car id="0" scrollsign1="0.0" scrollsign2="16"/>
    <car id="6" scrollsign1="0.0" scrollsign2="16"/>
   </train>
  </consist>

  <consist start="A04">
   <train pack="London" file="LUS7.xml" number="107">
    <car id="0" scrollsign1="0.0" scrollsign2="17"/>
    <car id="6" scrollsign1="0.0" scrollsign2="17"/>
   </train>
  </consist>

  <consist start="A04" position="130">
   <train pack="London" file="LUS7.xml" number="108">
    <car id="0" scrollsign1="0.0" scrollsign2="18"/>
    <car id="6" scrollsign1="0.0" scrollsign2="18"/>
   </train>
  </consist>

  <consist start="A02">
   <train pack="London" file="LU1973_DE.xml" number="201">
    <car id="0" scrollsign1="0.0" scrollsign2="21"/>
    <car id="3" scrollsign1="0.0" scrollsign2="21"/>
   </train>
  </consist>

  <consist start="A02" position="60"">
   <train pack="London" file="LU1973_DE.xml" number="202">
    <car id="0" scrollsign1="0.0" scrollsign2="22"/>
    <car id="3" scrollsign1="0.0" scrollsign2="22"/>
   </train>
  </consist>

  <consist start="A02" position="120">
   <train pack="London" file="LU1973_DE.xml" number="203">
    <car id="0" scrollsign1="0.0" scrollsign2="23"/>
    <car id="3" scrollsign1="0.0" scrollsign2="23"/>
   </train>
  </consist>

  <consist start="A02" position="180">
   <train pack="London" file="LU1973_DE.xml" number="204">
    <car id="0" scrollsign1="0.0" scrollsign2="24"/>
    <car id="3" scrollsign1="0.0" scrollsign2="24"/>
   </train>
  </consist>

  <consist start="A02" position="240">
   <train pack="London" file="LU1973_DE.xml" number="205">
    <car id="0" scrollsign1="0.0" scrollsign2="25"/>
    <car id="3" scrollsign1="0.0" scrollsign2="25"/>
   </train>
  </consist>

  <consist start="A02" position="300">
   <train pack="London" file="LU1973_DE.xml" number="206">
    <car id="0" scrollsign1="0.0" scrollsign2="26"/>
    <car id="3" scrollsign1="0.0" scrollsign2="26"/>
   </train>
  </consist>



  <consist start="A05">
   <train pack="London" file="LU1995_A.xml" number="4011">
    <car id="0" scrollsign1="0.0" scrollsign2="41"/>
    <car id="6" scrollsign1="0.0" scrollsign2="41"/>
   </train>
   <train pack="London" file="LU1995_B.xml" number="4012">
    <car id="0" scrollsign1="0.0" scrollsign2="41"/>
    <car id="6" scrollsign1="0.0" scrollsign2="41"/>
   </train>
  </consist>

  <consist start="A05" position="115">
   <train pack="London" file="LU1995_A.xml" number="4021">
    <car id="0" scrollsign1="0.0" scrollsign2="42"/>
    <car id="6" scrollsign1="0.0" scrollsign2="42"/>
   </train>
   <train pack="London" file="LU1995_B.xml" number="4022">
    <car id="0" scrollsign1="0.0" scrollsign2="42"/>
    <car id="6" scrollsign1="0.0" scrollsign2="42"/>
   </train>
  </consist>

  <consist start="A05" position="230">
   <train pack="London" file="LU1995_A.xml" number="4031">
    <car id="0" scrollsign1="0.0" scrollsign2="43"/>
    <car id="6" scrollsign1="0.0" scrollsign2="43"/>
   </train>
   <train pack="London" file="LU1995_B.xml" number="4032">
    <car id="0" scrollsign1="0.0" scrollsign2="43"/>
    <car id="6" scrollsign1="0.0" scrollsign2="43"/>
   </train>
  </consist>


  <consist start="A06">
   <train pack="London" file="LU1995_A.xml" number="4041">
    <car id="0" scrollsign1="0.0" scrollsign2="44"/>
    <car id="6" scrollsign1="0.0" scrollsign2="44"/>
   </train>
   <train pack="London" file="LU1995_B.xml" number="4042">
    <car id="0" scrollsign1="0.0" scrollsign2="44"/>
    <car id="6" scrollsign1="0.0" scrollsign2="44"/>
   </train>
  </consist>



  <consist start="A06" position="115">
   <train pack="London" file="LU1995_A.xml" number="4051">
    <car id="0" scrollsign1="0.0" scrollsign2="45"/>
    <car id="6" scrollsign1="0.0" scrollsign2="45"/>
   </train>
   <train pack="London" file="LU1995_B.xml" number="4052">
    <car id="0" scrollsign1="0.0" scrollsign2="45"/>
    <car id="6" scrollsign1="0.0" scrollsign2="45"/>
   </train>
  </consist>



  <consist start="A06" position="230">
   <train pack="London" file="LU1995_A.xml" number="4061">
    <car id="0" scrollsign1="0.0" scrollsign2="46"/>
    <car id="6" scrollsign1="0.0" scrollsign2="46"/>
   </train>
   <train pack="London" file="LU1995_B.xml" number="4062">
    <car id="0" scrollsign1="0.0" scrollsign2="46"/>
    <car id="6" scrollsign1="0.0" scrollsign2="46"/>
   </train>
  </consist>



  <consist start="A07">
   <train pack="London" file="LU1995_A.xml" number="4071">
    <car id="0" scrollsign1="0.0" scrollsign2="47"/>
    <car id="6" scrollsign1="0.0" scrollsign2="47"/>
   </train>
   <train pack="London" file="LU1995_B.xml" number="4072">
    <car id="0" scrollsign1="0.0" scrollsign2="47"/>
    <car id="6" scrollsign1="0.0" scrollsign2="47"/>
   </train>
  </consist>



  <consist start="A07" position="115">
   <train pack="London" file="LU1995_A.xml" number="4081">
    <car id="0" scrollsign1="0.0" scrollsign2="48"/>
    <car id="6" scrollsign1="0.0" scrollsign2="48"/>
   </train>
   <train pack="London" file="LU1995_B.xml" number="4082">
    <car id="0" scrollsign1="0.0" scrollsign2="48"/>
    <car id="6" scrollsign1="0.0" scrollsign2="48"/>
   </train>
  </consist>



  <consist start="A07" position="230">
   <train pack="London" file="LU1995_A.xml" number="4091">
    <car id="0" scrollsign1="0.0" scrollsign2="49"/>
    <car id="6" scrollsign1="0.0" scrollsign2="49"/>
   </train>
   <train pack="London" file="LU1995_B.xml" number="4092">
    <car id="0" scrollsign1="0.0" scrollsign2="49"/>
    <car id="6" scrollsign1="0.0" scrollsign2="49"/>
   </train>
  </consist>



  <consist start="A08" position="20">
   <train pack="London" file="LU1995_A.xml" number="4101">
    <car id="0" scrollsign1="0.0" scrollsign2="40"/>
    <car id="6" scrollsign1="0.0" scrollsign2="40"/>
   </train>
   <train pack="London" file="LU1995_B.xml" number="4102">
    <car id="0" scrollsign1="0.0" scrollsign2="40"/>
    <car id="6" scrollsign1="0.0" scrollsign2="40"/>
   </train>
  </consist>
 </consists>

Post Reply