I need help with a smp idea Help now!!! Pls

  • 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 community!

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

  • LOOKING FOR A VERSION OF SKRIPT?

    You can always check out skUnity Downloads for downloads and any other information about Skript!

DynamStudio

Member
Jul 27, 2024
3
0
1
So my idea is to create a kind of strength smp where the plan is to make it using skript so we’re gonna make it so a player drops a book when they die and if u right click that book u gain 1+ attack strength
 
Guys also leave ur discord names whoever can do this is gonna have to be a good skripter they will also become coowner
 
We will also need to make it so it display how much bonus attack strength u have and a way to revoke bonus strength
 
Code:
on death of player:
    drop a enchanted book named "&c&lbook o' strength" with lore "&7Right-click to gain +1 strength" at the victim
    if {bonusstr::%victim's uuid%} is more than 0:
        send "&c⚔ -1"
        set {bonusstr::%victim's uuid%} to {bonusstr::%victim's uuid%} - 1

on right click:
    if player's tool is a enchanted book named "&c&lbook o' strength":
        cancel event
        add 1 to {bonusstr::%player's uuid%}
        send "&a+1 attack strenght, u have &e%{bonusstr::%player's uuid%}% &abonus strength now!" to player
        remove 1 enchanted book from the player

command /strengthbalance:
    trigger:
        if {bonusstr::%player's uuid%} is not set:
            send "&au have 0 strength." to player
        else:
            send "&au have %{bonusstr::%player's uuid%}% strength." to player

####################################################
# this will display strenght at action bar VVV, remove if u dont want it
every 5 ticks:
    loop all players:
        send action bar "&c⚔ %{bonusstr::%loop-player's uuid%}%" to loop-player
####################################################

command /resetmystrength:
    permission: skript.strength.reset.self
    trigger:
        set {bonusstr::%player's uuid%} to 0
        send "&ei have reset ur strength, now u have 0"

command /strbook:
    permission: op
    trigger:
        send "&ebook has been given!"
        drop a enchanted book named "&c&lbook o' strength" with lore "&7Right-click to gain +1 strength" at the player

on damage:
    attacker is player:
        victim is not player:
            set {_dam} to damage + {bonusstr::%attacker's uuid%}
            damage victim by {_dam} hearts
        else:
            cancel event

this should work prob