Page 7 of 70

Posted: Mon Mar 03, 2008 10:03 am
by Hoopy
space hermits often have ships launching from them so it's rare to get past one without getting locked by the ship.

Posted: Tue Mar 25, 2008 9:47 am
by LittleBear
Just to let players know: Random hits works on 1.70, but will not work on the test 1.71 version. This is due to two Java Commands being renamed. It would be a quick search and replace to change them to the new names, but if I did this then it woudn't work on 1.70! When 1.71 becomes officall I'll put up a 1.2 version of Random Hits with the new names. In the meantime, you must use 1.70 of Oolite to play Random Hits.

Random Hits uses the "thisBeingAttacked" command to test who (player or NPC) was the last ship to attack the victim before his death (ie who fired the fatal shot). On 1.71 this command is changed to "thisShipAttacked". As a result if you play on 1.71 although the victim will be there, the OXP will not recognise that you killed him.

Posted: Tue Mar 25, 2008 10:11 am
by Kaks
Have you tried replacing:

Code: Select all

this.beingAttacked = function(whom)
with

Code: Select all

this.shipAttacked = this.beingAttacked = function(whom)
This should make that part of the code compatible with both 1.70 & 1.71! ;)

Posted: Tue Mar 25, 2008 6:57 pm
by JensAyton
In point of fact, this.beingAttacked will work in 1.71 (but will generate a log warning). The new name is this.shipBeingAttacked.

Posted: Fri Apr 25, 2008 3:52 pm
by Commander Mysenses
@LittleBear
Any news on v.1.2 yet?
Bit of a drag to drop back to v.1.70, to complete the hit!

Posted: Fri Apr 25, 2008 3:55 pm
by LittleBear
RL has been pretty bad, so no time ATM. Probabley get it out week after next though.

Posted: Sat Apr 26, 2008 8:49 pm
by BTBC
I am having a problem the mark jumped systems and I followed and destroyed the target ship I then get told that he has escaped in a pod and to destroy the pod but I cant find any pods

Here is the error message from the shell window..

**** WARNING in AI randomhitsmark2aAI.plist in state JUMP_OUT: the AI method scr iptActionOnTarget: is deprecated and should not be used. It is slow and has unpr edictable side effects. The recommended alternative is to use sendScriptMessage: to call a function in a ship's JavaScript ship script instead. scriptActionOnTa rget: should not be used at all from scripts. An alternative is safeScriptAction OnTarget:, which is similar to scriptActionOnTarget: but has less side effects.
2008-04-26 20:40:57.474 oolite[6477] [script.javaScript.warning.206]: ----- Java Script warning: system.legacy_spawn() is deprecated (and never worked), use Ship .spawn() instead.

Escape pods

Posted: Sun Apr 27, 2008 6:39 am
by WillASM
BTBC wrote:
I am having a problem the mark jumped systems and I followed and destroyed the target ship I then get told that he has escaped in a pod and to destroy the pod but I cant find any pods

Here is the error message from the shell window..

**** WARNING in AI randomhitsmark2aAI.plist in state JUMP_OUT: the AI method scr iptActionOnTarget: is deprecated and should not be used. It is slow and has unpr edictable side effects. The recommended alternative is to use sendScriptMessage: to call a function in a ship's JavaScript ship script instead. scriptActionOnTa rget: should not be used at all from scripts. An alternative is safeScriptAction OnTarget:, which is similar to scriptActionOnTarget: but has less side effects.
2008-04-26 20:40:57.474 oolite[6477] [script.javaScript.warning.206]: ----- Java Script warning: system.legacy_spawn() is deprecated (and never worked), use Ship .spawn() instead.
Same problem here, I can complete the missions so long as the target
does not bail out in an escape pod. If he does bail, thats an automatic
failure for that mission..

Re: Escape pods

Posted: Sun Apr 27, 2008 7:42 am
by Commander Mysenses
WillASM wrote:
Same problem here, I can complete the missions so long as the target does not bail out in an escape pod. If he does bail, thats an automatic failure for that mission..
What version of Oolite are you running?

Posted: Sun Apr 27, 2008 10:22 am
by LittleBear
Yeah. This is because the name of the command which lauches the pod (and a couple of others too) have been changed between 1.70 and 1.71. I need to do a new version of Random Hits to make it work properly with V1.71 of Oolite. Basically, it just needs me to go through my Java Scripts and AIs :- (Open up, Serach and replace - test!) to change the names. The OXP has a lot of varitey to it though, so it means me getting round to doing this with over 100 AIs and Scripts! It will be done when I have some time (probabley next week) and I'll then upload a 1.2 of Random Hits (for Oolite 1.71 onwards). For the moment the V1.1 of Random Hits runs bug-free with Oolite 1.70, but won't work properly with 1.71.

EDIT:-

Done So Far:-

1) Changed the AIs which use scriptActionOnTarget to safeScriptActionOnTarget.

2) Commented out the Description of all Java Script files (this solves the problem of the second pod spawned in the same game session not following its script).

Posted: Sun Apr 27, 2008 1:49 pm
by LittleBear
Changed all the problem commands on the version on my machine:-

system.legacy_spawn ==>> this.ship.spawn

this.beingAttacked ==>> this.shipBeingAttacked

scriptActionOnTarget ==>> safeScriptActionOnTarget


This should work to make the next version of Random Hits work on V1.71 onwards of Oolite. Need to do some playtesting before uploading though.

Posted: Tue Apr 29, 2008 12:01 pm
by LittleBear
UPDATE TO VERSION 1.2.

Version 1.2 of Random Hits is now on the Wiki (follow the link on my signature to download).

Please Note version 1.2 of Random Hits now requires version 1.71 (or higher) of Oolite. It will not run properly on a lower version (including 1.70). This new version takes account of several command name charges between Version 1.70 and Version 1.71 of Oolite. It will now run properly on Version V1.71 and higher. Changes :-

- All instances of “system.legacy_spawn” changed to “this.ship.spawn”.
- All instances of “this.beingAttacked” changed to “this.shipBeingAttacked”.
- All instances of “scriptActionOnTarget” changed to “safeScriptActionOnTarget”.
- Descriptions commented out from Java Scripts.
- Space Bars now have Station Scan Class (i.e. they show as green on the scanner).
- Couple of tweaks to the AIs.
- A few more typos, grammar errors and spelling mistakes fixed.

I've tested it on both 1.71 and 1.71.1 and seems to be working as intended. You MUST use this version if playing on 1.71 onwards as the old (1.1 Version) of Random Hits will not work on Version 1.71 of Oolite. Please note that the new V1.2 Version of Random Hits REQUIRES Version 1.71 of Oolite or higher.

I've also edited the first post on this thread to reflect the Update.

If you do hit a problem with the game not recognising a kill or a pod not appearing, could you post the TYPE of ship (Python, Cobra III etc) where this happened?

Posted: Tue Apr 29, 2008 6:34 pm
by elite
Yeahhh I can play it again as I now have 1.71.1

Thanks.

Posted: Tue Apr 29, 2008 10:49 pm
by WillASM
Works like a charm after 3 missions, the pods are showing up now after they bail. Thank you Very much for the quick update LittleBear.
By the way, very addictive oxp, having a great time chasing these guys down, thanks again.. As a side note, Finally reached *Deadly*
status today on the last mission, only about 3800 more to go :lol:

Posted: Sat May 10, 2008 11:18 am
by davcefai
I have a problem with v1.2:

There is no visible docking bay on the space bars.

From one side I can see a large arched "door" but "My God! It's full of stars!"

If I fly through it nothing happens but then in my rear screen I see a solid wall.

There are no relevant error messages on the debug screen.

Suggestion and workarounds are welcome.