Fractal Softworks Forum

Please login or register.

Login with username, password and session length
Advanced search  

News:

Starsector 0.97a is out! (02/02/24); New blog post: Simulator Enhancements (03/13/24)

Author Topic: [RESOLVED!] The type com.thoughtworks.xstream.XStream cannot be resolved.  (Read 1887 times)

creature

  • Captain
  • ****
  • Posts: 400
    • View Profile

Hi, I'm a newbie modder trying to get into scripting but I am getting an error at the very first line of my first mod plugin saying:

Code
The type com.thoughtworks.xstream.XStream cannot be resolved. It is indirectly referenced from required .class files

I followed this Eclipse modding tutorial to get this far:

https://fractalsoftworks.com/forum/index.php?topic=4344.0

It seems that the error is connected to BaseModPlugin, as when I remove the import line

Code
import com.fs.starfarer.api.BaseModPlugin;

The error disappears - except it's the base file that the plugin extends, so nothing else would work without it. Alex mentioned that there might be an issue with some of the jars I imported, so here's a shot of my project tree and the line where the error appears:



Would appreciate if you could help me out with this!
« Last Edit: October 25, 2019, 05:49:27 PM by creature »
Logged

Alex

  • Administrator
  • Admiral
  • *****
  • Posts: 23986
    • View Profile

I'd try adding the various .jar files in starsector-core/, except for the ones that end in _obf (which are obfuscared core files). The one you probably need for this error specifically is xstream-1.4.10.jar, but add the other ones as well to prevent similar problems in the future.
Logged

creature

  • Captain
  • ****
  • Posts: 400
    • View Profile

I'd try adding the various .jar files in starsector-core/, except for the ones that end in _obf (which are obfuscared core files). The one you probably need for this error specifically is xstream-1.4.10.jar, but add the other ones as well to prevent similar problems in the future.
Thanks Alex! After a long time of trial and error, I've finally found a combination of imported jars that allowed me to run my plugin!  ;D
Logged