Fractal Softworks Forum

Please login or register.

Login with username, password and session length
Advanced search  

News:

Starsector 0.9.1a is out! (05/10/19); Blog post: Raiding for Fun and Profit (11/27/19)

Pages: 1 ... 384 385 [386]

Author Topic: Misc modding questions that are too minor to warrant their own thread  (Read 823418 times)

Morrokain

  • Admiral
  • *****
  • Posts: 864
  • Megalith Dreadnought - Archean Order
    • View Profile
Re: Misc modding questions that are too minor to warrant their own thread
« Reply #5775 on: November 29, 2019, 04:22:37 PM »

Since ammo recharging is kind of a gimmick with a lot of Shadowyards weapons I've been planning on introducing a hullmod that boosts this recharge rate; unfortunately as I started trying to implement it it became clear that straightforward mechanisms for this don't seems to be present, at least not through MutableShipStats. It's already been requested through the API request thread but doesn't seem to have been implemented yet; as such I figured I may as well ask if anyone has any suggestions for an alternate implementation.

I messed with this idea a while back. Long and short of it is I don't think that value is exposed anywhere. I am nowhere even close to the best coder on this forum though. Just figured I'd say I tried and met no success.
Logged

passwalker

  • Commander
  • ***
  • Posts: 108
    • View Profile
Re: Misc modding questions that are too minor to warrant their own thread
« Reply #5776 on: November 29, 2019, 10:32:11 PM »

does anyone know where i can get old starfarer releases - 0.34, 0.35 and the first alpha
blogpost download links are dead, they give me a 404 error
http://fractalsoftworks.com/tag/release/page/5/
i kinda want to look at old sprites and whatnot
to see where it all began.
Logged
Any and ALL sprites i ever posted on this forum are FREE to use. even if i'm using them myself. Don't ever, EVER ask for permission, or i will come to your home and EAT YOUR DOG!!!
i do NOT want to see my name appear in the credits section of any published mod and will consider it a personal insult.

Sundog

  • Global Moderator
  • Admiral
  • *****
  • Posts: 938
    • View Profile
    • Email
Re: Misc modding questions that are too minor to warrant their own thread
« Reply #5777 on: November 30, 2019, 06:57:07 AM »

No idea where you could get versions that old. Oldest one I have is 0.6.2

Since ammo recharging is kind of a gimmick with a lot of Shadowyards weapons I've been planning on introducing a hullmod that boosts this recharge rate; unfortunately as I started trying to implement it it became clear that straightforward mechanisms for this don't seems to be present, at least not through MutableShipStats. It's already been requested through the API request thread but doesn't seem to have been implemented yet; as such I figured I may as well ask if anyone has any suggestions for an alternate implementation.
Well, you could always modify ammo manually with myWeapon.setAmmo(), but that might get complicated/bug-prone depending on what you want to do.

creature

  • Commander
  • ***
  • Posts: 106
    • View Profile
Re: Misc modding questions that are too minor to warrant their own thread
« Reply #5778 on: December 02, 2019, 07:58:47 PM »

How can I add custom combat messages on the textbox that appears at the top left of the screen during combat? I'd like to show event updates during a mission.
Logged

Sundog

  • Global Moderator
  • Admiral
  • *****
  • Posts: 938
    • View Profile
    • Email
Re: Misc modding questions that are too minor to warrant their own thread
« Reply #5779 on: December 02, 2019, 08:43:01 PM »

You can do that with the CombatUIAPI, which can be accessed through the combat engine. e.g. Global.getCombatEngine().getCombatUI().addMessage()

creature

  • Commander
  • ***
  • Posts: 106
    • View Profile
Re: Misc modding questions that are too minor to warrant their own thread
« Reply #5780 on: December 02, 2019, 08:57:11 PM »

You can do that with the CombatUIAPI, which can be accessed through the combat engine. e.g. Global.getCombatEngine().getCombatUI().addMessage()
Thanks for the quick reply! It worked!
Logged

Thaago

  • Global Moderator
  • Admiral
  • *****
  • Posts: 4230
  • Quantum Mechanic
    • View Profile
    • Email
Re: Misc modding questions that are too minor to warrant their own thread
« Reply #5781 on: December 04, 2019, 12:17:25 PM »

Can module weapon slots, image, etc be changed dynamically?

I've tried skin files and they also fail, so I think the answer is "no", unless I want to make actual .variant files for each combination of modules (which is impractical as there are hundreds).
Logged

Alex

  • Administrator
  • Admiral
  • *****
  • Posts: 15492
    • View Profile
Re: Misc modding questions that are too minor to warrant their own thread
« Reply #5782 on: December 04, 2019, 12:57:38 PM »

Yeah, as I remember, module slots are limited to the specific hull type that's in the original variant.
Logged

Thaago

  • Global Moderator
  • Admiral
  • *****
  • Posts: 4230
  • Quantum Mechanic
    • View Profile
    • Email
Re: Misc modding questions that are too minor to warrant their own thread
« Reply #5783 on: December 04, 2019, 04:59:21 PM »

Ahh, darn! Thanks for confirming! :)
Logged

Morrokain

  • Admiral
  • *****
  • Posts: 864
  • Megalith Dreadnought - Archean Order
    • View Profile
Re: Misc modding questions that are too minor to warrant their own thread
« Reply #5784 on: December 05, 2019, 09:45:23 PM »

Can't remember, is the standard recovery chance 50% or lower than that?


Actually, just want to make sure this does what I think it does because it would be difficult to test:

Code

    public static final float RECOVER_CHANCE = 0.75f;


public void applyEffectsBeforeShipCreation(HullSize hullSize, MutableShipStatsAPI stats, String id) {

if (stats.getEntity() != null && stats.getEntity().getOwner() != 0) {
stats.getDynamic().getMod(Stats.INDIVIDUAL_SHIP_RECOVERY_MOD).modifyMult(id, RECOVER_CHANCE);
}
}


Should reduce the chance to recover by 25% right?
« Last Edit: December 06, 2019, 12:34:00 PM by Morrokain »
Logged

mipen

  • Ensign
  • *
  • Posts: 3
    • View Profile
Re: Misc modding questions that are too minor to warrant their own thread
« Reply #5785 on: December 06, 2019, 03:55:18 AM »

Is it possible to increase the number of blueprints that are dropped from ruins and salvaged structures?
Logged

Alex

  • Administrator
  • Admiral
  • *****
  • Posts: 15492
    • View Profile
Re: Misc modding questions that are too minor to warrant their own thread
« Reply #5786 on: December 06, 2019, 03:41:00 PM »

Should reduce the chance to recover by 25% right?

Correct!

Is it possible to increase the number of blueprints that are dropped from ruins and salvaged structures?

In theory, yes, but I think that'd involve providing your own copy of MarketCMD (and changing the relevant rules that call it), so it's a decent bit of work.
Logged
Pages: 1 ... 384 385 [386]