Of course you are still bound by how commodities.plist works, but I am sure with a little work you will be able to understand it.

Moderators: winston, another_commander
Code: Select all
This.originalGovernment = system.government
system.gorvenment = ourgovernment
This.originalEconomy = system.government
system.economy = ourEconomy
spawn("coriolis",1,x,y,z)
// restore system stats..
// you can do this to all system statistics... (i Use it in solarSystems oxp)
system.gorvernment = this.originalGovernment
system.economy = this.originalEconomy
I don't think that would work. As soon as you remove the main station to replace it, another station in the system automagically becomes the main station. So when you spawn your replacement one, it will probably no longer be the main station.Commander McLane wrote:While it is true that you cannot script commodity prices or quantities in a main station (or any station that uses the "default" entry from commodities.plist), and especially you cannot change anything anymore in a station that is already spawned, you can via OXP replace the main station with another station which can have its custom commodities.plist entry. This is the basic technical idea behind specialevents.oxp.
Of course you are still bound by how commodities.plist works, but I am sure with a little work you will be able to understand it.
I have a solution for that!Thargoid wrote:I don't think that would work. As soon as you remove the main station to replace it, another station in the system automagically becomes the main station. So when you spawn your replacement one, it will probably no longer be the main station.
Code: Select all
{
"0 7" = {
description = "Lave is most famous for its vast rain forests and the Laveian tree grub. Due to a population explosion among the tree grubs there is currently a shortage of food on Lave which has led to high food prices.";
station = "my_custom_station";
};
}
Is it possible to set conditions in front of a planetary description? That way, a system's content could also be altered dynamically via the planetinfo.plist.Commander McLane wrote:any changes in planetinfo.plist will of course be permanent
Code: Select all
{
conditions = ("gui_screen_string oneof GUI_SCREEN_STATUS, GUI_SCREEN_EQUIP_SHIP, GUI_SCREEN_MARKET, GUI_SCREEN_SHORT_RANGE_CHART", "dockedAtMainStation_bool equal YES", "mission_assassins equal assassins_STAGE3", "mission_assassins_jumpcount greaterthan 4", "galaxy_number equal 6", "score_number greaterthan 823");
do = (
"setMissionMusic: none",
"setMissionImage: assassins.png",
setGuiToMissionScreen,
"addMissionText: hitbrief_3",
"set: mission_assassins assassins_STAGE3a",
"set: mission_assassins_jumpcount 0",
"setMissionDescription: assassins_header6",
"setSpecificPlanetInfo: 6=73=description=Orramaor is noted for its companion world Apollodorus. Formaly the corporate headquarters of Soin Classic Shipyards Ltd, the Planet Orramaor is now famous for a large crater on the southern continent."
);
},
I am not sure. But I don't think so. Conditions in planetinfo.plist can only be used in script_actions, as far as I understand. And if you use setSpecificPlanetInfo in a script_actions in planetinfo.plist, what's the advantage over doing it directly in your script.plist?Lestradae wrote:Is it possible to set conditions in front of a planetary description? That way, a system's content could also be altered dynamically via the planetinfo.plist.Commander McLane wrote:any changes in planetinfo.plist will of course be permanent
Well, personally I would find that more clearly arranged (especially with my oxp having a bazillion of different XML and Java scripts simultanously running) but perhaps that's a matter of taste.Commander McLane wrote:And if you use setSpecificPlanetInfo in a script_actions in planetinfo.plist, what's the advantage over doing it directly in your script.plist?
That one's interesting. Is there a XML command for the planetinfo.plist that lets a piece of music or a sound file be played when the player enters a system? I could use something like that for my special systems.LittleBear wrote:do = (
"setMissionMusic: none"