SheepScriptLib

Quick rating

SheepScriptLib

No reviews yet

Based on CustomNpcs, it provides some useful tools.

Mod Loaders
Forge
Minecraft

Community voices

Reviews

Versions
Loading versions…
Match includes

Click once to include, again to exclude, again to clear

Rating Any
Any 0.5 1.0 1.5 2.0 2.5 3.0 3.5 4.0 4.5 5.0
Min
Max
Play Status
Reviews
Time Played
hrs+
Verified developers only
Has developer response
List view
Grid view
Compact view
Sort by
Date
Rating
Helpful
Unhelpful
Edited
Sort ascending
Delete this review?

This removes your review from the project. You can write a new review after.

Review submitted for moderation

Your review has been sent to moderators, who will check that it meets our guidelines before it appears publicly.

No reviews yet. Be the first to review this project!

Get it on

Available Platforms

About

Project Details

Type
Mod
Latest Version
[1.12.2]SheepScriptLib-1.25.1.jar
Authors

For authors

Embed Badge

If you're the author of this project, you can embed a live badge anywhere that supports HTML or Markdown. It updates automatically whenever ratings change.

Custom banner text
ModDex rating badge preview

Use HTML for any page that supports it, or Markdown for README files and Markdown-based descriptions.

Identifiers

Platform IDs

CurseForge ID

Resources

External Links

Source Issues Wiki Discord

About

Description

The detail of API will provided later.

Functions

BetterCloneHandler:

    Provides clones' caches, instead of CNPC's real-time IO, it will be fast.

SheepAI:

    Implement class: saltsheep.ssl.api.SheepAI, saltsheep.ssl.api.SheepAIHandler

    new AI and inputs: owner IEntity, whetherShouldRun(IEntity)=>boolean, run(IEntity)=>void,endedRun(IEntity)=>void, canStopDefault boolean

    use SheepAIHandler to add ai to a ai group.

    SheepAI is working based on async thread, and use waitTick(int) to wait in the thread then use work(()=>void) to run in the server thread, it is well designed to have a great efficiency.

Task:

    A light function that provides task chain and delay work.

    Use like: Task.run(function(){}).append(Task.delay(10)).append(Task.run(function(){})).start();

    Also can be hignly customed, use Task.custom(runnable init, Callable<boolean> invoke, Callable<Task> clone), and it will ended when invoke return true or server stopped.

NeoPuppet:

    This function based on the edit of JobPuppet, the mod use ASM to append extra logic on JobPuppet getRotation method.

    It is too complex to explain, it is better to see in saltsheep.ssl.api.neo.AnimationHandler, saltsheep.ssl.api.neo.AnimationNode.

    It will be easy.

BothSideScript:

    It provides a chance to use script in both server and client, and you can switch it.

    It may be a bit dangerous for the server owner because I set no limit for the script. My meaning is, player can cheat by using it, because it works like a mod.

    The only way to avoid it completely is to delete the function.

    Using it:

        the files with suffix ".ssl.js" under directory .minecraft\SheepBothScripts, which contains its sub directory, will be loaded by eval.

        the scripts will defaultly have two extra global variable: station and script

        script: saltsheep.ssl.script.ScriptContainer, set the container name, hook events(FMLEvents will have special implement)

        station: saltsheep.ssl.api.Common.station, a javascript object stored at Java layer, you can use it to achieve the connection of scripts.

    But it didnt provide any client's wrapper API, which like CNPC's API,  for you.

The more:

    There's many scattered functions under saltsheep.ssl.api, you can discover it by yourself.

Dependencies

SheepKeyLib, CustomNpcs

Screenshots

Gallery

This project has no gallery images yet.

Versions

Files

Relations

Project Relations

More like this

Similar Mods

Suggestions use data such as tags, dependencies, dependents, descriptions, titles, and more to rank how much they overlap with this mod.

On ModDex

Community snapshot

0
Ratings
0
Followers
0
In stacks

By the numbers

Statistics

~20,000
Downloads
Last Updated
Created
Last synced
When ModDex last fetched this project from CurseForge or Modrinth. Every project is re-checked on a schedule, and any project that ships a new file is synced automatically within hours of the release.
New file updates sync automatically
How syncing works