Page 6 of 14

Posted: Tue Oct 23, 2007 10:34 pm
by LittleBear
Bah! Even using mutiple sets causes the third page to be the same as the first, although launching and redocked generates two new adds. Not fatal to the OXP but it would mean are limited to a choice of two hits per visit. I suspect this is somthing to do with Oolite's random seed. Is there anyway in an OXP to force a re-roll?

Posted: Tue Oct 23, 2007 10:45 pm
by JensAyton
LittleBear wrote:
Bah! Even using mutiple sets causes the third page to be the same as the first, although launching and redocked generates two new adds. Not fatal to the OXP but it would mean are limited to a choice of two hits per visit. I suspect this is somthing to do with Oolite's random seed. Is there anyway in an OXP to force a re-roll?
Yeah… wait for 1.70 and use JavaScript. (Any new way of forcing a re-roll would require the waiting for 1.70 bit anyway.)

Posted: Tue Oct 23, 2007 10:48 pm
by Arexack_Heretic
dunno, maybe by forcing the board to fill up slowly:

each time you exitWitchspace,
check whether a slot is undefined, then fill it if not.
next jump, check slot+1.
this way there should be a different random_seed for each mark.

maybe set a semi-random timer as well that decrements with each jump, when at 0 reset the slot. (needs on average be >max_number of contracts)

edit ah Ahruman has a better solution apparently. :)
I think I'll wait on 1.7 for the scripted variable ship implementation too.
Too many properties and tricks that are really required are announced for 1.7. edit: 1.70.

Posted: Tue Oct 23, 2007 11:11 pm
by JensAyton
Arexack_Heretic wrote:
I think I'll wait on 1.7 for the scripted variable ship implementation too.
Too many properties and tricks that are really required are announced for 1.7.
Random nitpick: version numbers are not rational numbers. 1.70 is not 1.7 (although, as it happens, there was no 1.7; there was presumably an internal 1.07 between 1.06 and 1.20.

Posted: Tue Oct 23, 2007 11:31 pm
by Arexack_Heretic
They are generally progressive though.
If only to suggest progress. ;)

Posted: Wed Oct 24, 2007 12:02 am
by LittleBear
For reasons I don't understand reseting all my tempory variable that are used in mission text (and then stored if the hit is accepted) bought me one more variation. So you get 3 different hits offered, launch and redock and 3 different hits are generated. So you'll have the choice of 6 hits per visit to the system. Seems Ok and "realistic". As you are sitting in a seedy bar with lots of other bounty hunters and it takes a bit of time to prep your ship and launch, hits will have been taken by others and new hits posted! :wink:

Think 6 hits per visit gives enough choice. If nothing takes your fancy, go somewhere else and come back later. A H jump seems to force a re-roll.

Posted: Wed Oct 24, 2007 2:47 pm
by Arexack_Heretic
What do you think (for law-men) wanted adds should be the frequency based on government level?
for assasinations the frequency would be a around
(10 - government_number), but for law-abiding agencies thing are more complex.
anarchies don't give a damn about criminals, (well... the local gal-cop might)
while corporate states may feel that having mercenaries battle unsupervised reflects poorly on their PR.

Code: Select all

0: Anarchy
1: Feudal
2: Multi-Governmental
3: Dictatorship
4: Communist
5: Confederacy 
6: Democracy 
7: Corporate State  
should I do:

Code: Select all

this.determineMaxAdds = function ()
{
 var maxadds =  10;
 var governmentNumber = "system.government"; 
//@ahruman: or let? => let req 1.70
 if (government>=0)
 {
  maxadds -= governmentNumber;
  missionVariables.wantedNumber = Math.floor(Math.random()*maxadds);
 };
 else
 {
  missionVariables.wantedNumber = 0
 }
}
?
which gives a linear decrease towards the more law-abiding gov'ts. and no wanted posters at all at Anarchies.
or
would a 'curve' with maxadds = 10, maxadds-=2*Math.abs(4-government) make more sense? (more wanteds as security increases, but dropping off as law-enforcement becomes more effective.)

Posted: Wed Oct 24, 2007 4:35 pm
by LittleBear
Thing is, I was going to had script the appearance so the each Bar had its own name on the ID computer at least untill we run out of bar-names! So was gonna place them all in anarchies. (A natural place to build a bouty hunters bar after all!). The script to generate the hits is pretty complex as it is! I've nearly finished the scripting for displaying and acceting jobs. If the player has too lower an elite rating for a particular job, be can still offer his services, but gets told to sod off. Done a few arrays for this one, generates things like:-

Code: Select all

Thank you for your interest in this termination, although your record is not unimpressive, a superior killer is required for this hit. We fear that the mark would laugh at you. Get out into the space lanes and improve your Elite Rating!
Suggestions for some more strings?

Current ones:-

Code: Select all


	<key>assassination_board_job_name</key>
	<array>
	<string>assignment</string>
	<string>contract</string>
	<string>job</string>
	<string>hit</string>
	<string>mission</string>
	<string>termination</string>
	<string>retirement</string>
	<string>execution</string>
	<string>removal job</string>
	<string>extermination</string>
	<string>elimination</string>
	<string>whacking</string>
	</array>

	<key>assassination_board_refused2</key>
	<array>
	<string>for your interest in this [assassination_board_job_name]</string>
	<string>for contacting us</string>
	<string>for making contact</string>
	<string>for your enquiry</string>
	<string>for taking the time to respond</string>
	<string>for reading our advertisement</string>
	<string>for responding</string>
	<string>for your communication</string>
	<string>for getting back to us</string>
	<string>for your kind reply</string>
	<string>for taking an interest</string>
	<string>for your application</string>
	</array>

	<key>assassination_board_refused3</key>
	<array>
	<string>but we are looking for someone with a higher Elite rating</string>
	<string>however we require someone more experienced</string>
	<string>but we need a more proved killer</string>
	<string>but we require a more experienced operative</string>
	<string>however we are seeking Commander of greater skill</string>
	<string>although your record is not unimpressive, a superior killer is required for this [assassination_board_job_name]</string>
	<string>but we feel that you lack the necessary experience</string>
	<string>but a proved killer is required for this [assassination_board_job_name]</string>
	<string>but we require a more murderous individual than you have thus far shown yourself to be</string>
	<string>however we are seeking a more prolific killer than yourself</string>
	<string>a better qualified applicant than yourself</string>
	<string>but we are seeking someone with more kills to their name</string>
	</array>


	<key>assassination_board_refused4</key>
	<array>
	<string>We fear that</string>
	<string>We are concerned that</string>
	<string>We have little doubt that</string>
	<string>We are worried that</string>
	<string>We foresee that</string>
	<string>We consider it likely that</string>
	</array>

	<key>assassination_board_refused5</key>
	<array>
	<string>the mark</string>
	<string>the victim</string>
	<string>the target</string>
	<string>the subject of the contract</string>
	</array>

	<key>assassination_board_refused6</key>
	<array>
	<string>would laugh at you</string>
	<string>would escape your clutches</string>
	<string>would blast you to kingdom come</string>
	<string>would evade your clumsy attempts</string>
	<string>would turn you into space dust</string>
	<string>would blast you out of space</string>
	</array>


	<key>assassination_board_refused7</key>
	<array>
	<string>Why don't you try an easier [assassination_board_job_name]?</string>
	<string>Get some practice before bothering us again!</string>
	<string>We suggest you stick to easy trade-runs for the time being.</string>
	<string>Lean to shoot before contacting us again!</string>
	<string>Get yourself a better ship before considering this type of employment!</string>
	<string>Get out into the space lanes and improve your Elite Rating!</string>
	</array>

[/code]

Posted: Fri Oct 26, 2007 9:27 am
by JensAyton
Arexack_Heretic wrote:
var governmentNumber = (system.call(government); //@ahruman: or let?
let is recommended from 1.70, but not supported in 1.69.
You didn’t close the first parenthesis.
government should be a string.
Oh, and there’s a system.government property, so you don’t need call(). Which is good, since there is no System.call() – it’s Player.call() in 1.69, and Entity.call() in 1.70. (Side note: there’s a Function.call() in core JavaScript, but that’s not relevant here.)

To clarify: call() is primarily intended for calling legacy script methods when there is no JS equivalent. To get the government number in a legacy script, you use the player scripting method systemGovernment_number, so to use it from JavaScript you’d write player.call("systemGovernment_number"). But system.government is more efficient and hopefully clearer. :-)

Posted: Fri Oct 26, 2007 11:42 am
by Arexack_Heretic
thanks Ahuman, changed those things you mentioned.


I was angling for some political-policing community input here also.

wanteds and bountyhunters are generally tolerated only when lawenforcement can't cope.
but would this result in a linear decrease towards the lawfull systems or one that increases , then drops.

Posted: Fri Oct 26, 2007 3:45 pm
by Disembodied
Captain Hesperus wrote:
Disembodied wrote:
Some more bar names:

Code: Select all

<string>The Horny Lobster</string>
This is just wrong on so many levels.....
What about

Code: Select all

<string>That Lovin' Feline</string>
(it's taken me three days to come up with that... :oops: )

Posted: Fri Oct 26, 2007 8:55 pm
by Captain Hesperus
Disembodied wrote:
(it's taken me three days to come up with that... :oops: )
Sometimes the best innuendos are the unwitting ones.....:lol:

Captain Hesperus
The Lovin' Feline <rawrrrrr!>

Posted: Fri Oct 26, 2007 8:59 pm
by LittleBear
Getting there. Random mission pages done, but still need more arrays, and have only coded systems where are mark may be found for G1 and 2 so far (as can be seen from this screeny). But this mission screen was gererated by random arrays, rather than a hand coded one:-


Image

Posted: Fri Oct 26, 2007 9:04 pm
by LittleBear
Getting there. Random mission pages done, but still need more arrays, and have only coded systems where are mark may be found for G1 and 2 so far (as can be seen from this screeny). But all these mission screens were gererated by random arrays, rather than hand coded ones:-


Image

Generated by a missiontext of:-

Code: Select all

<string>mission_random_hits_seedy_spacebar_name\n--------------------------------------------------------------------------------------------------------------------------\nPOSTED BY  : mission_random_hits_assassination_board_poster_title %R mission_random_hits_assassination_board_poster_name from the mission_random_hits_assassination_board_poster_system System.\nSUBJECT      : mission_random_hits_assassination_board_subject\n\nmission_random_hits_assassination_board_part1 mission_random_hits_mark_first_name mission_random_hits_mark_nick_name mission_random_hits_mark_second_name mission_random_hits_mark_race_part1 mission_random_hits_mark_race_part2 mission_random_hits_assassination_board_part2 mission_random_hits_assassination_board_part3 mission_random_hits_mark_ship_description mission_random_hits_mark_ship mission_random_hits_assassination_board_part4 mission_random_hits_mark_system System. mission_random_hits_assassination_board_part5 mission_random_hits_mark_fee Credits mission_random_hits_assassination_board_part6 mission_random_hits_mark_gender mission_random_hits_assassination_board_part7\n\nREPLIES TO   : mission_random_hits_assassination_board_address1 %R @ mission_random_hits_assassination_board_address2\n--------------------------------------------------------------------------------------------------------------------------\nCurrently viewing [assassination_board_job_name] mission_random_hits_page of 3. [assassination_board_easykill]</string>
Player offers services but too inexeprienced:-

Image

Generated by code:-

Code: Select all

<key>random_hits_refused</key>
<string>mission_random_hits_seedy_spacebar_name\n--------------------------------------------------------------------------------------------------------------------------\nREPLY FROM : mission_random_hits_assassination_board_poster_title mission_random_hits_assassination_board_poster_name from the mission_random_hits_assassination_board_poster_system System.\nSUBJECT        : [assassination_board_refused1] mission_random_hits_mark_first_name mission_random_hits_mark_nick_name mission_random_hits_mark_second_name \nADDRESS       : mission_random_hits_assassination_board_address1 %R @ mission_random_hits_assassination_board_address2\n\nThank you [assassination_board_refused2] Commander [commander_name], [assassination_board_refused3]. [assassination_board_refused4] [assassination_board_refused5] [assassination_board_refused6]. [assassination_board_refused7] [assassination_board_insult]!\n\n--------------------------------------------------------------------------------------------------------------------------\nThis [assassination_board_job_name] is unavailable to you at this time.</string>


Player offers services and has suitable elite ranking:-

Image

generated by code

Code: Select all

<key>random_hits_jobaccepted</key>
<string>mission_random_hits_seedy_spacebar_name\n--------------------------------------------------------------------------------------------------------------------------\nREPLY FROM : mission_random_hits_assassination_board_poster_title mission_random_hits_assassination_board_poster_name from the mission_random_hits_assassination_board_poster_system System.\nSUBJECT        : [assassination_board_refused1] mission_random_hits_mark_first_name mission_random_hits_mark_nick_name mission_random_hits_mark_second_name \nADDRESS       : mission_random_hits_assassination_board_address1 %R @ mission_random_hits_assassination_board_address2\n\nThank you [assassination_board_refused2] Commander [commander_name], you [assassination_board_accepted1] [assassination_board_accepted2] [assassination_board_accepted3] [assassination_board_accepted4] [assassination_board_accepted5] this [assassination_board_job_name]. [assassination_board_accepted6] [assassination_board_refused5] [assassination_board_accepted7]! [assassination_board_part5] mission_random_hits_mark_fee Credits [assassination_board_accepted7a] upon docking with any GalCop Station or any Bounty Hunters' Bar following the [assassination_board_accepted8] of [assassination_board_refused5b]. This [assassination_board_accepted9] will be in addition to any bounty paid by GalCop. [assassination_board_accepted10]!\n\n--------------------------------------------------------------------------------------------------------------------------\nYou have accepted this [assassination_board_job_name]. You may not take another [assassination_board_job_nameb] until the current [assassination_board_job_namec] is completed or abandoned. If you leave the current Galactic Chart you will be deemed to have abandoned the [assassination_board_job_name].</string>


Posted: Sat Oct 27, 2007 6:52 am
by TGHC
If you leave the current Galaxy sounds better.

Keep up the good work LB.


TGHC