Hello everyone, I know this is the wrong forum to ask, but I seem unable to post in the Scenario Scripting forum.
I'd like to have a trigger, that activates a script where I get either the Driver's name or the Train name, so that I can set visible a certain mesh based on that name.
I know how to show/hide meshes and all that jazz, but I can't find a way to put this together:
include "gs.gs" include "world.gs" include "train.gs" include "MapObject.gs"
class xx isclass Train {
public void Init(void) {
inherited();
}
public native string GetTrainDisplayName(void){
string trainName = Train.GetTrainDisplayName();
if (trainName == "something") {
then do xy;
} else {
do yx;
}
}
}
I can't understand what's missing.. I know the script is too short to work, but still
Thanks for everybody who can reply, and help me. Any advice, new idea, or critic is well appreciated.
I'd like to have a trigger, that activates a script where I get either the Driver's name or the Train name, so that I can set visible a certain mesh based on that name.
I know how to show/hide meshes and all that jazz, but I can't find a way to put this together:
- train.GetTrainDisplayName();
- DriverCharacter driver = train.GetActiveDriver();
- Loco = Train.GetFrontmostLocomotive();
include "gs.gs" include "world.gs" include "train.gs" include "MapObject.gs"
class xx isclass Train {
public void Init(void) {
inherited();
}
public native string GetTrainDisplayName(void){
string trainName = Train.GetTrainDisplayName();
if (trainName == "something") {
then do xy;
} else {
do yx;
}
}
}
I can't understand what's missing.. I know the script is too short to work, but still
Thanks for everybody who can reply, and help me. Any advice, new idea, or critic is well appreciated.