Fractal Softworks Forum

Please login or register.

Login with username, password and session length
Advanced search  

News:

Starsector 0.95a is out! (03/26/21); Blog post: Skill Changes, Part 2 (07/15/21)

Author Topic: Having Issues making a hullmod that does nothing.  (Read 205 times)

Flacman3000

  • Commander
  • ***
  • Posts: 188
  • A man cannot put his shaft into the unknown.
    • View Profile
    • Email
Having Issues making a hullmod that does nothing.
« on: April 11, 2021, 03:02:34 AM »

Hi guys I'm currently having issues making one hull mod that does nothing but give information in the description on the hullmod datasheet. but I get this message instead I'm using the shielded cargo script did I do something wrong?

422646 [Thread-4] ERROR com.fs.starfarer.combat.CombatMain  - java.lang.RuntimeException: Error compiling [data.scripts.hullmods.cu_InfaredEngines]
java.lang.RuntimeException: Error compiling [data.scripts.hullmods.cu_InfaredEngines]
   at com.fs.starfarer.loading.scripts.ScriptStore$3.run(Unknown Source)
   at java.lang.Thread.run(Unknown Source)
Caused by: java.lang.ClassNotFoundException: data.scripts.hullmods.cu_InfaredEngines
   at org.codehaus.janino.JavaSourceClassLoader.findClass(JavaSourceClassLoader.java:179)
   at java.lang.ClassLoader.loadClass(Unknown Source)
   at java.lang.ClassLoader.loadClass(Unknown Source)
   ... 2 more

My script is like this:

package data.hullmods;

import com.fs.starfarer.api.combat.BaseHullMod;

public class cu_InfaredEngines extends BaseHullMod {
   // nothing to do, just a marker hullmod
}

Logged
Ryzen 7 2700x, 1080ti, 16GB DDR4 RAM and playing SS on a SSD - Always stay ahead because when you're ahead you're rear anatomy is open to interpretation.

Carabus

  • Lieutenant
  • **
  • Posts: 64
    • View Profile
Re: Having Issues making a hullmod that does nothing.
« Reply #1 on: April 11, 2021, 04:42:50 AM »

package data.hullmods;

Shouldn't it be "data.scripts.hullmods"?
Or the other way, whereever you reference it by "data.scripts.hullmods" it should be "data.hullmods"?
« Last Edit: April 11, 2021, 04:44:48 AM by Carabus »
Logged

Flacman3000

  • Commander
  • ***
  • Posts: 188
  • A man cannot put his shaft into the unknown.
    • View Profile
    • Email
Re: Having Issues making a hullmod that does nothing.
« Reply #2 on: April 11, 2021, 11:40:07 AM »

package data.hullmods;

Shouldn't it be "data.scripts.hullmods"?
Or the other way, whereever you reference it by "data.scripts.hullmods" it should be "data.hullmods"?

I just switched it to this and now i get this error instead.

112034 [Thread-4] ERROR com.fs.starfarer.combat.CombatMain  - java.lang.RuntimeException: Error compiling [data.scripts.hullmods.cu_InfaredEngines]
java.lang.RuntimeException: Error compiling [data.scripts.hullmods.cu_InfaredEngines]
   at com.fs.starfarer.loading.scripts.ScriptStore$3.run(Unknown Source)
   at java.lang.Thread.run(Unknown Source)
Caused by: java.lang.ClassNotFoundException: data.scripts.hullmods.cu_InfaredEngines
   at org.codehaus.janino.JavaSourceClassLoader.findClass(JavaSourceClassLoader.java:179)
   at java.lang.ClassLoader.loadClass(Unknown Source)
   at java.lang.ClassLoader.loadClass(Unknown Source)
   ... 2 more


Logged
Ryzen 7 2700x, 1080ti, 16GB DDR4 RAM and playing SS on a SSD - Always stay ahead because when you're ahead you're rear anatomy is open to interpretation.