Facsk
  • Welcome to skUnity!

    Welcome to skUnity! This is a forum where members of the Skript community can communicate and interact. Skript Resource Creators can post their Resources for all to see and use.

    If you haven't done so already, feel free to join our official Discord server to expand your level of interaction with the comminuty!

    Now, what are you waiting for? Join the community now!

Supported Minecraft Versions
  1. 1.10
  2. 1.11
aT16CWj.png

FacSk aims to add full control of Factions within Skript.


I have been asked many many times to add Factions support to Skellett (My other Skript addon) I get atleast one or more message a week asking to add support for it. So I decided to make a new Addon. Here you go enjoy!

Main:
  • 100% faction player control
  • 100% faction control
  • 90% events
  • 0% faction flag support
  • 5% relationships and rival support
  • 0% faction permission support
Required:
  • Java 8
  • Factions and MassiveCore
  • Any Spigot version that Factions and MassiveCore support
Player Syntax:
Expressions:

code_language.skript:
[the] faction[s] player [(from|in|of)] (1¦%-player%|2¦[uuid] %-string%)

#Changers: set (Faction)
#Info: Setting this is the faction that the player should autoclaim for.
[the] auto[ ]claim [(mode|state)] of faction[s] player %mplayer%
faction[s] player %mplayer%'s auto[ ]claim [(mode|state)]

#Last activity is data that Factions uses for clearing out inactive players
#If you set this to anything it will only update the player to the current time so their data won't be deleted for inactivity
[the] last activity [time] of faction[s] player %mplayer%
faction[s] player %mplayer%'s last activity [time]

#Changers: set (String)
[the] [faction] ID of faction[s] player %mplayer%
faction[s] player %mplayer%'s [faction] ID

#Changers: set (Faction), reset
#Info: resetting this will set their faction to the default faction
[the] faction of faction[s] player %mplayer%
faction[s] player %mplayer%'s faction

#Changers: set (Rel), reset
#Info: Rel is the name of roles in Factions
#Info: resetting this will set their role to the default role
[the] faction role of faction[s] player %mplayer%
faction[s] player %mplayer%'s faction role

#Changers: set (String)
[the] [faction] title of faction[s] player %mplayer%
faction[s] player %mplayer%'s [faction] title

#Changers: set (Number)
[the] [faction] power[ ]boost[er] of faction[s] player %mplayer%
faction[s] player %mplayer%'s [faction] power[ ]boost[er]

#Changers: set (Number), reset
#Info: resetting this will set their power to the default power
[the] power of faction[s] player %mplayer%
faction[s] player %mplayer%'s power

[the] max[imum] power of faction[s] player %mplayer%
faction[s] player %mplayer%'s max[imum] power

[the] max[imum] universal power of faction[s] player %mplayer%
faction[s] player %mplayer%'s max[imum] universal power

[the] power per hour [rate] of faction[s] player %mplayer%
faction[s] player %mplayer%'s power per hour [rate]

[the] power (per|loss on) death [rate] of faction[s] player %mplayer%
faction[s] player %mplayer%'s power (per|loss on) death [rate]

#Changers: set (Boolean)
[the] map [auto] [update] [(mode|state)] of faction[s] player %mplayer%
faction[s] player %mplayer%'s map [auto] [update] [(mode|state)]

#Changers: set (Boolean)
[the] overriding [(mode|state)] of faction[s] player %mplayer%
faction[s] player %mplayer%'s overriding [(mode|state)]

#Changers: set (Boolean)
#Info: This is a toggle for players to view the title of a faction when they enter a faction claim
[the] territory [info] title[s] [(mode|state|toggle)] of faction[s] player %mplayer%
faction[s] player %mplayer%'s territory [info] title[s] [(mode|state|toggle)]

[the] faction name of faction[s] player %mplayer%
faction[s] player %mplayer%'s faction name

[the] name and title of faction[s] player %mplayer% [and] [with] (data [of]|from|and|compared to) faction %faction%

[the] name and title of faction[s] player %mplayer% [and] [with] (data [of]|from|and|compared to) player %mplayer%

#Info: This is loopable
[(the|all)] [of] [the] faction[s] players

#Info: This returns just the normal name of the player (E.g: LimeGlass)
[the] name of faction[s] player %mplayer%
faction[s] player %mplayer%'s name

#Grabs the player from MPlayer
[the] player of faction[s] player %mplayer%
faction[s] player %mplayer%'s player


Effects:

code_language.skript:
load [the] faction[s] (data|info) of %mplayer%
load %mplayer%'s faction[s] (data|info)

(reset|clear) [the] faction[s] (data|info) of %mplayer%
(reset|clear) %mplayer%'s faction[s] (data|info)

(force|make) [the] faction[s] player %mplayer% leave [their] [faction]

(force|make) [the] faction[s] player %mplayer% [to] [try (and|to)] claim %locations% [for [faction] %-faction%]


Conditions:

code_language.skript:
[the] faction[s] player %mplayer% (1¦is|2¦is(n't| not)) [a] (default|noob|new|fresh off the boat) [player]

[the] faction[s] player %mplayer% (1¦[does] ha(s|ve)|2¦do[es](n't| not) have) [a] faction

[the] faction[s] player %mplayer% (1¦[does] ha(s|ve)|2¦do[es](n't| not) have) [a] [faction] title

[the] faction[s] player %mplayer% (1¦[does] ha(s|ve)|2¦do[es](n't| not) have) [a] [faction] power[ ]boost[er]

[the] faction[s] player %mplayer% (1¦is|2¦is(n't| not)) in [their] own (territory|land|claim)

[the] faction[s] player %mplayer% (1¦is|2¦is(n't| not)) in enemy (territory|land|claim)


Faction Syntax:
Expressions:

code_language.skript:
[the] faction at [location] %location%

#Info: Grabs a faction either by name or id
[the] faction from [faction] (string|id|name) %string%

#Info: This is loopable
[(the|all)] [of] [the] factions

#Changers: set (String)
[the] name of faction %faction%

#Changers: set (String)
[the] description of faction %faction%
faction %faction%'s description

#Changers: set (String)
[the] motd of faction %faction%
faction %faction%'s motd

#Info: This is loopable
[(the|all)] [of] [the] motd messages (of|from) faction %faction%
[(the|all)] [of] [the] faction %faction%'s motd messages

#Changers: set (Timeperiod)
[the] time creat(e[d]|ion) of faction %faction%
[the] time faction %faction% was created

#Changers: set (Location)
[the] home [location] of faction %faction%
faction %faction%'s home [location]

#Changers: set (Number)
[the] power[ ]boost[er] of faction %faction%
faction %faction%'s power[ ]boost[er]

[the] power of faction %faction%
faction %faction%'s power

[the] max[imum] power of faction %faction%
faction %faction%'s max[imum] power

[the] [amount of] land [(count|size)] [(of|from)] faction %faction% [has] [in [world] %-string%]
faction %faction%'s land [(count|size)] [in [world] %-string%]

#Info: This is loopable
[(the|all)] [of] [the] (claimed worlds|worlds [claimed]) [(of|by)] faction %faction% [has claims in]
faction %faction%'s claimed worlds

#Info: This is loopable
[(the|all)] [of] [the] players (in|of) faction %faction%
faction %faction%'s players

#Info: This is loopable
[(the|all)] [of] [the] (1¦online|2¦offline) players (in|of) faction %faction%
faction %faction%'s (1¦online|2¦offline) players

#Info: This is loopable
[(the|all)] [of] [the] players with role %factionrel% (in|of) faction %faction%
faction %faction%'s players with role %factionrel%

[the] leader of faction %faction%
faction %faction%'s leader

[get] [the] war[ ]zone faction

[get] [the] (wilderness|none) faction

[get] [the] safe[ ]zone faction


Effects:

code_language.skript:
load [the] faction[s] (data|info) of faction %faction%
load faction %faction%'s faction[s] (data|info)

#Info: This removes the current leader of a faction and replaces them with the next best replacement
promote [a] [new] leader in faction %faction%
promote %faction%'s faction leader

(send|message) %strings% [to] faction %faction%


Conditions:

code_language.skript:
[the] faction %faction% (1¦[does] ha(s|ve)|2¦do[es](n't| not) have) [a] description

[the] faction %faction% (1¦[does] ha(s|ve)|2¦do[es](n't| not) have) [a[n]] motd

[the] faction %faction% (1¦[does] ha(s|ve)|2¦do[es](n't| not) have) [a] home [location]

[the] home at [location] %location% (1¦is|2¦is(n't| not)) valid for faction %faction%
[the] [location] %location% (1¦is|2¦is(n't| not)) [a] valid home [location] for faction %faction%

#Info: This checks if a faction has more land and than power (Meaning they could easily have land claimed)
[the] faction %faction% (1¦[does] ha(s|ve)|2¦do[es](n't| not) have) [a] land inflation

#Info: Tests if all the faction players are online or offline
[the] faction %faction% players are [all] (1¦offline|2¦online)

[are] any faction %faction% players online

[are] explosions (1¦(disabled|not allowed)|2¦(enabled|allowed)) in faction %faction%


Events:

code_language.skript:
 [on] [facsk] faction[s] create:
 
       #Returns the faction
       event-faction
 
   [on] [facsk] faction[s] desc[ription] (change|edit):
 
       #Returns the faction
       event-faction
 
       #Returns the new description
       event-string

   [on] [facsk] faction[s] disband:
 
       #Returns the faction
       event-faction
 
   [on] [facsk] faction[s] home (change|edit):
 
       #Returns the faction
       event-faction
 
       #Returns the location of the new home
       event-location
 
   [on] [facsk] faction[s] invite:
 
       #Returns the faction
       event-faction
 
       #Returns the mplayer
       event-mplayer
 
   [on] [facsk] faction[s] motd (change|edit):
 
       #Returns the faction
       event-faction
 
       #Returns the new motd
       event-string
 
   [on] [facsk] faction[s] name (change|edit):
 
       #Returns the faction
       event-faction
 
       #Returns the new name
       event-string
 
   [on] [facsk] faction[s] (role|rank) (change|edit):
 
       #Returns the mplayer
       event-mplayer
 
       #Returns the event rank change
       [the] event(-| )(rel|role|rank)
 
   [on] [facsk] faction[s] relation[s] (change|edit):
 
       #Returns the faction
       event-faction
 
       #Returns the faction
       [the] other [event(-| )]faction
 
       #Returns the event rel change
       [the] event(-| )(rel|role|rank)
 
   [on] [facsk] faction[s] title (change|edit):
 
       #Returns the mplayer
       event-mplayer
 
       #Returns the new title
       event-string

Types:

mplayer

faction

factionrel

Factionrel enum types:

ENEMY(
"an enemy", "enemies", "an enemy faction", "enemy factions",
"Enemy"
),
NEUTRAL(
"someone neutral to you", "those neutral to you", "a neutral faction", "neutral factions",
"Neutral"
),
TRUCE(
"someone in truce with you", "those in truce with you", "a faction in truce", "factions in truce",
"Truce"
),
ALLY(
"an ally", "allies", "an allied faction", "allied factions",
"Ally"
),
RECRUIT(
"a recruit in your faction", "recruits in your faction", "", "",
"Recruit"
),
MEMBER(
"a member in your faction", "members in your faction", "your faction", "your factions",
"Member"
),
OFFICER(
"an officer in your faction", "officers in your faction", "", "",
"Officer", "Moderator"
),
LEADER(
"your faction leader", "your faction leader", "", "",
"Leader", "Admin", "Owner"
);

Example script
code_language.skript:
command /test:
   trigger:
       set {_p} to faction player from player
       message "Autoclaim state: %auto claim state of faction player {_p}%"
       message "Last activity: %last activity time of faction player {_p}%"
       make faction player {_p} claim player's location


Hope you enjoy this Factions hook in Skript! Leave a 5 star review to show your support :emoji_grinning:
Author
LimeGlass
Downloads
212
Views
863
First release
Last update
Rating
4.22 star(s) 9 ratings

More resources from LimeGlass

Latest reviews

I got this problem with my script that it just says <none> on the scoreboard and i dont know how to fix...

on join:
set {_player} to faction player from player
set {_faction} to faction of faction player {_player}
set {_faction-name} to name of faction {_faction}
set {_faction-power} to power of faction {_player}

every 10 ticks:
loop all players:
wipe loop-player's sidebar
set name of sidebar of loop-player to "&8-=- &f&lMine&3&lValley &8-=-"
set score "&8&m -----------------" in sidebar of loop-player to 11
set score "&3Spiller&8 » &f%loop-player%" in sidebar of loop-player to 10
set score "&3Penge&8 » &f%loop-player's balance%" in sidebar of loop-player to 9
set score "&3Online&8 » &f%{players.online}%" in sidebar of loop-player to 8
set score "&3Online Staff&8 » &f%size of {Online.Staff::*}%" in sidebar of loop-player to 7
set score "&8 &m---&8=&m---&8 " in sidebar of loop-player to 6
set score "&3Faction &8» &f%{_faction-name}%" in sidebar of loop-player to 5
set score "&3Power &8» &f%{_faction-power}%&3/&f%{_facpm}%" in sidebar of loop-player to 4
set score "&3Kills &8» &f%{kills.%uuid of loop-player%}%" in sidebar of loop-player to 3
set score "&3Døde &8» &f%{death.%uuid of loop-player%}%" in sidebar of loop-player to 2
set score " &8&m-----------------" in sidebar of loop-player to 1
Can you make one for FactionsUUID aswell? because i don't use Mcore anymore..
LimeGlass
LimeGlass
When I get around to recoding Facsk I will.
Awesome ! I found i little bug. When i get the leader of a faction after loop all factions (set {_chef} to leader of faction loop-value). I don't get the name of the leader of the faction. I get the "Mpplayer" of the leader with lastactivitymillis, factionid, role and power.

Can you fix it ? Thank. (I'm french)
Like dan330 said down there, add support for LegacyFactions. It's way better, can be translated, less laggy, etc. Thanks!
Good plugin but could you add support for LegacyFactions it is a really growing up Factions UUID rework!
Good but does not support 1.7.10
[05:11:42 INFO]: [Facsk] Enabling Facsk v1.0.1
[05:11:42 ERROR]: Error occurred while enabling Facsk v1.0.1 (Is it up to date?)
java.lang.NoSuchMethodError: com.gmail.thelimeglass.Utils.PropertyType.value()Ljava/lang/String;
at com.gmail.thelimeglass.Facsk.register(Facsk.java:158) ~[?:?]
at com.gmail.thelimeglass.Facsk.onEnable(Facsk.java:76) ~[?:?]
at org.bukkit.plugin.java.JavaPlugin.setEnabled(JavaPlugin.java:316) ~[spigot1710.jar:git-Spigot-1.7.9-R0.2-208-ge0f2e95]
at org.bukkit.plugin.java.JavaPluginLoader.enablePlugin(JavaPluginLoader.java:332) [spigot1710.jar:git-Spigot-1.7.9-R0.2-208-ge0f2e95]
at org.bukkit.plugin.SimplePluginManager.enablePlugin(SimplePluginManager.java:412) [spigot1710.jar:git-Spigot-1.7.9-R0.2-208-ge0f2e95]
at org.bukkit.craftbukkit.v1_7_R4.CraftServer.loadPlugin(CraftServer.java:476) [spigot1710.jar:git-Spigot-1.7.9-R0.2-208-ge0f2e95]
at org.bukkit.craftbukkit.v1_7_R4.CraftServer.enablePlugins(CraftServer.java:394) [spigot1710.jar:git-Spigot-1.7.9-R0.2-208-ge0f2e95]
at net.minecraft.server.v1_7_R4.MinecraftServer.n(MinecraftServer.java:360) [spigot1710.jar:git-Spigot-1.7.9-R0.2-208-ge0f2e95]
at net.minecraft.server.v1_7_R4.MinecraftServer.g(MinecraftServer.java:334) [spigot1710.jar:git-Spigot-1.7.9-R0.2-208-ge0f2e95]
at net.minecraft.server.v1_7_R4.MinecraftServer.a(MinecraftServer.java:290) [spigot1710.jar:git-Spigot-1.7.9-R0.2-208-ge0f2e95]
at net.minecraft.server.v1_7_R4.DedicatedServer.init(DedicatedServer.java:210) [spigot1710.jar:git-Spigot-1.7.9-R0.2-208-ge0f2e95]
at net.minecraft.server.v1_7_R4.MinecraftServer.run(MinecraftServer.java:458) [spigot1710.jar:git-Spigot-1.7.9-R0.2-208-ge0f2e95]
at net.minecraft.server.v1_7_R4.ThreadServerApplication.run(SourceFile:628) [spigot1710.jar:git-Spigot-1.7.9-R0.2-208-ge0f2e95]
LimeGlass
LimeGlass
What java version are you using? String is not a thing?

This is not the correct location to post bug reports. PM me.
It is an good plugin, but please add 1.8.8 support! Lots of people still use 1.8.8!!!!
Finally i found an addon for Factions! Are you planning to insert the documentation in skUnity?
LimeGlass
LimeGlass
Can't unless I get permission from an Admin which I asked multiple times for.
Seems to be awesome, although I made my own land claim script xD - not sure whether Factions = Land Claim...

Maybe is it for other people helpful.
Great work Lime! :)