Page 3 of 4

Posted: Sat May 12, 2007 1:24 pm
by Dr. Nil
I turned the appearance of genships way down (as I've done with a lot of other ships) to keep them legendary, before even playing with the oxp installed. I haven't come across one yet, but I look forward to it. :)

Alternative code for ...\Oolite\AddOns\out\genship.oxp\Config\script.plist

Code: Select all

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>

   <key>generation-ship-script01</key>

   <array>

      <dict>

         <key>conditions</key>

         <array>

            <string>status_string equal STATUS_EXITING_WITCHSPACE</string>
			<string>planet_number equal -1</string>

         </array>

         <key>do</key>

         <array>

			<dict>
				<key>conditions</key>
				<array>
					<string>d100_number lessthan 3</string>
				</array>
				<key>do</key>
				<array>
					<string>addShips: generationship-1 1</string>
				</array>
			</dict>
			<dict>
				<key>conditions</key>
				<array>
					<string>d100_number lessthan 3</string>
				</array>
				<key>do</key>
				<array>
					<string>addShips: generationship-2 1</string>
				</array>
			</dict>
			<dict>
				<key>conditions</key>
				<array>
					<string>d100_number lessthan 3</string>
				</array>
				<key>do</key>
				<array>
					<string>addShips: generationship-3 1</string>
				</array>
			</dict>
			<dict>
				<key>conditions</key>
				<array>
					<string>d100_number lessthan 3</string>
				</array>
				<key>do</key>
				<array>
					<string>addShips: generationship-4 1</string>
				</array>
			</dict>
			<dict>
				<key>conditions</key>
				<array>
					<string>d100_number lessthan 3</string>
				</array>
				<key>do</key>
				<array>
					<string>addShips: generationship-5 1</string>
				</array>
			</dict>
			<dict>
				<key>conditions</key>
				<array>
					<string>d100_number lessthan 3</string>
				</array>
				<key>do</key>
				<array>
					<string>addShips: generationship-6 1</string>
				</array>
			</dict>
			<dict>
				<key>conditions</key>
				<array>
					<string>d100_number lessthan 3</string>
				</array>
				<key>do</key>
				<array>
					<string>addShips: generationship-7 1</string>
				</array>
			</dict>
			<dict>
				<key>conditions</key>
				<array>
					<string>d100_number lessthan 3</string>
				</array>
				<key>do</key>
				<array>
					<string>addShips: generationship-8 1</string>
				</array>
			</dict>
			<dict>
				<key>conditions</key>
				<array>
					<string>d100_number lessthan 3</string>
				</array>
				<key>do</key>
				<array>
					<string>addShips: generationship-9 1</string>
				</array>
			</dict>
			<dict>
				<key>conditions</key>
				<array>
					<string>d100_number lessthan 3</string>
				</array>
				<key>do</key>
				<array>
					<string>addShips: generationship-10 1</string>
				</array>
			</dict>
			<dict>
				<key>conditions</key>
				<array>
					<string>d100_number lessthan 3</string>
				</array>
				<key>do</key>
				<array>
					<string>addShips: generationship-11 1</string>
				</array>
			</dict>
			<dict>
				<key>conditions</key>
				<array>
					<string>d100_number lessthan 3</string>
				</array>
				<key>do</key>
				<array>
					<string>addShips: generationship-11 1</string>
				</array>
			</dict>
			<dict>
				<key>conditions</key>
				<array>
					<string>d100_number lessthan 3</string>
				</array>
				<key>do</key>
				<array>
					<string>addShips: generationship-12 1</string>
				</array>
			</dict>
			<dict>
				<key>conditions</key>
				<array>
					<string>d100_number lessthan 3</string>
				</array>
				<key>do</key>
				<array>
					<string>addShips: generationship-13 1</string>
				</array>
			</dict>
			<dict>
				<key>conditions</key>
				<array>
					<string>d100_number lessthan 3</string>
				</array>
				<key>do</key>
				<array>
					<string>addShips: generationship-14 1</string>
				</array>
			</dict>
			<dict>
				<key>conditions</key>
				<array>
					<string>d100_number lessthan 3</string>
				</array>
				<key>do</key>
				<array>
					<string>addShips: generationship-15 1</string>
				</array>
			</dict>
			<dict>
				<key>conditions</key>
				<array>
					<string>d100_number lessthan 3</string>
				</array>
				<key>do</key>
				<array>
					<string>addShips: generationship-16 1</string>
				</array>
			</dict>
			<dict>
				<key>conditions</key>
				<array>
					<string>d100_number lessthan 3</string>
				</array>
				<key>do</key>
				<array>
					<string>addShips: generationship-17 1</string>
				</array>
			</dict>
			<dict>
				<key>conditions</key>
				<array>
					<string>d100_number lessthan 3</string>
				</array>
				<key>do</key>
				<array>
					<string>addShips: generationship-18 1</string>
				</array>
			</dict>
			<dict>
				<key>conditions</key>
				<array>
					<string>d100_number lessthan 3</string>
				</array>
				<key>do</key>
				<array>
					<string>addShips: generationship-19 1</string>
				</array>
			</dict>
			<dict>
				<key>conditions</key>
				<array>
					<string>d100_number lessthan 3</string>
				</array>
				<key>do</key>
				<array>
					<string>addShips: generationship-20 1</string>
				</array>
			</dict>
			<dict>
				<key>conditions</key>
				<array>
					<string>d100_number lessthan 3</string>
				</array>
				<key>do</key>
				<array>
					<string>addShips: generationship-21 1</string>
				</array>
			</dict>
			<dict>
				<key>conditions</key>
				<array>
					<string>d100_number lessthan 3</string>
				</array>
				<key>do</key>
				<array>
					<string>addShips: generationship-22 1</string>
				</array>
			</dict>
			<dict>
				<key>conditions</key>
				<array>
					<string>d100_number lessthan 3</string>
				</array>
				<key>do</key>
				<array>
					<string>addShips: generationship-23 1</string>
				</array>
			</dict>
			<dict>
				<key>conditions</key>
				<array>
					<string>d100_number lessthan 3</string>
				</array>
				<key>do</key>
				<array>
					<string>addShips: generationship-24 1</string>
				</array>
			</dict>
			<dict>
				<key>conditions</key>
				<array>
					<string>d100_number lessthan 3</string>
				</array>
				<key>do</key>
				<array>
					<string>addShips: generationship-25 1</string>
				</array>
			</dict>
			<dict>
				<key>conditions</key>
				<array>
					<string>d100_number lessthan 3</string>
				</array>
				<key>do</key>
				<array>
					<string>addShips: generationship-26 1</string>
				</array>
			</dict>
			<dict>
				<key>conditions</key>
				<array>
					<string>d100_number lessthan 3</string>
				</array>
				<key>do</key>
				<array>
					<string>addShips: generationship-27 1</string>
				</array>
			</dict>
			<dict>
				<key>conditions</key>
				<array>
					<string>d100_number lessthan 3</string>
				</array>
				<key>do</key>
				<array>
					<string>addShips: generationship-28 1</string>
				</array>
			</dict>
			<dict>
				<key>conditions</key>
				<array>
					<string>d100_number lessthan 3</string>
				</array>
				<key>do</key>
				<array>
					<string>addShips: generationship-29 1</string>
				</array>
			</dict>
			<dict>
				<key>conditions</key>
				<array>
					<string>d100_number lessthan 3</string>
				</array>
				<key>do</key>
				<array>
					<string>addShips: generationship-30 1</string>
				</array>
			</dict>
         </array>

      </dict>

   </array>

</dict>

</plist>

Posted: Sat May 12, 2007 1:43 pm
by LittleBear
Have changed it to greaterthan 8 for the version on my machine, but I haven't released this one yet as I still need to sort out redoing the script to make weeks really weeks, put in the resized-docking bay model and some other stuff. Will get round to it, but it'll be in one big-update rather than loads of little ones.

To be honest, the unnecessary check for ships, is just from the fact that my scripts tend to be really long (Assassins is somthing ridiculous like 800 commands), so I tend to C&P segments a lot when I need an adding command both for launching and exiting_witchspace. I knew I needed it for launching (in case eg: your launching from the Monk Station itself), C&Ped it for the EXITING_WITCHSPACE condition.

I'll add a greaterthan -1 for the next realease. Although neither me or Uncle Reno were getting the Monk Stations in witchspace.

Posted: Sat May 12, 2007 3:43 pm
by TGHC
Uncle Reno wrote:
OK, just forced a misjump on 1.68 and ended up in witchspace with 2 Generation ships, 2 Super Cobras, 1 Mosquito Trader, a Viper Escort, a couple of Navy Vipers and 2 Thargoid ships.
and a partridge in a pear tree boom boom!

>exits very rapidly!

Posted: Sat May 12, 2007 8:55 pm
by Uncle Reno
Dr. Nil wrote:
I turned the appearance of genships way down (as I've done with a lot of other ships) to keep them legendary, before even playing with the oxp installed. I haven't come across one yet, but I look forward to it. :)

Alternative code for ...\Oolite\AddOns\out\genship.oxp\Config\script.plist

Code: Select all

Dr Nil's Generation Ship code (see above post)
Am I reading that wrong or is there a, admittedly very small, chance of having them all appear at one time?
Cmdr McLane wrote:
Perhaps not all of them, but at least for the SuperCobras I definitely can answer: yes. There are three of them created everytime on EXITING_WITCHSPACE, whether you are in a system or had a misjump doesn't matter.
Just had a look in the OXP and there is a small script to do just that. Do you think that was for testing purposes? I've now disabled it but if you do that then you also need to add extra roles to the shipdata as otherwise its only role is Supercobra.

Posted: Sat May 12, 2007 9:45 pm
by Commander McLane
Uncle Reno wrote:
Am I reading that wrong or is there a, admittedly very small, chance of having them all appear at one time?
Yes, you're right on that.
Cmdr McLane wrote:
Perhaps not all of them, but at least for the SuperCobras I definitely can answer: yes. There are three of them created everytime on EXITING_WITCHSPACE, whether you are in a system or had a misjump doesn't matter.
Just had a look in the OXP and there is a small script to do just that. Do you think that was for testing purposes? I've now disabled it but if you do that then you also need to add extra roles to the shipdata as otherwise its only role is Supercobra.
I don't think it was for testing but that it was intended just like that. I can however imagine that it was not intended to appear in interstellar space.

Posted: Sun May 13, 2007 8:53 am
by Killer Wolf
Sorry, been absent for a bit.

but - no, haven't got the Black Monks. i've got a few extra-ships OXPS, the Behemoth one included but no other mission/flavour ones. I'm currently in Galaxy 2, if that makes any difference. Re my other threads, i've had loads of ships (Eagles!!) gang up on me even when other ships were attacking them, but in the past when i've been in witchspace everyone's just behaved as normal traders - fight the Thargs, scoop any remaining Thargons, then wander about aimlessly.

it's a bit disconcerting to pile into a barney when an Ophidian Yacht's crying for help, only to spot all the scanner lollipops are gradually turning red :-/

Posted: Wed Jun 06, 2007 5:05 pm
by Arexack_Heretic
Had fun with a recursive script once...let me relate it:

I was testing the behaviour of a destroyer_ship I had designed.
They were behaving oddly jigging to and fro and not shooting anything, but that is not the point.
I added into it's AI a check_group_odds and had it spawn more of itself if it thought itself outclassed.
Somehow each ship though it was it's own group and all of them thought they were outgunned...
To make things worse, I had half of them as pirate, the other half as police. lol
lots of ships.
They were also spacing out when on low energy, so lots of hyperbubbles as well. ;)

Posted: Tue Jun 12, 2007 8:36 am
by Jakob Kramer
Heh... space madness! :)

It could be used for at Fright Bomb. When dropped it affects the perception of other commanders, causing very frightening hallucinations, making the commanders try to escape through witchspace jumps if they have sufficient fuel to reach another system.

A bit like the energy bomb but with the difference that only ships with a fair amount of fuel will "disappear" (and no cargo containers to scoop of course).

WitchbombAI.plist

Posted: Tue Jun 12, 2007 10:05 am
by Arexack_Heretic

Code: Select all

GLOBAL {ENTER = ("setStateTo: NEXT"); UPDATE = (); EXIT = ();};

NEXT = {
ENTER = (scanForHostiles, "pauseAI: 3");
"TARGET_FOUND" = (setTargetToFoundTarget, "performScriptActionOnTarget: performHyperspaceExit", "pauseAI: 2", "setStateTo: NEXT");
"NOTHING_FOUND" = ("pauseAI: 2", becomeExplosion);
UPDATE = ("pauseAI: 2", "setStateTo: NEXT");
EXIT = ();
};
Will scanfor.hostiles, hyperspace.hostiles then detonate.

Posted: Tue Jun 12, 2007 11:09 am
by Griff
heh, great stuff JK & A_H! the fright bomb sounds like a really funny idea.
if you chase the ship down the wormhole do you meet them on the other side? if so, you could use the bomb to seperate a ship from it's escorts? (by ammending A_H's script to scan for a ship with a specific role rather than scanforhostiles), oo, and with ahrumans new player teleportation code maybe you could punish the player by sending him far across the system and into the sun if they trigger the bomb at the wrong time

Posted: Tue Jun 12, 2007 11:50 am
by Arexack_Heretic
yes, each wormhole leads only to the ship that made it.

Other ships may in fact have jumped to the same system, but only the ship generating the witchbubble you followed is spawned.

IIRC

Re: WitchbombAI.plist

Posted: Tue Jun 12, 2007 9:57 pm
by Commander McLane
Arexack_Heretic wrote:

Code: Select all

GLOBAL {ENTER = ("setStateTo: NEXT"); UPDATE = (); EXIT = ();};

NEXT = {
ENTER = (scanForHostiles, "pauseAI: 3");
"TARGET_FOUND" = (setTargetToFoundTarget, "performScriptActionOnTarget: performHyperspaceExit", "setStateTo: NEXT");
"NOTHING_FOUND" = (becomeExplosion);
UPDATE = ("pauseAI: 2");
EXIT = ();
};
Will scanfor.hostiles, hyperspace.hostiles then detonate.
So sorry that I always seem to criticize your code. :oops:

According to the wiki it's "scriptActionOnTarget: performHyperSpaceExit". And wouldn't it need another scanForHostiles in the UPDATE-part? (Though I'm not sure about that. Can be that it keeps scanning without that.)
Other ships may in fact have jumped to the same system, but only the ship generating the witchbubble you followed is spawned.
No, all ships are spawned. That applies for escorts that jumped through their mother's wormhole. But it applies also for other ships that jumped independently. I once made a long journey of jumps through wormholes, when the Nova-mission was triggered. In every new system everybody immediatly jumped out again and I met them all again in the next system. (Including an ever growing pack of Thargoid Carriers (biiiiiiiig wormholes!).) 8)

Re: WitchbombAI.plist

Posted: Wed Jun 13, 2007 7:32 am
by TGHC
Commander McLane wrote:
I once made a long journey of jumps through wormholes, when the Nova-mission was triggered. In every new system everybody immediatly jumped out again and I met them all again in the next system. (Including an ever growing pack of Thargoid Carriers (biiiiiiiig wormholes!).) 8)
That's the real beauty of this game, so many of us have had unique or rare experiences by doing something a bit different to the norm, you never really know what may happen next! Magnificent!

Posted: Wed Jun 13, 2007 8:13 am
by Arexack_Heretic
That may then explain the exitable destroyer script I ranted obout a few days back in anothe thread...
It jumped out when groupOdds were bad, when exiting hyperspace therealways was added one.
After a several cycles of diving in wormholes, there were <many>.

@McL: yes. I forgot to put "setStateTo: NEXT" in the UPDATE after the pause. This way it cycles through NEXT continuously, untill there are no hostiles left.
EDITED to work and modified so that each cycle takes 5 seconds in total.

Posted: Wed Jun 13, 2007 8:31 am
by Commander McLane
Arexack_Heretic wrote:
@McL: yes. I forgot to put "setStateTo: NEXT" in the UPDATE after the pause. This way it cycles through NEXT continuously, untill there are no hostiles left.
EDITED to work and modified so that each cycle takes 5 seconds in total.
Each cycle would take 5 seconds also without modification, because inyou way the 2 seconds from the UPDATE will be followed by the 3 seconds from the ENTER.

But is that necessary? I thought UPDATE is meant to be the same as ENTER, just without having entered from another state. So UPDATE = (scanForHostiles, "pauseAI: 5"); should do without "setStateTo: NEXT", shouldn't it?