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)

Pages: 1 ... 10 11 [12] 13 14 ... 16

Author Topic: [0.97a] LazyLib v2.8b (released 2024-02-02)  (Read 979204 times)

LazyWizard

  • Global Moderator
  • Admiral
  • *****
  • Posts: 1363
    • View Profile
    • GitHub Profile
Re: [0.8.1a] LazyLib v2.3 (released 2018-11-12)
« Reply #165 on: November 12, 2018, 06:11:49 PM »

LazyLib 2.3 is up, get it here (mirror).

Important note: if you're using one of the dev versions of the console mod that are floating around, those dev versions may conflict with this LazyLib release. You can update to this dev version from last month to avoid the issue.

The big new feature in this update is sprite font rendering. You've probably seen this in the console mod if you use it, but now it's available for all mods. Enjoy!

Spoiler
[close]

This release also includes the usual bugfixes and performance improvements, as well as some new methods for modders. Also more javadoc. so much javadoc...

Full changelog:
Quote
2.3 (November 12, 2018)
=========================
Bundled the Kotlin runtime library (v1.3.0) with LazyLib:
 - Kotlin is an alternate JVM language that is 100% interoperable with Java
 - "Core" LazyLib is and always shall be written in Java, though some features
   such as the font classes are written in Kotlin for convenience's sake
 - Kotlin extension methods can be found within the org.lazywizard.lazylib.ext
   package in jars/LazyLib-Kotlin.jar (Java users can safely ignore this jar)
Added @Nullable and @NotNull annotations where appropriate
Added org.lazywizard.lazylib.ui.LazyFont:
 - Represents a bitmap font (the same type Starsector itself uses)
 - Load a font using the static method loadFont(String fontPath)
 - Use createText() to create a reusable DrawableString, which can draw a
   block of text repeatedly and very efficiently
 - Use drawText() to manually draw text into a VBO or display list
 - See LazyFont's javadoc for example usage
Changes to CampaignUtils:
 - Added getEntitiesWithRep(SectorEntityToken token, String entityTag,
   IncludeRep include, RepLevel rep)
 - Added toWorldCoordinates(Vector2f screenCoordinates)
 - Added toScreenCoordinates(Vector2f worldCoordinates)
Changes to CollectionUtils:
 - Added implode(Enum toImplode)
 - Added implode(Enum toImplode, String separator)
Changes to CollisionUtils:
 - Added getNearestPointOnBounds(Vector2f source, CombatEntityAPI entity)
Changes to ColorUtils:
 - Added glColor(Color color, float alpha)
Changes to CombatUtils:
 - Added toWorldCoordinates(Vector2f screenCoordinates)
 - Added toScreenCoordinates(Vector2f worldCoordinates)
Changes to FastTrig:
 - Added atan() and atan2() that are much faster (though less accurate)
   than the implementations in Java's core Math class
   (roughly 5-20x faster; accurate to within 0.005 radians/~0.29 degrees)
Changes to MathUtils:
 - Added FPI and FTAU constants, contain Math.PI and Math.PI * 2 as floats
 - Added clamp(float/int toClamp, float/int min, float/int max). This clamps
   the passed value within the given range. Variants are provided for both
   integers and floats.
 - Added getNearestPointOnLine(Vector2f source, Vector2f lineStart,
   Vector2f lineEnd)
 - Added getPoint(Vector2f center, float radius, float angle). This acts as an
   alias for the existing getPointOnCircumference(), which is both the most
   commonly used method in LazyLib as well as one of the most awkwardly named
Changes to ModUtils:
 - Added isModEnabled(String modId)
 - Added loadClassesIfClassIsPresent(String classCanonicalName,
   List<String> classesToLoadCanonicalNames, boolean initializeClasses)
 - Added getEnabledModIds()
 - Added getOverrides(), returns vanilla files explicitly overridden by any
   mod (ie: in that mod's mod_info.sjon 'replace' section)
Changes to VectorUtils:
 - getFacing() and getAngle() now use FastTrig's new atan2() implementation
 - Added getFacingStrict() and getAngleStrict(), which are slower but more
   accurate (these use the old pre-2.3 atan2() implementations)
 - Added isZeroVector(Vector2f vector)
 - Added resize(Vector2f vector, float length)
 - Added resize(Vector2f vector, float length, Vector2f dest)
 - Added clampLength(Vector2f vector, float maxLength)
 - Added clampLength(Vector2f vector, float maxLength, Vector2f dest)
 - Added clampLength(Vector2f vector, float minLength, float maxLength)
 - Added clampLength(Vector2f toClamp, float minLength, float maxLength,
   Vector2f dest)
 - Added rotate(Vector2f toRotate, float angle), convenience method that
   stores the result in toRotate
 - Added rotateAroundPivot(Vector2f toRotate, Vector2f pivotPoint,
   float angle), convenience method that stores the result in toRotate
Removed from LazyLib:
 - Removed isDevBuild()
Removed from SimpleEntity:
 - Removed Object constructor (it used reflection, which is now blocked;
   remaining options are Vector2f, WeaponAPI, and ShipEngineAPI)
Miscellaneous Javadoc improvements
« Last Edit: November 12, 2018, 07:30:44 PM by LazyWizard »
Logged

Nicke535

  • Commander
  • ***
  • Posts: 240
  • Degenerate Core
    • View Profile
Re: [0.8.1a] LazyLib v2.3 (released 2018-11-12)
« Reply #166 on: November 13, 2018, 06:38:51 AM »

Nice! A lot of good improvements across the board, and quite a lot of practical additions as well. Definitely gonna try and put this to use as soon as I can.

LazyWizard

  • Global Moderator
  • Admiral
  • *****
  • Posts: 1363
    • View Profile
    • GitHub Profile
Re: [0.9a] LazyLib v2.4 (released 2018-11-16)
« Reply #167 on: November 16, 2018, 11:01:57 AM »

LazyLib 2.4 is up, get it here (mirror).

Changelog:
Quote
2.4 (November 16, 2018)
=========================
Updated to be compatible with Starsector 0.9a
Updated bundled Kotlin runtime library to v1.3.10
Added org.lazywizard.lazylib.JSONUtils.CommonDataJSONObject:
 - Provides a wrapper around a standard JSONObject
 - save() method saves JSON to common data folder (saves/common), which will
   persist between saves (and presumably survive Starsector updates)
 - Constructor takes the filename under saves/common to save the data to
Changes to JSONUtils:
 - Added clear(JSONObject toClear)
 - Added loadCommonJSON(String filename)
   (if file does not exist, returns an empty CommonDataJSONObject)
 - Added loadCommonJSON(String filename, String defaultJSONPath)
   (if file does not exist, copies existing data from defaultJSONPath)
Logged

LazyWizard

  • Global Moderator
  • Admiral
  • *****
  • Posts: 1363
    • View Profile
    • GitHub Profile
Re: [0.9a] LazyLib v2.4b (released 2018-11-16)
« Reply #168 on: November 16, 2018, 08:52:14 PM »

LazyLib 2.4b is up, get it here (mirror).

Changelog:
Quote
2.4b (November 16, 2018)
==========================
Changes to JSONUtils:
 - loadCommonJSON(String filename, String defaultJSONPath) will save the newly
   created CommonDataJSONObject to disk immediately if defaultJSONPath exists
   and filename does not
Logged

Shrugger

  • Lieutenant
  • **
  • Posts: 61
    • View Profile
Re: [0.9a] LazyLib v2.4b (released 2018-11-16)
« Reply #169 on: November 25, 2018, 09:16:35 AM »

Getting an error here. Was just watching the title menu, and it went

Code
242012 [Thread-4] ERROR com.fs.starfarer.combat.CombatMain  - java.lang.NoSuchMethodError: org.lazywizard.lazylib.MathUtils.getPoint(Lorg/lwjgl/util/vector/Vector2f;FF)Lorg/lwjgl/util/vector/Vector2f;
java.lang.NoSuchMethodError: org.lazywizard.lazylib.MathUtils.getPoint(Lorg/lwjgl/util/vector/Vector2f;FF)Lorg/lwjgl/util/vector/Vector2f;
at data.scripts.ai.SCY_arcMissileAI.advance(SCY_arcMissileAI.java:197)
at com.fs.starfarer.combat.entities.Missile$GuidedMissileAIWrapper.advance(Unknown Source)
at com.fs.starfarer.combat.CombatEngine.advanceInner(Unknown Source)
at com.fs.starfarer.combat.CombatEngine.advance(Unknown Source)
at com.fs.starfarer.title.TitleScreenState.advance(Unknown Source)
at com.fs.starfarer.BaseGameState.traverse(Unknown Source)
at com.fs.state.AppDriver.begin(Unknown Source)
at com.fs.starfarer.combat.CombatMain.main(Unknown Source)
at com.fs.starfarer.StarfarerLauncher$1.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)
242013 [Thread-10] INFO  sound.null  - Playing music with id [064.ogg]

Maybe it's SCY that does it, but I've no idea.
Logged

LazyWizard

  • Global Moderator
  • Admiral
  • *****
  • Posts: 1363
    • View Profile
    • GitHub Profile
Re: [0.9a] LazyLib v2.4b (released 2018-11-16)
« Reply #170 on: November 25, 2018, 09:19:27 AM »

Do you have LazyLib enabled in the launcher?
Logged

Shrugger

  • Lieutenant
  • **
  • Posts: 61
    • View Profile
Re: [0.9a] LazyLib v2.4b (released 2018-11-16)
« Reply #171 on: November 25, 2018, 09:35:25 AM »

Yes.
Logged

LazyWizard

  • Global Moderator
  • Admiral
  • *****
  • Posts: 1363
    • View Profile
    • GitHub Profile
Re: [0.9a] LazyLib v2.4b (released 2018-11-16)
« Reply #172 on: November 25, 2018, 09:39:58 AM »

Are you running an old version of LazyLib? Make sure you're using the latest version (2.4b). There was never a 0.9a-compatible version without getPoint().

If you do have 2.4b, then some other mod must be including an old version of LazyLib for some reason.
Logged

Shrugger

  • Lieutenant
  • **
  • Posts: 61
    • View Profile
Re: [0.9a] LazyLib v2.4b (released 2018-11-16)
« Reply #173 on: November 25, 2018, 09:42:25 AM »

Damn, you're right. I thought I had updated all my mods, but LL must've slipped through somehow - I was still running 2.2.

Sorry for the bother. Next time we get an update, I'll nuke my mods folder straight away.
Logged

LazyWizard

  • Global Moderator
  • Admiral
  • *****
  • Posts: 1363
    • View Profile
    • GitHub Profile
Re: [0.9a] LazyLib v2.4c (released 2019-03-01)
« Reply #174 on: March 01, 2019, 05:59:35 PM »

LazyLib 2.4c is up, get it here (mirror).

Changelog:
Quote
2.4c (March 01, 2019)
=======================
Updated bundled Kotlin runtime library to v1.3.21
Changes to CombatUtils:
 - All getXWithinRange() methods have been updated to use 0.9a's new
   CollisionGridAPI, which should improve performance
 - getEntitiesWithinRange() now includes BattleObjectiveAPIs
Changes to LazyFont:
 - Fixed text blending issue
 - Blend mode is no longer automatically enabled during rendering - if you want
   your text to be drawn blended, you must ensure GL_BLEND is enabled and set
   the blend func (usually glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA))
Logged

Fantastic Chimni

  • Commander
  • ***
  • Posts: 104
  • Chimni
    • View Profile
Re: [0.9a] LazyLib v2.4c (released 2019-03-01)
« Reply #175 on: March 03, 2019, 02:39:52 PM »

So the new getEntitiesWithinRange() has some... Interesting effects when paired with code that has a knockback. https://imgur.com/3na0tLa

It WAS a nice planet.
« Last Edit: March 03, 2019, 02:42:43 PM by Fantastic Chimni »
Logged

LazyWizard

  • Global Moderator
  • Admiral
  • *****
  • Posts: 1363
    • View Profile
    • GitHub Profile
Re: [0.9a] LazyLib v2.4d (released 2019-03-03)
« Reply #176 on: March 03, 2019, 04:35:22 PM »

LazyLib 2.4d is up, get it here (mirror).

Changelog:
Quote
2.4d (March 03, 2018)
=======================
Changes to CombatUtils:
 - Reverted changes to getEntitiesWithinRange() (it now only returns ships,
   projectiles, missiles and asteroids as it did pre-2.4c)
Logged

LazyWizard

  • Global Moderator
  • Admiral
  • *****
  • Posts: 1363
    • View Profile
    • GitHub Profile
Re: [0.9a] LazyLib v2.4e (released 2019-04-21)
« Reply #177 on: April 21, 2019, 06:29:59 AM »

Version 2.4e is up, get it here (mirror).

This update reverts CombatUtils' getXInRange() methods to their pre-2.4c versions (thanks to Dark.Revenant for reporting their buggy behavior). It also adds coroutine support for those of you who use Kotlin.

In other news, I've put LazyLib's Javadoc online. It can now be viewed here.
Logged

Irlbbbagt

  • Ensign
  • *
  • Posts: 3
    • View Profile
Re: [0.9.1a] LazyLib v2.4e (released 2019-04-21)
« Reply #178 on: October 15, 2019, 02:34:45 AM »

Okay I am probably being an idiot but I cannot get this to run.  I have extracted it into my mods folder but when I try to run it I get a fatal error compiling org.lazywizard.lazylib.LazyLib

Looking at the mod_info.json I see that I might have to modify the MOD_ID at that location to fix the issue but there does not seem to be a MOD_ID file.

So I am a bit lost.  Any help would be greatly appreciated.  Thanks!
Logged

Midnight Kitsune

  • Admiral
  • *****
  • Posts: 2846
  • Your Friendly Forum Friend
    • View Profile
Re: [0.9.1a] LazyLib v2.4e (released 2019-04-21)
« Reply #179 on: October 15, 2019, 02:31:00 PM »

Did you download the source by mistake? Or did you forget to unzip the file into the mods folder?
Logged
Help out MesoTroniK, a modder in need

2021 is 2020 won
2022 is 2020 too
Pages: 1 ... 10 11 [12] 13 14 ... 16