482
edits
Line 161: | Line 161: | ||
Save the -set.xml file with the changes. | Save the -set.xml file with the changes. | ||
==STEP 3: Add the Bombable Nasal code== | ==STEP 3: Add the Bombable Nasal code to the Model XML file== | ||
Bombable needs to have certain code run when the AI or MP aircraft initializes. The code is in [[Nasal]], FlightGear's scripting language. The code gives Bombable needed information about the aircraft (dimensions, vulnerabilities, weapons, etc) and also the code tells Bombable which systems to initialize for this aircraft. | Bombable needs to have certain code run when the AI or MP aircraft initializes. The code is in [[Nasal]], FlightGear's scripting language. The code gives Bombable needed information about the aircraft (dimensions, vulnerabilities, weapons, etc) and also the code tells Bombable which systems to initialize for this aircraft. | ||
Line 478: | Line 478: | ||
Save the file. | Save the file. | ||
===Notes=== | |||
The statement include="F-15E_StrikeEagle-bombableinclude.xml" indicates that F-15E_StrikeEagle-bombableinclude.xml will be in the same directory as F-15E_StrikeEagle.xml. That directory is Aircraft/F-15E/Models -- so make sure that the -bombableinclude.xml file is indeed in that directory! | |||
Model files can have only ONE Nasal <load> section and one <unload> section. | |||
If you have more than one, the second and subsequent <load>/<unload> sections are ignored. | |||
The problem? Your aircraft may already have a <load> or <unload> section. When you add the Bombable code, one of the two <load> sections (the pre-existing one or Bombable's) will be ignored. | |||
The solution is to combine the two <load> sections into one, and the same with the <unload> sections. You'll need to know a little about [[Nasal]] programming to do anything complicated, but as a rule you can just copy/paste whatever is in the aircraft's <load> section to the start of Bombable's <load> section, and the same with <unload>. | |||
==STEP 4. Add to an AI Scenario== | ==STEP 4. Add to an AI Scenario== |
edits