Train-Sim.Com
Microsoft Train Simulator

Creating a AI Engine

Notice to all visitors and members of the Train-Sim.Com message forums:
If you plan on using a signature banner in your posts, we would like to remind you that there is a maximum size for banners. That maximum is 450 pixels wide by 120 pixels high, and not to exceed 25k. Your compliance is appreciated. FORUM RULES Problems? There are two common reasons for problems with logging in and posting messages. The first is that you are running a firewall that prevents your messages from being sent to the server. The other is that you have cookies disabled; the DCForum software requires cookies to work properly.

Previous Topic | Next Topic

Printer-friendly copy Email this topic to a friend

Reading Topic #25541

Charter Member · 3555 posts

How do you create a AI engine for a engine that currently does not have one?Chris Bogley
Syracuse New YorkCreating a AI Engine – image 1

Alert | IP

Printer-friendly page | Edit | Reply | Reply With Quote | Top

RE: Creating a AI Engine, ATF1224, Nov-15-04, 08:41 PM, (1) RE: Creating a AI Engine, Busdriver, Nov-15-04, 08:49 PM, (2) RE: Creating a AI Engine, Mark_Blum, Nov-15-04, 08:52 PM, (3) RE: Creating a AI Engine, SVTS, Nov-16-04, 08:05 AM, (4) RE: Creating a AI Engine, Curt, Nov-16-04, 09:02 AM, (5) RE: Creating a AI Engine, Busdriver, Nov-16-04, 09:25 PM, (6) RE: Creating a AI Engine, SVTS, Nov-17-04, 09:13 AM, (7) RE: Creating a AI Engine, Busdriver, Nov-17-04, 11:31 AM, (8) RE: Creating a AI Engine, Busdriver, Nov-17-04, 08:03 PM, (9)

Conferences | Topics | Previous Topic | Next Topic

Charter Member · 559 posts

RE: Creating a AI Engine

LAST EDITED ON Nov-15-04 AT 08:54 PM (EST)

Hi Chris:I don't know every trick, but 99 percent of it is simple. Copy and rename the engine file, and delete things you don't need in the file. Example:If the engine is named "mygeep" (ok, so I have no imagination), then copy and rename the file as "mygeepAI". Then go into the engine file and rename it the same way on the 1st Wagon line, the Engine line, and the next wagon line, and then in the Name line.Next, delete the line sending you to the CabView line calling up the (cvf) file, and the sound line referencing the cab sounds "cab.sms". That's most of it.If you're in the mood to play around, you can alter the lighting section and delete anything that doesn't have to do with AI running, but you do need to know what you're doing in the lighting section. The techdocs that came with the game are pretty good at explaining this. And if you're really in a mood to experiment you can have special sounds for the AI unit. That's over my head. If you do a search in the sound forum for AI engines you should find a thread that explains most of this better than I did.Hope this gets you started.Mark
A Southern Railway FanEdited: Well, or you could do what Bryce said!! LOL

Alert | IP

Printer-friendly page | Edit | Reply | Reply With Quote | Top

Charter Member · 3555 posts

RE: Creating a AI Engine

Okay, a few have suggested Route Riter. So my next question is what about the sounds for the AI engine? For example, I aliased a Santa Fe SD 40 using MLT's KHP 2.0 EMD sounds. Is it a simple matter of just aliasing the one line in the AI engine using the same line from the KHP SD 40 AI engine to get the EMD AI sound? This is the main reason I want to create AI engines, so I don't have a block of engines idleing. I can't even hear my lead unit in notch 8 with the other 5 units just humming.Chris Bogley
Syracuse New YorkCreating a AI Engine – image 4

Alert | IP

Printer-friendly page | Edit | Reply | Reply With Quote | Top

Member since Nov-3-03 · 453 posts

RE: Creating a AI Engine

Chris,What the AI engines make for sounds is completely dependent upon what the sms in Scalability Level 0 tells it to. Some sms files have the engine sound tied to speed which is not very realistic when going downhill at 60 mph and 0 throttle. The AIs will sound like they are in run 8. What I have done in a few cases is had the volume curve of the engine sound gradually drop off with speed so that the lead unit can be heard more over the AIs once you are rolling, yet when at 0 mph, the idling is still there for those station stops. I do the fade gradually so it is not noticed as you get rolling and notch up. If there is a track sound wav in the sms like MLT does, that also helps since the engines will still be making track noises at speed, yet the diesel sound turns itself down so that you can hear your lead unit.I hope this made sense.Bryce

Alert | IP

Printer-friendly page | Edit | Reply | Reply With Quote | Top

Charter Member · 3555 posts

RE: Creating a AI Engine

Can you shed some more light on this? I have often found it to be annoying that when in idle on a flat stretch of track, I have a AI unit still running in notch 8. Didn't think there was a way around it till you mentioned it. Tell me more oh great one!Chris Bogley
Syracuse New YorkCreating a AI Engine – image 5

Alert | IP

Printer-friendly page | Edit | Reply | Reply With Quote | Top

Member since Nov-3-03 · 453 posts

RE: Creating a AI Engine

Chris,I'm at work, but will check in with you later today. None of my notes/files are here.Thanks for the compliment. I don't consider myself to be the great one, but I sure do love this stuff, and all of the tinkering it provides. Glad I can (hopefully) help.Bryce

Alert | IP

Printer-friendly page | Edit | Reply | Reply With Quote | Top

Member since Nov-3-03 · 453 posts

RE: Creating a AI Engine

Chris,Here is a stream from an AIeng.sms file I have. To give credit, I believe it started as an MLT sms file, but I have heavily modified it:Stream (
Priority ( 6 )
Triggers ( 3
Initial_Trigger ( StartLoop ( 1 File ( "..\\..\\xxxx\\xxxxxcruise1.wav" -1 ) SelectionMethod ( SequentialSelection ) ) )
Variable_Trigger ( Speed_Inc_Past 70.0 ReleaseLoopRelease () )
Variable_Trigger ( Speed_Dec_Past 70.0 StartLoop ( 1 File ( "..\\..\\xxxx\\xxxxxcruise1.wav" -1 ) SelectionMethod ( SequentialSelection ) ) )
)
FrequencyCurve(
SpeedControlled
CurvePoints ( 3
-25 15025
0 10025
25 15025
)
Granularity ( 50 )
)
VolumeCurve(
SpeedControlled
CurvePoints ( 5
-50.0 0.35
-7.0 0.5
0.0 1.0
7.0 0.5
50.0 0.35
)
Granularity ( 0.05 )
)
)Here are some notes on an AI sms file:
It must be set to Scalability Level 0 at the top.
This example stream is the first stream that has to do with engine sound (there could be many other streams before and after this). Notice that it is not tied to variable 2 (throttle position) since AI units don't respond to that. Instead it is tied speed. With the initial trigger set to start the loop, you will have an idle sound at startup. The volume curve at the bottom tells the sound to be playing at 100% at 0 mph, 50% (0.5) volume when the train gets to 7mph, and then continues to turn down the volume to 35% when it gets to 50MPH. Note that this is a curve, so it will be a smooth transition from 100% to 50% to 35% between the speeds indicated (points on the curve).The original sms file had a cruise 2 stream for higher speeds, but I put a # in front of the word stream to make it not play at all since I don't want any more engine sounds at the higher speeds. This is especially effective when you have a stream that plays track noise outside the engine since it will allow the AI to be making noise, yet not engine noise that you want to hear from your lead unit.I leave a frequency curve as well because right at startup, when the train starts moving, it is cool to hear all of the engines rev a bit in the low rpms, but the volume drops out with speed making the lead unit the primary sound.Sound files are relatively easy to play with since you can put a # in front of any stream you do not want to hear for testing, and simply start a saved game with the engine(s) you want to test with. Also, you do not need to get completely out of MSTS for your changes to the sms to take effect. I usually hit esc, exit the activity. Press Alt-Tab to go to the sms in your favorite text editor. Save changes in the sms. Click on the MSTS icon in the start bar. Load saved activity. Play with new settings.
I hope I didn't miss anything. It has been quite some time since I played with and modified these files, so the memory may have faded on some details.Bryce

Alert | IP


[ Home | MSTS Forum | MSTS FAQ | How To... | File Library ] Copyright © 2004 by Nels Anderson. All Rights Reserved.

Restored from the Train-Sim.Com archive, captured November 22, 2004. About this archive.