Help needed with Event coding

Discuss and distribute tools and methods for modding. Moderator - Grognak
Post Reply
Darksiderq
Posts: 13
Joined: Sat Sep 29, 2012 11:51 pm

Help needed with Event coding

Post by Darksiderq »

Hi guys i really like FTL and just wanted to code an "own" event for the
[SUBMIT EVENTS] Community-provided event mod

But i have a problem once i pack the event(it a hand written copy of the MERCENARY event) in the data.dat file the game crashes after loading. Can somebody help me with that?

The event

Code: Select all

<event name="BRIBE_REBEL" unique="false">
	<ship load="REBEL_LONG" hostile="false"/>
	<text>As you finish your jump a Rebel Scout hails you "I see you are the one running from the Fleet...Maybe we can work something out so you can get some more Time..."</text>
	<choice>
		<text>Accept his Offer(-30 Scrap)</text>
		<event>
			<text>You gladly accept his offer and you hope he keeps his Word.</text>
				<item_modify>
					<item type="scrap" min="-30" max="-10"/>
				</item_modify>
				<modifyPursuit amount="-3"/>
		</event>
	</choice>
	<choice>
		<text>Refuse his Offer.</text>
		<event>
			<text>You contact the Rebell telling him you have no need of his services.</text>
		</event>
		</choice>
	<choice>
		<text>Attack the Rebell!</text>
		<event>
			<text>You will never make a Deal with a Rebell.You are Powering the Weapons</text>
			<ship hostile="true/>
		</event>
	</choice>
</event>
The event is loaded form events_rebel.xml file under NEUTRAL_REBEL eventlist as the following

Code: Select all

<eventList name="NEUTRAL_REBEL">
	<event load="AUTO_CIVILIAN"/>
	<event load="SQUAT_REFUEL_STATION"/>
	<event load="AUTO_DEFENSE_MAP"/>
	<event load="AUTO_DEFENSE_ITEM"/>
	<event load="AUTO_DEFENSE_RADAR"/>
	<event load="REBEL_TRANSPORT"/>
	<event load="BROKEN_REBEL_DRONE"/>
	<event load="ALISON_DEFECTOR"/>
	!!!<event load="BRIBE_REBEL"/>!!!ADDED PART
</eventList>
zaratustra
Posts: 12
Joined: Fri Sep 21, 2012 5:36 pm

Re: Help needed with Event coding

Post by zaratustra »

Code: Select all

 <ship hostile="true/>
missing a quote there.
Darksiderq
Posts: 13
Joined: Sat Sep 29, 2012 11:51 pm

Re: Help needed with Event coding

Post by Darksiderq »

Thank you very mutch totally didnt see this^^ Stupid mistake game start fine now not lets see if it works.

EDIT:Eveything works fine^^

EDIT2:Also my Quest works fine.
Post Reply