newbie protection gets removed because region has pvp allowed

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

  • LOOKING FOR A VERSION OF SKRIPT?

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

elyexee

Member
Jul 16, 2023
30
0
6
37
so what is happening is when i had pvp allowed i could hit the player but the newbie protection of that player gets removed but if i take off pvp allowed and let it neither allowed neither denied the pvp doesnt work for some reason i need somebody to help me as fast as they can because i gotta release my server
 
i want so the pvp stays in default and that the pvp works if u guys know ill be hearing u just to fix this
 
Ok first thing to do here is to change back your region to pvp allow.
Code:
#Canceling damage if player has newbie protection
on first join:
    #Giving player newbie protection through a variable
    set {newbie.%player%} to true
    #player keeps newbie protection for 15 minutes
    wait 15 minutes
    delete {newbie.%player%}
  
on damage:
    #This checks if the player has newbie protection
    if {newbie.%player%} is true:
        #If the player has newbie protection, then set the damage to 0
        set the damage to 0
 
Ok first thing to do here is to change back your region to pvp allow.
Code:
#Canceling damage if player has newbie protection
on first join:
    #Giving player newbie protection through a variable
    set {newbie.%player%} to true
    #player keeps newbie protection for 15 minutes
    wait 15 minutes
    delete {newbie.%player%}
 
on damage:
    #This checks if the player has newbie protection
    if {newbie.%player%} is true:
        #If the player has newbie protection, then set the damage to 0
        set the damage to 0
Code:
on first join:
    set {newbie::%player%} to true
    wait 15 minutes
    delete {newbie::%player%}
  
on damage:
    if {newbie::%victim%} is true:
        if "%region at victim%" contains "your region here":
            if attacker is player:
                cancel event
                send "&7This player has newbie protection" to attacker

This might work a little better. I did not test it so.
 
like i dont want skript
i want to make the pvp flag into default so i can use newbie pvp manager plugin
 
like i dont want skript
i want to make the pvp flag into default so i can use newbie pvp manager plugin
You're going to have to wait for PVP Manager to update their plugin because newbie protection even on my servers it isn't currently working, nor many other plugins feature,