Page 3 of 15

Re: [RELEASE] Towbar OXP v0.9

Posted: Mon Sep 23, 2013 10:15 am
by Norby
Both requests are in the towbar.js since v0.1. ;)

this.$TowbarFixed = true; //show towbar if no towed ship also, false works as retractable
this.$TowbarShow = true; //false change it to an invisible tractor beam

Re: [RELEASE] Towbar OXP v0.9

Posted: Mon Sep 23, 2013 11:40 am
by Corny
Ah, so I can change this in the script directly. Good foresight, Sir!
So, you can break the tractor beam if you do too sharp turns? :P

Re: [RELEASE] Towbar OXP v0.9

Posted: Mon Sep 23, 2013 12:01 pm
by Norby
Corny wrote:
So, you can break the tractor beam if you do too sharp turns? :P
Of course. :lol:

Many things can be justified in this Ooniverse with some technical blah, in this case about overloading the condensators of the beam. ;)

Re: [RELEASE] Towbar OXP v0.9

Posted: Mon Sep 23, 2013 1:59 pm
by Corny
Okay, got it to work so far - the target appeared and let me tug it to the station.
The controls are kinda jerky when I'm towing a ship, and I stopped the ship when I attempted to connect the towbar. After that, it took multiple attempts to get my ship moving (a Cobra Mark I towing a Moray Medical Boat). Is that intended (bug or feature :D)?
Also, when I attempted to get moving, I used my fuel injectors which were not towbar-safe. When I arrived back at the station, they were listed as broken. That's kinda mean, they don't work anyway when I'm trying to tow ships and after that, they're broken? :(

Also, I have a problem getting HUDs besides the NumericHUDv3.11 working.
You've included a .plist with stuff I'm supposed to paste into the HUD. The FighterHUD I wanted to use uses a different formatting, however, and the Towbar-OXP still breaks the HUD :(

That's how it looks in NumericHUDv3.11:

Code: Select all

[...]
legends		= // these are drawn, in order, before the dials, add any other images you want here
	(
		//Above crosshairs display
  		{ equipment_required="EQ_DTABR"; x=0; y=52.5; y_origin=0; height=16; width=64; image = "detectors_red.png"; },
  		{ equipment_required="EQ_DTABY"; x=0; y=52.5; y_origin=0; height=16; width=64; image = "detectors_yellow.png"; },
  		{ equipment_required="EQ_DTA00"; x=10; y=40; y_origin=0; height=20; width=16; text="0"; },
  		{ equipment_required="EQ_DTA01"; x=10; y=40; y_origin=0; height=20; width=16; text="1"; },
  		{ equipment_required="EQ_DTA02"; x=10; y=40; y_origin=0; height=20; width=16; text="2"; },
  		{ equipment_required="EQ_DTA03"; x=10; y=40; y_origin=0; height=20; width=16; text="3"; },
  		{ equipment_required="EQ_DTA04"; x=10; y=40; y_origin=0; height=20; width=16; text="4"; },
  		{ equipment_required="EQ_DTA05"; x=10; y=40; y_origin=0; height=20; width=16; text="5"; },
  		{ equipment_required="EQ_DTA06"; x=10; y=40; y_origin=0; height=20; width=16; text="6"; },
  		{ equipment_required="EQ_DTA07"; x=10; y=40; y_origin=0; height=20; width=16; text="7"; },
  		{ equipment_required="EQ_DTA08"; x=10; y=40; y_origin=0; height=20; width=16; text="8"; },
  		{ equipment_required="EQ_DTA09"; x=10; y=40; y_origin=0; height=20; width=16; text="9"; },
  		{ equipment_required="EQ_DTA10"; x=2; y=40; y_origin=0; height=20; width=16; text="0"; },
  		{ equipment_required="EQ_DTA11"; x=2; y=40; y_origin=0; height=20; width=16; text="1"; },
  		{ equipment_required="EQ_DTA12"; x=2; y=40; y_origin=0; height=20; width=16; text="2"; },
  		{ equipment_required="EQ_DTA13"; x=2; y=40; y_origin=0; height=20; width=16; text="3"; },
  		{ equipment_required="EQ_DTA14"; x=2; y=40; y_origin=0; height=20; width=16; text="4"; },
  		{ equipment_required="EQ_DTA15"; x=2; y=40; y_origin=0; height=20; width=16; text="5"; },
  		{ equipment_required="EQ_DTA16"; x=2; y=40; y_origin=0; height=20; width=16; text="6"; },
  		{ equipment_required="EQ_DTA17"; x=2; y=40; y_origin=0; height=20; width=16; text="7"; },
  		{ equipment_required="EQ_DTA18"; x=2; y=40; y_origin=0; height=20; width=16; text="8"; },
  		{ equipment_required="EQ_DTA19"; x=2; y=40; y_origin=0; height=20; width=16; text="9"; },
  		{ equipment_required="EQ_DTA20"; x=-6; y=40; y_origin=0; height=20; width=16; text="0"; },
  		{ equipment_required="EQ_DTA21"; x=-6; y=40; y_origin=0; height=20; width=16; text="1"; },
  		{ equipment_required="EQ_DTA22"; x=-6; y=40; y_origin=0; height=20; width=16; text="2"; },
  		{ equipment_required="EQ_DTA23"; x=-6; y=40; y_origin=0; height=20; width=16; text="3"; },
  		{ equipment_required="EQ_DTA24"; x=-6; y=40; y_origin=0; height=20; width=16; text="4"; },
  		{ equipment_required="EQ_DTA25"; x=-6; y=40; y_origin=0; height=20; width=16; text="5"; },
  		{ equipment_required="EQ_DTA26"; x=-6; y=40; y_origin=0; height=20; width=16; text="6"; },
  		{ equipment_required="EQ_DTA27"; x=-6; y=40; y_origin=0; height=20; width=16; text="7"; },
  		{ equipment_required="EQ_DTA28"; x=-6; y=40; y_origin=0; height=20; width=16; text="8"; },
  		{ equipment_required="EQ_DTA29"; x=-6; y=40; y_origin=0; height=20; width=16; text="9"; },
  		{ equipment_required="EQ_DTAV"; x=-14; y=40; y_origin=0; height=20; width=16; text="v"; },
  		{ equipment_required="EQ_DTA30"; x=-14; y=40; y_origin=0; height=20; width=16; text="0"; },
  		{ equipment_required="EQ_DTA31"; x=-14; y=40; y_origin=0; height=20; width=16; text="1"; },
  		{ equipment_required="EQ_DTA32"; x=-14; y=40; y_origin=0; height=20; width=16; text="2"; },
  		{ equipment_required="EQ_DTA33"; x=-14; y=40; y_origin=0; height=20; width=16; text="3"; },
  		{ equipment_required="EQ_DTA34"; x=-14; y=40; y_origin=0; height=20; width=16; text="4"; },
  		{ equipment_required="EQ_DTA35"; x=-14; y=40; y_origin=0; height=20; width=16; text="5"; },
  		{ equipment_required="EQ_DTA36"; x=-14; y=40; y_origin=0; height=20; width=16; text="6"; },
  		{ equipment_required="EQ_DTA37"; x=-14; y=40; y_origin=0; height=20; width=16; text="7"; },
  		{ equipment_required="EQ_DTA38"; x=-14; y=40; y_origin=0; height=20; width=16; text="8"; },
  		{ equipment_required="EQ_DTA39"; x=-14; y=40; y_origin=0; height=20; width=16; text="9"; },
  		{ equipment_required="EQ_DTA40"; x=-22; y=40; y_origin=0; height=20; width=16; text="0"; },
  		{ equipment_required="EQ_DTA41"; x=-22; y=40; y_origin=0; height=20; width=16; text="1"; },
  		{ equipment_required="EQ_DTA42"; x=-22; y=40; y_origin=0; height=20; width=16; text="2"; },
  		{ equipment_required="EQ_DTA43"; x=-22; y=40; y_origin=0; height=20; width=16; text="3"; },
  		{ equipment_required="EQ_DTA44"; x=-22; y=40; y_origin=0; height=20; width=16; text="4"; },
  		{ equipment_required="EQ_DTA45"; x=-22; y=40; y_origin=0; height=20; width=16; text="5"; },
  		{ equipment_required="EQ_DTA46"; x=-22; y=40; y_origin=0; height=20; width=16; text="6"; },
  		{ equipment_required="EQ_DTA47"; x=-22; y=40; y_origin=0; height=20; width=16; text="7"; },
  		{ equipment_required="EQ_DTA48"; x=-22; y=40; y_origin=0; height=20; width=16; text="8"; },
  		{ equipment_required="EQ_DTA49"; x=-22; y=40; y_origin=0; height=20; width=16; text="9"; },
  		{ equipment_required="EQ_DTA50"; x=-30; y=40; y_origin=0; height=20; width=16; text="0"; },
  		{ equipment_required="EQ_DTA51"; x=-30; y=40; y_origin=0; height=20; width=16; text="1"; },
  		{ equipment_required="EQ_DTA52"; x=-30; y=40; y_origin=0; height=20; width=16; text="2"; },
  		{ equipment_required="EQ_DTA53"; x=-30; y=40; y_origin=0; height=20; width=16; text="3"; },
  		{ equipment_required="EQ_DTA54"; x=-30; y=40; y_origin=0; height=20; width=16; text="4"; },
  		{ equipment_required="EQ_DTA55"; x=-30; y=40; y_origin=0; height=20; width=16; text="5"; },
  		{ equipment_required="EQ_DTA56"; x=-30; y=40; y_origin=0; height=20; width=16; text="6"; },
  		{ equipment_required="EQ_DTA57"; x=-30; y=40; y_origin=0; height=20; width=16; text="7"; },
  		{ equipment_required="EQ_DTA58"; x=-30; y=40; y_origin=0; height=20; width=16; text="8"; },
  		{ equipment_required="EQ_DTA59"; x=-30; y=40; y_origin=0; height=20; width=16; text="9"; },
  		{ equipment_required="EQ_DTAAF"; x=14; y=40; y_origin=0; height=20; width=16; text=">"; },
  		{ equipment_required="EQ_DTAFW"; x=-30; y=40; y_origin=0; height=20; width=16; text="<"; },
  		{ equipment_required="EQ_DTAMALF"; x=-14; y=40; y_origin=0; height=20; width=16; text="???"; },
  		{ equipment_required="EQ_DTADER"; x=30; y=40; y_origin=0; height=20; width=16; text="Derelict"; },
  		{ equipment_required="EQ_DTAEMP"; x=-75; y=40; y_origin=0; height=20; width=16; text="Empty"; },
  		{ equipment_required="EQ_DTAMIN"; x=-75; y=40; y_origin=0; height=20; width=16; text="Mined"; },
  		{ equipment_required="EQ_DTAFUG"; x=18; y=40; y_origin=0; height=20; width=16; text="**"; },
  		{ equipment_required="EQ_DTAOFF"; x=18; y=40; y_origin=0; height=20; width=16; text="*"; },
  		{ equipment_required="EQ_DTAPER"; x=10; y=40; y_origin=0; height=20; width=16; text="%"; },
[...]
And here's where I pasted it into the FighterHUD's .plist:

Code: Select all

[...]
<key>legends</key><!-- these are drawn, in order, before the dials, add any other images you want here -->
		{ equipment_required="EQ_DTADER"; x=-25; y=40; y_origin=0; height=20; width=16; text="Derelict"; },
  		{ equipment_required="EQ_DTAEMP"; x=-75; y=40; y_origin=0; height=20; width=16; text="Empty"; },
  		{ equipment_required="EQ_DTAMIN"; x=-75; y=40; y_origin=0; height=20; width=16; text="Mined"; },
	<array>
		<dict>
			<key>image</key>
			<string>hud.png</string>
			<key>width</key>
			<real>640</real>
			<key>height</key>
			<real>480</real>
			<key>x</key>
			<integer>0</integer>
			<key>y</key>
			<integer>0</integer>
			<key>alpha</key>
			<real>1.00</real>
		</dict>
		<dict>
			<key>image</key>
			<string>wireframe.png</string>
			<key>width</key>
			<real>60</real>
			<key>height</key>
			<real>60</real>
			<key>x</key>
			<integer>264</integer>
			<key>y</key>
			<integer>-195</integer>
			<key>alpha</key>
			<real>0.90</real>
		</dict>
		<dict>
			<key>text</key>
			<string>SPD</string>
			<key>x</key>
			<integer>-309</integer>
			<key>y</key>
			<string>-169</string>
			<key>height</key>
			<integer>8</integer>
			<key>width</key>
			<integer>8</integer>
		</dict>
		<dict>
			<key>text</key>
			<string>FUEL</string>
			<key>x</key>
			<integer>-309</integer>
			<key>y</key>
			<string>-177</string>
			<key>height</key>
			<integer>8</integer>
			<key>width</key>
			<integer>8</integer>
		</dict>
		<dict>
			<key>text</key>
			<string>CAB</string>
			<key>x</key>
			<integer>-309</integer>
			<key>y</key>
			<string>-185</string>
			<key>height</key>
			<integer>8</integer>
			<key>width</key>
			<integer>8</integer>
		</dict>
		<dict>
			<key>text</key>
			<string>TEMP</string>
			<key>x</key>
			<integer>-309</integer>
			<key>y</key>
			<string>-193</string>
			<key>height</key>
			<integer>8</integer>
			<key>width</key>
			<integer>8</integer>
		</dict>
		<dict>
			<key>text</key>
			<string>ALT</string>
			<key>x</key>
			<integer>-309</integer>
			<key>y</key>
			<string>-201</string>
			<key>height</key>
			<integer>8</integer>
			<key>width</key>
			<integer>8</integer>
		</dict>
		<dict>
			<key>text</key>
			<string>Fwd</string>
			<key>x</key>
			<integer>291</integer>
			<key>y</key>
			<string>-228</string>
			<key>height</key>
			<integer>8</integer>
			<key>width</key>
			<integer>8</integer>
		</dict>
		<dict>
			<key>text</key>
			<string>Aft</string>
			<key>x</key>
			<integer>224</integer>
			<key>y</key>
			<string>-228</string>
			<key>height</key>
			<integer>8</integer>
			<key>width</key>
			<integer>8</integer>
		</dict>
		<dict>
			<key>text</key>
			<string>ORD</string>
			<key>x</key>
			<integer>-309</integer>
			<key>y</key>
			<string>-221</string>
			<key>height</key>
			<integer>8</integer>
			<key>width</key>
			<integer>8</integer>
		</dict>
    </array>
[...]
It's probably not too surprising that this doesn't work. So, how to get it working?
Also, I tried to record towing a ship - shot it until the pilot ejected, approached it etc. - and when I was about to tow it, I just got "Target Lost" and the derelict just diappeared without a trace (and without a bump in my shields). :shock:

Re: [RELEASE] Towbar OXP v0.9

Posted: Mon Sep 23, 2013 2:05 pm
by Cody
Corny wrote:
The FighterHUD I wanted to use uses a different formatting...
I use Fighter Hud - it could do with an update, I reckon.

Re: [RELEASE] Towbar OXP v0.9

Posted: Mon Sep 23, 2013 2:52 pm
by Smivs
@Corny, I think you are trying to mix XML and openstep there - don't think that's going to work :(

Re: [RELEASE] Towbar OXP v0.9

Posted: Mon Sep 23, 2013 2:58 pm
by Norby
Corny wrote:
The controls are kinda jerky when I'm towing a ship
There is a feature to slow the turning rates when tow a ship which can cause this but need some other reason also to happen which I do not know yet, maybe a video help if you can make it.
Corny wrote:
When I arrived back at the station, they were listed as broken.
You can not tow with broken towbar, this means you lost the towed ship somewhere. You must get a console message when broken and buy another or wait for fixing if has a Towbar Repair Bot. You can check visually in the aft view (but if set to retractable then when towing a ship only).
Corny wrote:
The FighterHUD I wanted to use uses a different formatting
See this example about the two different formatting, must not mix these in one file.
If you can translate the 3 important lines to xml then please do and publish it, if not then I will do it a bit later.
Corny wrote:
Also, I tried to record towing a ship - shot it until the pilot ejected, approached it etc. - and when I was about to tow it, I just got "Target Lost" and the derelict just diappeared without a trace (and without a bump in my shields). :shock:
Maybe other ship shot it down? Please try to do it again and record it. My attempts are not showed similar surprises so thank you for your interesting tests. :)

Re: [RELEASE] Towbar OXP v0.9

Posted: Mon Sep 23, 2013 8:05 pm
by Corny
Norby wrote:
Corny wrote:
The controls are kinda jerky when I'm towing a ship
There is a feature to slow the turning rates when tow a ship which can cause this but need some other reason also to happen which I do not know yet, maybe a video help if you can make it.
I'll post the video once I got the time editing them. :) It was all recorded.
Norby wrote:
Corny wrote:
When I arrived back at the station, they were listed as broken.
You can not tow with broken towbar, this means you lost the towed ship somewhere. You must get a console message when broken and buy another or wait for fixing if has a Towbar Repair Bot. You can check visually in the aft view (but if set to retractable then when towing a ship only).
You got me wrong - the towbar worked fine and I got the ship back to the station. The fuel injectors were broken.
Norby wrote:
Corny wrote:
Also, I tried to record towing a ship - shot it until the pilot ejected, approached it etc. - and when I was about to tow it, I just got "Target Lost" and the derelict just diappeared without a trace (and without a bump in my shields). :shock:
Maybe other ship shot it down? Please try to do it again and record it. My attempts are not showed similar surprises so thank you for your interesting tests. :)
There was no ship nearby. It just disappeared in the moment where I would've started towing it.
I got it recorded and will link the video once I got it edited and uploaded.

Re: [RELEASE] Towbar OXP v0.9

Posted: Mon Sep 23, 2013 10:12 pm
by Corny

Re: [RELEASE] Towbar OXP v0.91

Posted: Tue Sep 24, 2013 8:24 am
by Norby
Thank you for the reports! Injectors bug fixed in Towbar v0.91. Injecting is disabled if you has not Towbar Compatible Injectors when you tow a ship and now enabled again after you delivered the mission ship.

I can not fix jerky controls but you can disable the slow turn feature now to avoid it.

The insertintohudlegends.plist now contain XML lines also.

I can not found any reason to the disappearing ship. There is nothing in the log?

Re: [RELEASE] Towbar OXP v0.91

Posted: Tue Sep 24, 2013 12:01 pm
by Corny
Norby wrote:
Thank you for the reports! Injectors bug fixed in Towbar v0.91. Injecting is disabled if you has not Towbar Compatible Injectors when you tow a ship and now enabled again after you delivered the mission ship.
Great :)
Norby wrote:
The insertintohudlegends.plist now contain XML lines also.
Thanks a bunch! I didn't know how to convert it.
Norby wrote:
I can not found any reason to the disappearing ship. There is nothing in the log?
This is everything I found in the respective time frame:

Code: Select all

15:24:51.818 [cheat.tentative]: POSSIBLE CHEAT DETECTED
15:25:01.132 [texture.load.png.error]: ***** A PNG loading error occurred for /Applications/Spiele/Oolite/AddOns/Dredgers 2.4.6.oxp/Textures/dredgerTraderEngines_emission.png: bad adaptive filter value.
15:36:25.253 [script.javaScript.exception.unexpectedType]: ***** JavaScript exception (Random_Hits 1.5.2): TypeError: system.addShips(barRole, 1, barPosition, 10) is null
15:36:25.254 [script.javaScript.exception.unexpectedType]:       /Applications/Spiele/Oolite/AddOns/RandomHits1.5.3.oxp/Scripts/oolite-randomHits.js, line 795.
15:39:29.117 [script.javaScript.timeLimit]: ***** ERROR: Script "(null)" ran for 0.208945 seconds and has been terminated.
15:53:05.718 [script.javaScript.timeLimit]: ***** ERROR: Script "(null)" ran for 0.120046 seconds and has been terminated.
15:58:01.831 [exit.context]: Exiting: Cocoa terminate event.
And no, I have no idea what this cheat thing is about. There are cheats in Oolite? :shock:

Re: [RELEASE] Towbar OXP v0.91

Posted: Tue Sep 24, 2013 12:52 pm
by spara
Corny wrote:

Code: Select all

15:36:25.253 [script.javaScript.exception.unexpectedType]: ***** JavaScript exception (Random_Hits 1.5.2): TypeError: system.addShips(barRole, 1, barPosition, 10) is null
15:36:25.254 [script.javaScript.exception.unexpectedType]:       /Applications/Spiele/Oolite/AddOns/RandomHits1.5.3.oxp/Scripts/oolite-randomHits.js, line 795.
15:39:29.117 [script.javaScript.timeLimit]: ***** ERROR: Script "(null)" ran for 0.208945 seconds and has been terminated.
15:53:05.718 [script.javaScript.timeLimit]: ***** ERROR: Script "(null)" ran for 0.120046 seconds and has been terminated.
These come from Random Hits and I found at least one related bug that needs to be corrected. Nothing to do with Towbar, unless you are trying to tow a space bar :lol:.
Corny wrote:
And no, I have no idea what this cheat thing is about. There are cheats in Oolite? :shock:
This refers to save file hacking, me thinks.

Re: [RELEASE] Towbar OXP v0.91

Posted: Tue Sep 24, 2013 1:04 pm
by Norby
Corny wrote:
I didn't know how to convert it.
Maybe you forgot what you said in the XML to OpenStep converter thread. ;)
Corny wrote:
15:24:51.818 [cheat.tentative]: POSSIBLE CHEAT DETECTED
There are cheats in Oolite? :shock:
Maybe you modified your savegame (based on forum search).
There are so many cheat in Oolite, there is a dedicated Cheats category in the wiki. :)
Corny wrote:
15:39:29.117 [script.javaScript.timeLimit]: ***** ERROR: Script "(null)" ran for 0.208945 seconds and has been terminated.
TimeLimit is a common problem of all OXP writers, to step forward need to be repeatable (at least on the same machine) and need to find which OXP produce it. My usual way to find is the binary halving: remove the first half of the OXPs and if the problem persist then halve again. If gone then must double check the another half due to there is possible to gone also and exists only if both part present.

Can you produce the disappearing ship with the Towbar OXP only? If yes then you do not need to go through the halving process.

Re: [RELEASE] Towbar OXP v0.91

Posted: Tue Sep 24, 2013 1:20 pm
by Norby
spara wrote:
unless you are trying to tow a space bar :lol:.
The towable mass is limited to 1.6 times of the mass of your ship so to tow a space bar you must ride a BaseShip. :)
Moreover the bar must be derelict which is very unwonted imho. ;)

Re: [RELEASE] Towbar OXP v0.91

Posted: Tue Sep 24, 2013 1:42 pm
by spara
Norby wrote:
spara wrote:
unless you are trying to tow a space bar :lol:.
The towable mass is limited to 1.6 times of the mass of your ship so to tow a space bar you must ride a BaseShip. :)
Moreover the bar must be derelict which is very unwonted imho. ;)
If I was more of a writer, a deserted station (space bar maybe) could be a central part of a gloomy oxp.