Oolite Bulletins

For information and discussion about Oolite.
It is currently Thu Nov 23, 2017 3:49 am

All times are UTC




Post new topic  Reply to topic  [ 130 posts ]  Go to page Previous 15 6 7 8 9
Author Message
PostPosted: Sun Jan 01, 2017 5:39 pm 
Offline
Competent
Competent
User avatar

Joined: Wed May 18, 2016 8:19 pm
Posts: 61
Quote:
:
Image
Which OXP contains the orange-white-ship and the cobra-like-ones (black and grey)?

_________________
First shoot, then ask who was there.
Image


Top
   
PostPosted: Sun Jan 01, 2017 7:16 pm 
Offline
Competent
Competent

Joined: Sat Dec 31, 2016 5:36 pm
Posts: 44
Quote:
Quote:
:
Image
Which OXP contains the orange-white-ship and the cobra-like-ones (black and grey)?
The Grey and Black ships are Cobra MK4, I think.


Top
   
PostPosted: Mon Jan 02, 2017 12:52 am 
Offline
---- E L I T E ----
---- E L I T E ----
User avatar

Joined: Mon May 20, 2013 9:53 pm
Posts: 2424
Location: Budapest, Hungary (Mainly Agricultural Democracy, TL10)
Quote:
Which OXP contains the orange-white-ship and the cobra-like-ones (black and grey)?
Tiger Ray and [wiki]King Cobra[/wiki]. The darker one is not a variant but the same ship than the lighter just in this moment shaders decided to show the dark side instead, which is not highlighted by the sun.

Cobra IV is very similar due to the predecessor of King Cobra (which is numbered to mkVI), it really has a playable Black variant also.

_________________
OXPs by Norby


Top
   
PostPosted: Tue Jan 03, 2017 5:53 pm 
Offline
Competent
Competent
User avatar

Joined: Wed Aug 24, 2016 10:30 pm
Posts: 36
Hey Norby,

Is there some way to force escorts to disengage? I just started off a new commander and hacked in two sidewinder escorts. I intended to make a story off of them about a ravaged family trying to make their way in the space system. However on my maiden voyage, I got attacked by a granite cobra and a few Morays, and had to dump cargo. They got off my back, but continued to harass my escorts. As I fled, I tried to call the escorts back however they would refuse to disengage... eventually they were overwhelmed and died.

Oh and on a side note, is there also a way to make the landing pad invisible? Still there and functioning, just not rendered in?

Thanks for all you do :)

_________________
I'm Ravished by the Sheer Implausibility of that Last Statement

It should be a crime for Anacondas to fly without escort. That much temptation is just too much to resist.


Top
   
PostPosted: Tue Jan 03, 2017 9:37 pm 
Offline
---- E L I T E ----
---- E L I T E ----
User avatar

Joined: Mon May 20, 2013 9:53 pm
Posts: 2424
Location: Budapest, Hungary (Mainly Agricultural Democracy, TL10)
If you prime and activate the deck then the status of all escorts in MFD should change to Landing. In this AI state they are programmed to flight straight to you and ignore attacks. If not then I do not know why and I can not do anything to fix it, sorry.

Another way is if an escort are farther from you than 24km (almost max. scanner range) then switch target to the enemy nearest to you, or if nothing hostile is in your scanner then start follow you.

You can hide the deck if you comment out the 1150. line in escortdeck.js, just add // at the start like this:
Code:
//	w.$EscortDeckV.position = dp;

_________________
OXPs by Norby


Top
   
PostPosted: Sun Apr 02, 2017 7:41 pm 
Offline
Competent
Competent

Joined: Fri Mar 17, 2017 1:49 am
Posts: 62
I'm trying to detect just my own escorts and just when they're attached to the ship. I want to exclude them from Telescope & Fast Target Selector.
I'm currently using:
Code:
		if( entity.dataKey.indexOf( "escortdeck" ) === 0
			&& ( entity.AIState === 'DECK' || entity.AIState === 'LOCKED' )
			&&  entity.collisionExceptions.indexOf( player.ship ) > -1 ) return false;
Is there an easier/better way?

_________________
"Better to be thought a fool, boy, than to open your trap and remove all doubt." - Grandma [over time, just "Shut your trap... fool"]
"The only stupid questions are the ones you fail to ask." - Dad
How do I...? Nevermind.


Top
   
PostPosted: Sun Apr 02, 2017 8:22 pm 
Offline
---- E L I T E ----
---- E L I T E ----
User avatar

Joined: Mon May 20, 2013 9:53 pm
Posts: 2424
Location: Budapest, Hungary (Mainly Agricultural Democracy, TL10)
First this is needed for speed:
Code:
this.startUp = function() {
    this.$ED = worldScripts.escortdeck; //cached pointer
}
Then the official way of your check:
Code:
var ed = this.$ED;
if( ed ) { //escortdeck oxp is present
    var i = ed.$EscortDeckShip.indexOf(entity);
    if( i >= 0 && ed.EscortDeckShipPos[i] ) //entity is on deck
        return false; //so exclude this entity from target list
}
I guess you looked into escordteck.js just a bit hard to find the answer in 3000 lines. ;)

_________________
OXPs by Norby


Top
   
PostPosted: Sun Apr 02, 2017 9:01 pm 
Offline
Competent
Competent

Joined: Fri Mar 17, 2017 1:49 am
Posts: 62
in equipment.plist, "available_to_all" = yes; that means NPCs can have them too, right?

also, I only want to exclude them when they're attached to the deck, not when they're flying about

I dumped the entity and:
isDock is false
owner is null
hence my awkward checking. I just want to make surethat you're the one setting AIState & collisionExceptions so I can rely on them.

_________________
"Better to be thought a fool, boy, than to open your trap and remove all doubt." - Grandma [over time, just "Shut your trap... fool"]
"The only stupid questions are the ones you fail to ask." - Dad
How do I...? Nevermind.


Top
   
PostPosted: Sun Apr 02, 2017 11:17 pm 
Offline
---- E L I T E ----
---- E L I T E ----
User avatar

Joined: Mon May 20, 2013 9:53 pm
Posts: 2424
Location: Budapest, Hungary (Mainly Agricultural Democracy, TL10)
At the moment no mean to add a deck equipment to an NPC due to the js do nothing with them. It is a player only device until somebody not improve it further.

The dataKey can be anything since derelict ships also usabe sometimes as escorts so better if not checked.

These AI states and collisionException are used by escortdeck only as far as I know so maybe usable but not a sure way. This is why I suggest to check in the arrays where the deck js store escorts. If the EscortDeckShipPos array is set for that escort then surely landed on the deck, this is the internal way what escortdeck.js use all times when needed to know if a ship is on the deck.

_________________
OXPs by Norby


Top
   
PostPosted: Mon Apr 03, 2017 12:07 am 
Offline
Competent
Competent

Joined: Fri Mar 17, 2017 1:49 am
Posts: 62
thanks, dude - much appreciated!

_________________
"Better to be thought a fool, boy, than to open your trap and remove all doubt." - Grandma [over time, just "Shut your trap... fool"]
"The only stupid questions are the ones you fail to ask." - Dad
How do I...? Nevermind.


Top
   
Display posts from previous:  Sort by  
Post new topic  Reply to topic  [ 130 posts ]  Go to page Previous 15 6 7 8 9

All times are UTC


Who is online

Users browsing this forum: No registered users and 20 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
cron
Powered by phpBB® Forum Software © phpBB Limited