on death problem

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

Status
Not open for further replies.

TopKenzo

Member
May 27, 2019
1
0
0
I have a problem,i want to make a jobs skript,but at tha job vanator(hunter) when i kill a zombie/cow/chicken/etc... i don't get any money,why?

Code:
on death:
    if {jobs::%attacker%::job1} or {jobs::%attacker%::job2} or {jobs::%attacker%::job3} is "vanator":
        if attacker's gamemode is survival:
            if world is "Survival":
                if the victim is a player:
                    add 15 to balance of attacker
                    send action bar "&aMeseria de vanator &f&l- &a+15$" to attacker
                if the victim is a zombie:
                    add 8 to balance of attacker
                    send action bar "&aMeseria de vanator &f&l- &a+8$" to attacker
                if the victim is a skeleton:
                    add 12 to balance of attacker
                    send action bar "&aMeseria de vanator &f&l- &a+12$" to attacker
                if the victim is a creeper:
                    add 10 to balance of attacker
                    send action bar "&aMeseria de vanator &f&l- &a+10$" to attacker
                if the victim is a witch:
                    add 13 to balance of attacker
                    send action bar "&aMeseria de vanator &f&l- &a+13$" to attacker
                if the victim is a spider:
                    add 7 to balance of attacker
                    send action bar "&aMeseria de vanator &f&l- &a+7$" to attacker
                if the victim is a sheep:
                    add 3 to balance of attacker
                    send action bar "&aMeseria de vanator &f&l- &a+3$" to attacker
                if the victim is a wolf:
                    add 4 to balance of attacker
                    send action bar "&aMeseria de vanator &f&l- &a+4$" to attacker
                if the victim is a cow:
                    add 3 to balance of attacker
                    send action bar "&aMeseria de vanator &f&l- &a+3$" to attacker
                if the victim is a pig:
                    add 2 to balance of attacker
                    send action bar "&aMeseria de vanator &f&l- &a+2$" to attacker
                if the victim is a chicken:
                    add 1 to balance of attacker
                    send action bar "&aMeseria de vanator &f&l- &a+1$" to attacker
 
Last edited:
I have a problem,i want to make a jobs skript,but at tha job vanator(hunter) when i kill a zombie/cow/chicken/etc... i don't get any money,why?

Code:
on death:
    if {jobs::%attacker%::job1} or {jobs::%attacker%::job2} or {jobs::%attacker%::job3} is "vanator":
        if attacker's gamemode is survival:
            if world is "Survival":
                if the victim is a player:
                    add 15 to balance of attacker
                    send action bar "&aMeseria de vanator &f&l- &a+15$" to attacker
                if the victim is a zombie:
                    add 8 to balance of attacker
                    send action bar "&aMeseria de vanator &f&l- &a+8$" to attacker
                if the victim is a skeleton:
                    add 12 to balance of attacker
                    send action bar "&aMeseria de vanator &f&l- &a+12$" to attacker
                if the victim is a creeper:
                    add 10 to balance of attacker
                    send action bar "&aMeseria de vanator &f&l- &a+10$" to attacker
                if the victim is a witch:
                    add 13 to balance of attacker
                    send action bar "&aMeseria de vanator &f&l- &a+13$" to attacker
                if the victim is a spider:
                    add 7 to balance of attacker
                    send action bar "&aMeseria de vanator &f&l- &a+7$" to attacker
                if the victim is a sheep:
                    add 3 to balance of attacker
                    send action bar "&aMeseria de vanator &f&l- &a+3$" to attacker
                if the victim is a wolf:
                    add 4 to balance of attacker
                    send action bar "&aMeseria de vanator &f&l- &a+4$" to attacker
                if the victim is a cow:
                    add 3 to balance of attacker
                    send action bar "&aMeseria de vanator &f&l- &a+3$" to attacker
                if the victim is a pig:
                    add 2 to balance of attacker
                    send action bar "&aMeseria de vanator &f&l- &a+2$" to attacker
                if the victim is a chicken:
                    add 1 to balance of attacker
                    send action bar "&aMeseria de vanator &f&l- &a+1$" to attacker
Add debug messages to see how far the code gets when you kill one of those entities.
 
Status
Not open for further replies.