Need a bit of Mod Help (Simple Choices / Resources on Start)

Discuss and distribute tools and methods for modding. Moderator - Grognak
Commander Bob
Posts: 11
Joined: Mon Sep 24, 2012 11:24 pm

Need a bit of Mod Help (Simple Choices / Resources on Start)

Postby Commander Bob » Wed Sep 26, 2012 10:04 pm

Hi guys, why the heck don't we have a Modding section on here? (Mod Releases, Mod Discussion, Mod Help subsections).

Anyways, I've been looking through the Help stuff in the wiki and so on, and I'm trying to modify Grognak's Sample Scrap mod to give me a bit of fuel, and some fleet slowdown.

Basically I'm trying to get a choice of:
  1. "Continue" (no benefits, for vanilla play)
  2. Fleet Slowdown Only (Available at all start beacons, costs 2-3 fuel)
  3. Booster pack of "Scrap / Fuel / Fleet Slowdown" that will only be available at the start of the game.
Now I've seen the XML for the Fleet slowdown so that's fine. Questions I have are:

  • How do I make the first option cost 2-3 fuel? (don't mind whether its static one of those values, or between those two). - Resolved.

  • Can I add BOTH of JUST Fuel AND Scrap? Or do I have to use one of the mixed rewards, like "Standard". If both, can I just put them sequentially like in the example below? Also can I specify an exact amount, or do I just haveto use the low / med / high? - Resolved.

  • How can I make the fuel/scrap/pursuit option be visible (or just selectable) on the Start Game only? I understand the start screen inherits the Start Beacon events. So thought of making a hidden requirement of one of the augmentations that I'd probably rarely use. As in give it myself at the start of the game, and remove it when selecting any of those options, so I can't use the last option from anywhere but the game start (or if I bought that Augment myself). However would this error if I try to remove it but don't have it? (thinking of it still running the removal statement on the later beacons). If this WOULD work, how do I find the ID, and what's the actual way of adding / removing an augment?

Here's sorta what I'm thinking of. I've just modified Grognak's sample mod (thanks for the awesome mod loader btw!):

Code: Select all

<!-- Scrap, Fuel and Fleet Pursuit Advantage mod -->

<event name="START_GAME">
   <text>The data you carry is vital to the remaining Federation fleet. You'll need supplies for the journey, so make sure to explore each sector before moving on to the next. But get to the exit before the pursuing Rebel fleet can catch up!</text>
</event>

<event name="START_BEACON">
   <text>Welcome to a new sector! Get to the exit beacon and jump to the next sector before the pursuing Rebels catch you!</text>
   <choice hidden="true">
      <text>Continue...</text>
      <event/>
   </choice>
   <choice hidden="false">
      <text>Engage the FTL drive at full power to boost you ahead of the Rebel Fleet?</text>
      <event>
         <text>You engage the FTL drive at full power, boosting you far ahead of the Rebel Fleet.</text>
         <item_modify>
                                                        <item type="fuel" min="2" max="4"/>
                                                </item_modify>
         <modifyPursuit amount="-20" />
      </event>
   </choice>
   <choice req="ENGINES" hidden="true">
      <text>Strip a near-by asteroid for scrap and fuel, then engage the FTL drive at full power?</text>
      <event>
         <text>You take a shuttle and grab as much metal and fuel as you can, and engage the FTL drive at full power, boosting you far ahead of the Rebel Fleet.</text>
         <autoReward level="MED">scrap_only</autoReward>
         <autoReward level="HIGH">fuel_only</autoReward>
         <modifyPursuit amount="-20"/>
      </event>
   </choice>
</event>
Last edited by Commander Bob on Wed Sep 26, 2012 11:39 pm, edited 3 times in total.
Icehawk78
Posts: 230
Joined: Tue Sep 18, 2012 4:55 pm

Re: Need a bit of Mod Help (Simple Choices / Resources on St

Postby Icehawk78 » Wed Sep 26, 2012 10:12 pm

Unfortunately, it's not possible to remove augments via modding (the secret ship event is apparently hardcoded in to remove the augment, there's nothing in the xml to do so). Your best bet for "beginning of game only" would likely be to create a new "beginning of sector" event which you then change all the non-starting sectors to reference.

For costing fuel, look at the non-shop merchant events. The tag is something to the effect of <modifyItem type="fuel" min="-2" max="-3" /> I think, but I don't remember for certain. The merchant ones have similar examples for doing more than one thing at a time, you'd just list two items in a row.
Commander Bob
Posts: 11
Joined: Mon Sep 24, 2012 11:24 pm

Re: Need a bit of Mod Help (Simple Choices / Resources on St

Postby Commander Bob » Wed Sep 26, 2012 10:29 pm

Ah thankyou!

So I'm guessing I create an event that both the starting & other sectors reference (the continue / Fleet pursuit one).

And another even that ONLY the starting sector references? (along with the other one too).

Do you have a quick example of this to hand? Creating events for specific sectors. I'm trying to make this work with Grognak's Modloader so I'm a bit new with it hehe. :)

Have updated my post, should have everything in there bar the "Only on Sector 1" thing now.
Icehawk78
Posts: 230
Joined: Tue Sep 18, 2012 4:55 pm

Re: Need a bit of Mod Help (Simple Choices / Resources on St

Postby Icehawk78 » Fri Sep 28, 2012 5:57 pm

Commander Bob wrote:Ah thankyou!

So I'm guessing I create an event that both the starting & other sectors reference (the continue / Fleet pursuit one).

And another even that ONLY the starting sector references? (along with the other one too).

Do you have a quick example of this to hand? Creating events for specific sectors. I'm trying to make this work with Grognak's Modloader so I'm a bit new with it hehe. :)

Have updated my post, should have everything in there bar the "Only on Sector 1" thing now.

I think you could likely get what you want by instead just altering the "enter sector" event for all of the sectors which reference the same event as the start of game event, and making them reference a not-providing-the-option event.
Commander Bob
Posts: 11
Joined: Mon Sep 24, 2012 11:24 pm

Re: Need a bit of Mod Help (Simple Choices / Resources on St

Postby Commander Bob » Sat Sep 29, 2012 6:42 pm

Um, got a small example of that? ;x
totalvamp
Posts: 2
Joined: Sun Sep 30, 2012 1:16 am

Re: Need a bit of Mod Help (Simple Choices / Resources on St

Postby totalvamp » Sun Sep 30, 2012 1:25 am

I'm trying something similar, what I need is nested questions for like an options menu. The problem is; how will I be able to remember what a player chose for fleet disabled? It needs to be saved somewhere.

Also how can you link that many question together? I think we are kind of looking for the same answers.

Question 1: want some extra scrap?
Yes
Skip
Question 2: Want fleet disabled?
Yes
Skip
Question 3: Want extra fuel?
Yes
Skip
Question 4: Want extra missiles?
Yes
Skip
Question 5: Want extra drone parts?
Yes
Skip
Justin
Site Admin
Posts: 265
Joined: Thu Apr 19, 2012 9:52 am

Re: Need a bit of Mod Help (Simple Choices / Resources on St

Postby Justin » Sun Sep 30, 2012 1:28 am

Someone else had a good idea for disabling the fleet:

Make a useless "fleet disabling augment".
In each of the starting events have a <choice hidden="true" req="FLEET_STOPPER">
And in that choice have your pursuit delay.

It means you'd have to click it each time but it would work.
If you're having hull problems, I feel bad for you son. I've got 99 problems but a breach ain't one.
totalvamp
Posts: 2
Joined: Sun Sep 30, 2012 1:16 am

Re: Need a bit of Mod Help (Simple Choices / Resources on St

Postby totalvamp » Sun Sep 30, 2012 1:33 am

Justin wrote:Someone else had a good idea for disabling the fleet:

Make a useless "fleet disabling augment".
In each of the starting events have a <choice hidden="true" req="FLEET_STOPPER">
And in that choice have your pursuit delay.

It means you'd have to click it each time but it would work.


But if you have to click it each time it would still be easier to just adjust the STAR_BEACON event and add it(event with fleet disable option) there?
Would probable be the same outcome
Justin
Site Admin
Posts: 265
Joined: Thu Apr 19, 2012 9:52 am

Re: Need a bit of Mod Help (Simple Choices / Resources on St

Postby Justin » Sun Sep 30, 2012 1:50 am

totalvamp wrote:But if you have to click it each time it would still be easier to just adjust the STAR_BEACON event and add it(event with fleet disable option) there?
Would probable be the same outcome


If i understand what you mean, the problem is that you need the fleet delay to occur in each sector. Having it occur in the first sector will then only affect the fleet in sector 1. That's why you'd need the weird augment workaround to make it happen in the start of each sector.
If you're having hull problems, I feel bad for you son. I've got 99 problems but a breach ain't one.
Commander Bob
Posts: 11
Joined: Mon Sep 24, 2012 11:24 pm

Re: Need a bit of Mod Help (Simple Choices / Resources on St

Postby Commander Bob » Sun Sep 30, 2012 4:47 pm

If that's how it works (Fleet delay resetting at the start of each sector) then yeah Justin I'd have the simple "Delay the fleet" option available in all sectors, but have it be my choice whether to use it, or just continue as normal if I'm feeling beefy. (I like exploring. OCD ;x).

Now for when I'm feeling beefy, I think I'll try and incorporate slowerthanlight's Hold the Line, or Kiev's Turning the Tide mod where if you destroy a fleet ship, it knocks it back. So sometimes I wouldn't bother delaying the fleet at the start of the sector, and just fight them instead when they get close. Risk vs reward.

It is ONLY on at the very start of the game that I'd want the full "Slow Fleet, AND fuel / scrap" option to be available though, just to give me a bit of an initial boost if I felt like it. Apparently the best way of doing that is modifying each sector's event? Problem is I thought they all (even the first) shared the same Start_Beacon one.

Thanks for all the answers though, didn't expect much interest / help in a small personal tweak. I'll still post the .ftl file here though when its working for others to use if they wish. :)