Fractal Softworks Forum

Please login or register.

Login with username, password and session length
Pages: 1 ... 544 545 [546] 547 548 ... 710

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

SafariJohn

  • Admiral
  • *****
  • Posts: 3023
    • View Profile
Re: Misc modding questions that are too minor to warrant their own thread
« Reply #8175 on: November 27, 2021, 01:29:14 PM »

If I make a weapon with a long charge up time, very fast projectile speed and slow turn rate. Would enemy ships try to get out of the way during the charge time?

Go play with the Mimir from Shadowyards. I think its main gun has a long chargeup and fast projectile like the weapon you want to do.
Logged

Timid

  • Admiral
  • *****
  • Posts: 640
  • Personal Text
    • View Profile
Re: Misc modding questions that are too minor to warrant their own thread
« Reply #8176 on: November 27, 2021, 04:47:05 PM »

I am using
Code
dialog.showCargoPickerDialog
public void recreateTextPanel(TooltipMakerAPI panel, CargoAPI cargo, CargoStackAPI pickedUp, boolean pickedUpFromSource, CargoAPI combined)

I found that adding buttons here in panel.AddButton makes the button graphically, but I can't do anything with it otherwise. I can't even check if it's enabled, or checked, set a shortcut, or even have buttonpressedsound.

Is it not supported in recreateTextPanel?

Alex

  • Administrator
  • Admiral
  • *****
  • Posts: 24128
    • View Profile
Re: Misc modding questions that are too minor to warrant their own thread
« Reply #8177 on: November 27, 2021, 05:07:43 PM »

I *think* if you call:
panel.setForceProcessInput(true)
That should do it.
Logged

Timid

  • Admiral
  • *****
  • Posts: 640
  • Personal Text
    • View Profile
Re: Misc modding questions that are too minor to warrant their own thread
« Reply #8178 on: November 27, 2021, 05:29:52 PM »

I *think* if you call:
panel.setForceProcessInput(true)
That should do it.
Oh, that worked, too bad there's no button.setButtonPressed to incur a script or something  :-[

Using addAreaCheckbox I thought would at least let me check if it got checked or not.

Thanks for helping!

Timid

  • Admiral
  • *****
  • Posts: 640
  • Personal Text
    • View Profile
Re: Misc modding questions that are too minor to warrant their own thread
« Reply #8179 on: November 29, 2021, 03:18:22 PM »

I wish to encourage people to do the single player missions except I don't know the method in an API to detect the score or even if the player attempted it once. I've scanned thorugh the Global API and asked around looking for something which I thought some super old mod would use, but found nothing. Does a method exist?

Alex

  • Administrator
  • Admiral
  • *****
  • Posts: 24128
    • View Profile
Re: Misc modding questions that are too minor to warrant their own thread
« Reply #8180 on: November 29, 2021, 03:22:40 PM »

I don't think there is, no. The scores are stored in saves/mission_scores.json but that's no good either, since iirc you wouldn't be able to read stuff from there using SettingsAPI.loadJSON() etc.
Logged

Wyvern

  • Admiral
  • *****
  • Posts: 3803
    • View Profile
Re: Misc modding questions that are too minor to warrant their own thread
« Reply #8181 on: November 29, 2021, 03:36:08 PM »

I know you can get some amount of fancy code running for specific missions - things like the old Ship and Weapon Pack Arcade mission.

While that wouldn't let you get at the player score, it should let you track what's going on during the mission and write your own data to a file, which could then be read during the main campaign.
Logged
Wyvern is 100% correct about the math.

Alex

  • Administrator
  • Admiral
  • *****
  • Posts: 24128
    • View Profile
Re: Misc modding questions that are too minor to warrant their own thread
« Reply #8183 on: November 30, 2021, 09:30:44 AM »

If I remove something from a faction file's known hullmods, (how) would that affect an already existing game?

It won't - adding things via the .faction file will work on an existing game, but removing them will not. Reason being, it's possible to add, say, a known hull (or hullmod, etc) in some other way - for example, selling a blueprint to pirates, or something else scripted a mod might do. The game doesn't know *why* a faction knows what it does, so it doesn't simply reset to the faction's known set of things on game load - though it does ensure that the faction knows everything in the .faction file.
Logged

Timid

  • Admiral
  • *****
  • Posts: 640
  • Personal Text
    • View Profile
Re: Misc modding questions that are too minor to warrant their own thread
« Reply #8184 on: November 30, 2021, 11:35:56 AM »

It won't - adding things via the .faction file will work on an existing game, but removing them will not. Reason being, it's possible to add, say, a known hull (or hullmod, etc) in some other way - for example, selling a blueprint to pirates, or something else scripted a mod might do. The game doesn't know *why* a faction knows what it does, so it doesn't simply reset to the faction's known set of things on game load - though it does ensure that the faction knows everything in the .faction file.
What is the point of the removeKnownFighter, removeKnownHullMod, removeKnownIndustry, removeKnownShip, removeKnownWeapon.. etc then?

Or did I misread.

Alex

  • Administrator
  • Admiral
  • *****
  • Posts: 24128
    • View Profile
Re: Misc modding questions that are too minor to warrant their own thread
« Reply #8185 on: November 30, 2021, 12:06:51 PM »

They work on the faction data in the campaign. I was talking about making changes in the .faction file. But, yeah, removing stuff that the faction "knows" via the .faction file through these methods will only work until the save is re-loaded. So if it's desired to suppress ships etc the faction has in the faction file, you'd have to do call these methods in onSaveLoad().
« Last Edit: November 30, 2021, 12:08:23 PM by Alex »
Logged

Yunru

  • Admiral
  • *****
  • Posts: 1560
    • View Profile
Re: Misc modding questions that are too minor to warrant their own thread
« Reply #8186 on: December 01, 2021, 06:25:56 AM »

Another basic one: If I have a ballistic weapon that uses missile projectiles, which bonuses (from skills and the like) does it benefit from?

Ruddygreat

  • Admiral
  • *****
  • Posts: 524
  • Seals :^)
    • View Profile
Re: Misc modding questions that are too minor to warrant their own thread
« Reply #8187 on: December 01, 2021, 06:42:06 AM »

Another basic one: If I have a ballistic weapon that uses missile projectiles, which bonuses (from skills and the like) does it benefit from?

the projectile will benefit from missile-buffing stuff (like eccm's speed & missile spec's hp buff) but the weapon will benefit from ballistic buffs, I found this out this morning whille messing w/ a kyeltziv technocracy ship

SafariJohn

  • Admiral
  • *****
  • Posts: 3023
    • View Profile
Re: Misc modding questions that are too minor to warrant their own thread
« Reply #8188 on: December 01, 2021, 03:37:56 PM »

If a modular ship has Phase Cloak, will its modules phase with it automatically?
Logged

Wyvern

  • Admiral
  • *****
  • Posts: 3803
    • View Profile
Re: Misc modding questions that are too minor to warrant their own thread
« Reply #8189 on: December 01, 2021, 03:41:23 PM »

If a modular ship has Phase Cloak, will its modules phase with it automatically?
98% confident that the answer is nope.
Logged
Wyvern is 100% correct about the math.
Pages: 1 ... 544 545 [546] 547 548 ... 710