[RELEASE] HardShips OXP v0.89

Discussion and information relevant to creating special missions, new ships, skins etc.

Moderators: another_commander, winston

User avatar
Josef
Competent
Competent
Posts: 60
Joined: Sat May 29, 2021 6:20 pm
Location: Wien

Re: [RELEASE] HardShips OXP v0.89

Post by Josef »

Cholmondely wrote: Sun Jun 27, 2021 6:41 pm


Cost 300000 deci-credits (divide by 10 to get credits)
Tech Level 14 (available on 15+)

Not too sure that the last is supposed to mean, I'm afraid!
Thank you!
Josef
User avatar
Josef
Competent
Competent
Posts: 60
Joined: Sat May 29, 2021 6:20 pm
Location: Wien

Re: [RELEASE] HardShips OXP v0.89

Post by Josef »

Hi everybody,
does anybody know how much the Laser Drones and the Hard Drones cost and at what TL it is possible to buy them?
Josef
User avatar
Cholmondely
Archivist
Archivist
Posts: 6630
Joined: Tue Jul 07, 2020 11:00 am
Location: The Delightful Domains of His Most Britannic Majesty (industrial? agricultural? mainly anything?)
Contact:

Re: [RELEASE] HardShips OXP v0.89

Post by Cholmondely »

Josef wrote: Fri Jul 16, 2021 7:48 am
Hi everybody,
does anybody know how much the Laser Drones and the Hard Drones cost and at what TL it is possible to buy them?
No details of cost or TL for either! There is a note on Hiran's Hard Drone page (top left corner) saying that it is a Police Hard Drone - which implies to me that it's not for sale.

It's seems to be a complex OXP - have you tried it?

What sort of OXPs do you use? You should have a pretty good feel for most of them by now....

Oh! And, by the way, how have you managed using a german-language keyboard? Have there been any problems?
Comments wanted:
Missing OXPs? What do you think is missing?
Lore: The economics of ship building How many built for Aronar?
Lore: The Space Traders Flight Training Manual: Cowell & MgRath Do you agree with Redspear?
User avatar
Josef
Competent
Competent
Posts: 60
Joined: Sat May 29, 2021 6:20 pm
Location: Wien

Re: [RELEASE] HardShips OXP v0.89

Post by Josef »

Cholmondely wrote: Fri Jul 16, 2021 8:34 am

No details of cost or TL for either! There is a note on Hiran's Hard Drone page (top left corner) saying that it is a Police Hard Drone - which implies to me that it's not for sale.

It's seems to be a complex OXP - have you tried it?

What sort of OXPs do you use? You should have a pretty good feel for most of them by now....

Oh! And, by the way, how have you managed using a german-language keyboard? Have there been any problems?
I didn't try that OXP I just need that information for a database.
The german-language keyboard was not a problem. I bought the computer in Austria where I live.
Josef
User avatar
Josef
Competent
Competent
Posts: 60
Joined: Sat May 29, 2021 6:20 pm
Location: Wien

Re: [RELEASE] HardShips OXP v0.89

Post by Josef »

Cholmondely wrote: Fri Jul 16, 2021 8:34 am
There is a note on Hiran's Hard Drone page (top left corner) saying that it is a Police Hard Drone - which implies to me that it's not for sale.

Do you know, where that page is because I didn't find it?
Josef
User avatar
Cholmondely
Archivist
Archivist
Posts: 6630
Joined: Tue Jul 07, 2020 11:00 am
Location: The Delightful Domains of His Most Britannic Majesty (industrial? agricultural? mainly anything?)
Contact:

Re: [RELEASE] HardShips OXP v0.89

Post by Cholmondely »

Josef wrote: Sat Jul 17, 2021 6:31 am
Cholmondely wrote: Fri Jul 16, 2021 8:34 am
There is a note on Hiran's Hard Drone page (top left corner) saying that it is a Police Hard Drone - which implies to me that it's not for sale.

Do you know, where that page is because I didn't find it?
I started with Hiran's Index page (now a Bookmarked tab on my browser) from his outputdir multi-Megabyte "blockbuster" database and clicked on 685 Expansions by Name.

On the new page (alphabetical order - very helpful) I clicked on HardShips

At the bottom of that page there is a list of every equipment and ship included in the HardShips oxz

Then I clicked on Hard Drone under Ships.





But now that I go through it again to type this up, I notice that there are two listings of Hard Drone under ships. I had looked at the second only.

Thinking about it again, if they are ships, they are not necessarily for sale...

You could try asking Norby - he's just over the border from you, in Hungary...
Comments wanted:
Missing OXPs? What do you think is missing?
Lore: The economics of ship building How many built for Aronar?
Lore: The Space Traders Flight Training Manual: Cowell & MgRath Do you agree with Redspear?
User avatar
Krager
---- E L I T E ----
---- E L I T E ----
Posts: 297
Joined: Wed Dec 11, 2024 9:44 pm
Location: Russian

Re: [RELEASE] HardShips OXP v0.89

Post by Krager »

При близком знакомстве заметил неправильную работу дополнения (ошибки).

1. При старте нового коммандира пункт с `HardShips` вероятно задумывался как меню. После нажатия должен был появится выбор из вариантов старта Hard Ships. На самом деле произходит старт на Hard Cobra MK III. Всё. При использовании только одного дополнения `HardShips v0.89` ситуация та же.
Hard0.jpg

2. При покупке выводит информацию о корабле. В пункте лазер, при наличии лазера - указывается его модель. При отсутствии лазера - выходит пункт из меню F3 `Продать лазер`.
Hard1.jpg
Была на другом дополнении похожая проблема с лазером Phkb её уже решал. Где то делал задержку, чтоб вообще никакой информации не появлялось если лазера нет. Было или в TechnicalReferenceLibrary v1.0.1 или в ShipVersion v1.24.1. Не помню в каком.
Hard2.jpg
Пока всё.
А, ещё, остаётся общая ошибка. Когда смотришь информацию о корабле. При отказе его купить - корабль исчезает.
User avatar
phkb
Impressively Grand Sub-Admiral
Impressively Grand Sub-Admiral
Posts: 5687
Joined: Tue Jan 21, 2014 10:37 pm
Location: Writing more OXPs, because the world needs more OXPs.

Re: [RELEASE] HardShips OXP v0.89

Post by phkb »

Krager wrote: Sat Mar 21, 2026 9:35 pm
1. При старте нового коммандира пункт с `HardShips` вероятно задумывался как меню. После нажатия должен был появится выбор из вариантов старта Hard Ships. На самом деле произходит старт на Hard Cobra MK III. Всё. При использовании только одного дополнения `HardShips v0.89` ситуация та же.
This appears to be because of a bug in Oolite, introduced in version 1.82 apparently. At least, that's the first version I found where the HardShips menu doesn't appear. I've got a patch to release to fix this, but there's a bit going on at the moment with Oolite releases, so I don't want to commit anything right now.

In the interim, open the "hardmenu.js" file in HardShips, find the "this.guiScreenChanged" function and change it from this:

Code: Select all

this.guiScreenChanged = function(to, from) {
	if( missionVariables.oolite_tutorial ) return;
	//start in HardCobra v1.0 if press F1 before choose any ship
	if( !worldScripts["rocketmenu"] && ( from == "GUI_SCREEN_INTRO2" || from == "GUI_SCREEN_NEWGAME")
		&& to == "GUI_SCREEN_STATUS") {
//		log(this.name, oolite.compareVersion("1.79")+" "+player.ship.dataKey);//debug
		if( 0 < oolite.compareVersion("1.79") //if version is less than 1.79
 			//or the ship in hardships-menu.oolite-save loaded by scenario.plist
			|| player.ship.dataKey == "hardcobra3-player" ) { //to allow starting in hauler, etc.
			this.$HardMenu_ReplacePlayerShip2(this.$HardMenu_Name[0], 0); 
			this.$HardMenu_NewGameScreen();
		}
	}
	delete this.guiScreenChanged;
}
to this:

Code: Select all

this.guiScreenChanged = function(to, from) {
	if( missionVariables.oolite_tutorial ) return;
	//start in HardCobra v1.0 if press F1 before choose any ship
	if( !worldScripts["rocketmenu"] && ( from == "GUI_SCREEN_INTRO2" || from == "GUI_SCREEN_NEWGAME" || missionVariables.HardShips_Started == null)
		&& to == "GUI_SCREEN_STATUS") {
//		log(this.name, oolite.compareVersion("1.79")+" "+player.ship.dataKey);//debug
		if( 0 < oolite.compareVersion("1.79") //if version is less than 1.79
 			//or the ship in hardships-menu.oolite-save loaded by scenario.plist
			|| player.ship.dataKey == "hardcobra3-player" ) { //to allow starting in hauler, etc.
			this.$HardMenu_ReplacePlayerShip2(this.$HardMenu_Name[0], 0); 
			this.$HardMenu_NewGameScreen();
		}
	}
	missionVariables.HardShips_Started = "loaded";
	delete this.guiScreenChanged;
}
That should sort the first issue out.
Krager wrote: Sat Mar 21, 2026 9:35 pm
2. При покупке выводит информацию о корабле. В пункте лазер, при наличии лазера - указывается его модель. При отсутствии лазера - выходит пункт из меню F3 `Продать лазер`.
This is because the "EQ_WEAPON_NONE" equipment item that is put into empty laser mounts has the description "Remove Laser" in core code. That's not a bug in itself. To fix HardShips, find the "this.$HardMenu_GetPlayerShipData" function, then find these lines:

Code: Select all

	s=player.ship.forwardWeapon;
	if( s!=null) equip+="Forward "+s.name;
	s=player.ship.aftWeapon;
	if( s!=null) equip+=", Aft "+s.name;
	s=player.ship.portWeapon;
	if( s!=null) equip+="\nPort "+s.name;
	s=player.ship.starboardWeapon;
	if( s!=null) equip+=", Starboard "+s.name;
And change them to this:

Code: Select all

	s=player.ship.forwardWeapon;
	if( s!=null && s.equipmentKey != "EQ_WEAPON_NONE") equip+="Forward "+s.name;
	s=player.ship.aftWeapon;
	if( s!=null && s.equipmentKey != "EQ_WEAPON_NONE") equip+=", Aft "+s.name;
	s=player.ship.portWeapon;
	if( s!=null && s.equipmentKey != "EQ_WEAPON_NONE") equip+="\nPort "+s.name;
	s=player.ship.starboardWeapon;
	if( s!=null && s.equipmentKey != "EQ_WEAPON_NONE") equip+=", Starboard "+s.name;
Krager wrote: Sat Mar 21, 2026 9:35 pm
А, ещё, остаётся общая ошибка. Когда смотришь информацию о корабле. При отказе его купить - корабль исчезает.
Which requires a much bigger fix than I'm prepared to do on this OXP. Someone else will need to step in and do that work.
User avatar
Krager
---- E L I T E ----
---- E L I T E ----
Posts: 297
Joined: Wed Dec 11, 2024 9:44 pm
Location: Russian

Re: [RELEASE] HardShips OXP v0.89

Post by Krager »

phkb wrote: Sun Mar 22, 2026 2:10 am
Which requires a much bigger fix than I'm prepared to do on this OXP. Someone else will need to step in and do that work.
Благодарю! Две проблемы решены! Меню вызывается, и мусор в информации отсутствует)
Осталось найти с чем этот пакет конфликтует...
Spoiler
01:47:25.801 [script.javaScript.unrootedTimer]: ----- WARNING: Timer <OOJSTimer 0x2bf29950>{nextTime: 2.25, one-shot, running, function: anonymous} is being garbage-collected while still running. You must keep a reference to all running timers, or they will stop unpredictably!
01:47:25.801 [script.javaScript.unrootedTimer]: ----- WARNING: Timer <OOJSTimer 0x2acfafa0>{nextTime: 2.25, one-shot, running, function: anonymous} is being garbage-collected while still running. You must keep a reference to all running timers, or they will stop unpredictably!
01:47:25.801 [script.javaScript.unrootedTimer]: ----- WARNING: Timer <OOJSTimer 0x26a7fee0>{nextTime: 2.25, one-shot, running, function: anonymous} is being garbage-collected while still running. You must keep a reference to all running timers, or they will stop unpredictably!
01:47:25.801 [script.javaScript.unrootedTimer]: ----- WARNING: Timer <OOJSTimer 0x14937fb0>{nextTime: 2.25, one-shot, running, function: anonymous} is being garbage-collected while still running. You must keep a reference to all running timers, or they will stop unpredictably!
Это только кусочек, на самом деле таких строк очень много.
User avatar
phkb
Impressively Grand Sub-Admiral
Impressively Grand Sub-Admiral
Posts: 5687
Joined: Tue Jan 21, 2014 10:37 pm
Location: Writing more OXPs, because the world needs more OXPs.

Re: [RELEASE] HardShips OXP v0.89

Post by phkb »

Krager wrote: Sun Mar 22, 2026 10:55 pm
Это только кусочек, на самом деле таких строк очень много.
Tracking down anonymous timers is tricky. No shortcuts on that one I'm afraid. It's a case of:
1. Finding a set of actions that will reliably cause the timers to be recycled (that is, launch, jump to new system, dock, etc)
2. Remove OXP's and replaying steps until you don't see the messages.
Post Reply