You are viewing a potentially older version of this package. View all versions.
AALUND13-JARL-2.0.0 icon

JARL

JARL (Just Another Rounds Library) is a versatile toolkit that introduces a Armor Framework and provides utilities like CustomCardUnity to streamline the creation of custom cards in Unity.

Date uploaded 17 hours ago
Version 2.0.0
Download link AALUND13-JARL-2.0.0.zip
Downloads 216
Dependency string AALUND13-JARL-2.0.0

This mod requires the following mods to function

Pykess-ModdingUtils-0.4.6 icon
Pykess-ModdingUtils

Utilities aimed at making modding easier and more accessible

Preferred version: 0.4.6
willis81808-ModsPlus-1.6.2 icon
willis81808-ModsPlus

Willis' amazing modding utilities

Preferred version: 1.6.2
willis81808-UnboundLib-3.2.10 icon
willis81808-UnboundLib

This is a helpful utility for ROUNDS modders aimed at simplifying common tasks.

Preferred version: 3.2.10
Root-Classes_Manager_Reborn-1.5.4 icon
Root-Classes_Manager_Reborn

A recreation of the original Classes Manager, with added features.

Preferred version: 1.5.4

README

JARL (Just Another Rounds Library) 2.0.0

JARL (Just Another Rounds Library) is a versatile toolkit that introduces a Armor Framework and provides utilities like CustomCardUnity to streamline the creation of custom cards in Unity.

Feel free send your suggestions or bug report in issues tab.

Features

  • Armor Framework: JARL integrates a flexible Armor Framework, empowering developers to craft their own armor or incorporate methods into armors created by other developers. This is achieved through the utilization of DamageProcessingMethodsAfter and DamageProcessingMethodsBefore, allowing for extensive customization.

  • Custom Card Unity: JARL also includes CustomCard for Unity, a class that can be inherited to create custom cards within the Unity environment.

Usage

Armor Framework

Creating a Armor Type

You can create an armor type by inheriting from the ArmorBase class. Here is an example of an armor type:

public class ExampleArmor : ArmorBase {
    public override BarColor GetBarColor() {
        return new BarColor(Color.cyan * 0.6f, Color.cyan * 0.45f);
    }

    public override void SetupArmor() {
        armorTags.Add("CanArmorPierce");
        reactivateArmorType = ArmorReactivateType.Second;
    }
}

The base class ArmorBase has a lot of methods/properties that you can change/override to customize your armor. Take a look at the ArmorBase class to see all the methods/properties that you can change/override.

Registering Armor

After creating your armor, you can register it using the RegisterArmorType method from the ArmorFramework class:

void Start() {
	ArmorFramework.RegisterArmorType(new ExampleArmor());
}

Adding Armor To Players

You can add armor to a player, for example, when a player picks a card, by using the AddArmor method from the ArmorHandler class:

public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) {
    ArmorFramework.armorHandlers[player].AddArmor(typeof(ExampleArmor), 50, 5, 5, ArmorReactivateType.Second, 5);
}

Custom Card Unity

Creating a Custom Card Fr Unity

You can create a custom card unity by inheriting from CustomCardUnity. Here is an example of a custom card for Unity:

using JARL.Abstract;
using JARL.Extensions;
using UnityEngine;

public class ExampleUnityCard : CustomCardUnity {
    public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) {
	    // Your Code Here
    }

    public override string GetModName() {
        return "Your Mod Initials";
    }
}