rem: this.log("Offering trumble.") 
add: let message = "Commander " + player.name + ",\n\n" + "You look like someone who could use a Trumble on your " + player.shipDescription + "!\n\n" + "This is yours for only 30 credits." 
context: this.didDock = function(){	/*	In the pre-JavaScript implementation, the mission variable was set to		OFFER_MADE while the mission screen was shown. If the player lanched		in that state, the offer would never be made again -- unless some		other script used the mission choice keys "YES" or "NO". This		implementation uses unique choice keys and doesn't change the mission		variable, which should be more reliable in all cases.	*/	if (missionVariables.trumbles == "OFFER_MADE")  missionVariables.trumbles = "BUY_ME"		if (player.dockedStation.isMainStation &&		missionVariables.trumbles == "" &&		!missionVariables.novacount &&		// Hmm. Why is this here? (Ported from legacy script)		player.credits > 6553.5)	{		this.log("Time to start selling trumbles.")		missionVariables.trumbles = "BUY_ME"	}		if (missionVariables.trumbles == "BUY_ME")	{		this.log("Trumbles are on the market.")		// 20% chance of trumble being offered, if no other script got this dock session first.		if (guiScreen == "GUI_SCREEN_STATUS"			&& Math.random() < 0.2)		{			this.log("Offering trumble.")						let message =			"Commander " + player.name + ",\n\n" +			"You look like someone who could use a Trumble on your " + player.shipDescription + "!\n\n" +			"This is yours for only 30 credits."						// Show a mission screen.			mission.clearMissionScreen()			mission.setBackgroundImage("trumblebox.png")			mission.showMissionScreen()			mission.addMessageText(message)			mission.setChoicesKey("oolite_trumble_offer_yesno")		}		else		{			this.log("Not offering trumble. GUI screen is " + guiScreen)		}	}	else	{		this.log("Not offering trumble. mission_trumbles is " + missionVariables.trumbles)	}}
meta: 622	/local1/tlutelli/issta_data/temp/all_js/javascript/2007_temp/2007/622/9c2f6c8ea45ca6898f11855e1c5790b7b8023e26/oolite-trumbles.js/clean/Resources/Scripts/oolite-trumbles.js