ademes
Mitglieder-
Gesamte Inhalte
131 -
Benutzer seit
-
Letzter Besuch
Letzte Besucher des Profils
Der "Letzte Profil-Besucher"-Block ist deaktiviert und wird anderen Benutzern nicht angezeigt.
-
Hi Timba and Metallix, Thank you both to come back on this matter. I will try to be more explicit. In many train manager that I know (CDM Rail, Train Controller,...) , the entire layout is cut into segments (Bahn Kanton??) residing between 2 switches, one switch and a signal, 2 signals. In addition,a bumper also determines the limit of a segment, including a reverse option. These segments are linked together in order to build an itinerary. If the link between two segments is a switch or a lot of switches (called a grill in English), than the position of each of these switches determine how a train goes from one segment to the other. The succession of segments and grills together finally build the itinerary. When those itineraries are defined, each train may (it is not mandatory) be attached to one itinerary. Normally, the itinerary name is saved as an object.variable in the engine of the train permitting to change the itinerary easily. I knew that a group may never be treated as a track because a group may contain different type of objects having nothing to do with the tracks. But the notion of "segment" seems to be unknown in MBS and that is the reason of my proposal. The new possibillity when double clicking on a track open in my mind a view of segmentation in MBS. That"s all. Now, I suppose that all users of MBS have their own solution and I respect that. And I also understand and appreciate the work done by the team to develop and maintain the MBS application. My purpose was just to bring my contribution to the project; Nothing more! With all my respect André
-
The one here that need to review his position on this forum is not me, Goetz… It's you and if you don't want to be botherred, let other responsible answer. What I said gently was : you are making a mistake with your previous answer : it may not work because a group is NOT a track and so the event "train enter/leave a track" will never be triggered with your solution. That is the point. Next, if you check the event where the group is used, MBS however indicates "train enters a track", just because of the keyword. Remove the keyword and you will discover that the only event that may be triggered is "a variable is changed" And finally, I do not accept insults; I'm not lazy! André
-
Hi Goetz, Sorry you are right! I forgot to give you a feedback! The list is well sorted as you explained Oh yeah! great! and it is ok; I may enter keyword and variables. BUT, snif, snif… it don't work as the group with the keyword doesn't trigger the event Watch the layout where I tested it. Look at group L1 with keyword station Regards André Test grill 1.mbp
-
Hi Andy Where is such Lua function coming from? Is there a place somewhere to have a list of all these functions? Thank you André
-
Hello, I have a question / suggestion : When one double clic on a track, all the tracks between 2 switches are selected. Great! But the result is "multiple selection" on which one can only Apply some properties. My question/suggestion : as these lot of tracks correspond to a section (or block or segment or any name one can give), is it not possible to : give an objet's name to the selection in order to use it the same way as other objects give the possibility to assign object's variables to that new object. Thank you André
-
Hello, I try the Following in an even : 1. define the table : rails table {0 items} 2. run : table.insert($("test").variables["rails"], track.name) 3. result : the table "rails" is well filled with all track's names, but the order is Strange - see attached 1 4. define in a script the table : liste = {} define a table : liste2 table {0 items} 5. run : table.insert(liste, track.name) $("test").variables["liste2"] = liste 6. result : the table liste2 is well filled with all track's names, but now the order is correct - see attached 2 Regards André
-
Thank you metallix. I upgrade now to new version André
-
Hello, I'm still in version 5.0.6.1 and I wasn't informed of an upgrade to 5.0.7.0 including the new features I'm waiting for. I mean that when opening my actual version, I don't have the Opportunity to upgrade. Should I do something else? Thank you André
-
Ok! Thank you martin51. This solves also my previous post. Regards André
-
Hello, In addition to my previous message, it seems that the function "return" doesn't run properly Under MBS. The Following should return a value for n : function foo(n) print ("function foo") return n*2 end foo(4) print ("N = ", n) should return N = 8, but it returns nothing (N = ) Regards André
-
Hello, I have a problem with "Function" : I call a function with the Following arguments : setgrill (grill, listgrill, train, return_code) where "grill" and "setgrill" are tables, Train is the object "vehicle" and return_code is a variable number set to 0 when Calling the function. Inside the function, return_code will be set to 0 if OK and to 4 if KO. But when I test the value of return_code after the call to the function, its value is always 0 even if the function set it to 4. I've inserted the instruction "return return_code" at the end of the function, but it seems that the caller continue to test the "local" return_code. My question is : how to define the argument return_code to be valid either in the caller and in the function. Setting it as a global variable is not a solution as the function may be called by different caller at the same time. Thank you André
-
OK! Great and this is a good reason. André
-
Thank you Goetz. I will wait. Is using external files (Lua files) another alternative? And, if yes, is it recommended and what are the rules to apply? Regards André
-
Hi goetz, Thank you for your help and it works fine now... except that the table "liste", even if correctly filled by the event, appears empty if I open the script where it is defined. I suppose that this is because the table is dynamic, howver its content is available in another event. So my question now is : how to keep the content of the table "liste" when I save and close the layout. My objective is trying to build (more or less automatically) a table containing the itinerary of a specific train. Could you help me? regards André
-
Hi Goetz, Thank you but however, the code you suggested didn't work as one can see in the attached tracing; in addition, the table "liste" remains empty and the vehicle doesn't stop. What's wrong??