Skip to content

This is a library to help assist modder's while making their mods.

License

Notifications You must be signed in to change notification settings

DjShinter/TownieLib

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

GitHub Readme Stats

TownieLib

Town of Salem 2 Mod Library!

Not to be confused with Coven.


GitHub Contributors GitHub Contributors Issues GitHub pull requests

Join the Discord! · Report Issues · Request Feature · Documentation

Love the project? Please consider contributing to help it improve.


TownieLib

The purpose of TownieLib is to help Modder's create mods for Town of Salem 2.

This project is an ongoing project and is under heavy development, so expect breaking with minor revisions before the 1.0.0 release.

TownieLib is mainly used to help making mods to prevent code repetition and complex code as it is only needed to be implemented once.

Example Code

using TownieLib;
using UnityEngine;

void Awake() 
    {
        // ur stuff
    }
void Update()
    {
        if (Input.GetKey(KeyCode.LeftControl) || Input.GetKey(KeyCode.RightControl))
        {
            if(Input.GetKeyDown(KeyCode.F))
            {
                Logger.LogInfo($"The game phase is {TownieApi.GamePhase}...");
            }
        }
        
    }

This example assumes you already know how to setup a BepInEx Plugin and be able to reference TownieLib.dll, and this advises you on how to use TownieLib, If TownieLib is missing a useful or required method / field, it can be requested here, and if you can contribute, you may read the contributing section!


Building this project

to be written...


Contributing

You would need to follow the "Building this project", and you can create a pull request.

All help is appreciated!


Is modding bannable?

To quote the "Salem Mod Loader" Discord.

Use the mod at your own risk, while you have very low odds of being banned, you could be at risk if you openly state in games you are running a modded client as trials may guilty you under hacking even though the mod gives no advantages.

Town of Salem Rules

No Cheating – Gaining an unfair advantage over players through means other than normal gameplay. This includes but isn’t limited to using multiple accounts in the same game, sharing information outside the game, using a foreign language to communicate in a way that can’t be understood by the players in the current locale, and posting screenshots to prove something happened in game.

To quote a developer in the official Town of Salem 2 Discord. Message Link

We plan to have official mod support, but having a good base is important. A new player won't have a mod preinstalled.


Credits

ljoonal - Very helpful! This project wouldn't have existed without them.

About

This is a library to help assist modder's while making their mods.

Topics

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages