Solved a

  • 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.
code_language.skript:
set {_eachWordCaps} to 1st char in each word of "%attacker%" to caps
Try this, never used it before but it should work! (SkStuff for addon)
 
  • Like
Reactions: Adrihun
before line 4 or after line 4?
code_language.skript:
on death:       
    if attacker is not a player:
        if attacker is set:
            player has permission "tag.player"
            set {_eachWordCaps} to 1st char in each word of "%attacker%" to caps
            set the death message to "&9Death -> &7%victim% &7was killed by a &a%{_eachWordCaps}%&7."
 
  • Like
Reactions: Adrihun
yes, installed it
code_language.skript:
[20:57:20 INFO]: [Skript] Enabling Skript v2.2-dev22f
[20:57:28 INFO]: [Skript] Loaded a total of 782074 english aliases
[20:57:28 INFO]: [Skript]  Created by Njol
[20:57:28 INFO]: [SkStuff] Enabling SkStuff v1.6.4.1
[20:57:28 INFO]: [SkStuff] SkStuff 1.6.4.1 has been successfully enabled!
[20:57:28 INFO]: [SkStuff] Registering general non version specific stuff...
[20:57:28 INFO]: [SkStuff] It looks like you're either running 1.8.4, 1.8.7, 1.8.8 or 1.8.9!
[20:57:28 INFO]: [SkStuff] Trying to register version specific stuff...
[20:57:28 INFO]: [SkStuff] Hooked into Metrics! Woohoo!!
[20:57:28 INFO]: [SkStuff] Everything ready! Loaded a total of 0 conditions, 6 effects, 0 events, 18 expressions and 2 types!

Using Skript 2.2 dev 22f
Using Spigot 1.8.9
Using ViaVersion Latest
Using Bungeecord 1.11 (Latest)
Using SkStuff 1.6.4.1
----------------------------
code_language.skript:
    if attacker is not a player:
        if attacker is set:
            player has permission "tag.player"
            set {_eachWordCaps} to 1st char in each word of "%attacker%" to caps
            set the death message to "&9Death » &7%victim% &7was killed by a &a%attacker%&7."
those aren't error, that's just stuff loading?
 
yea ik, there are no errors so why doesnt it work? weird :/

BTW i am using bungee 1.11 with spigot 1.8.9 and viaversion. If i player uses 1.12 client, does it use 1.9 pvp or 1.8 pvp
1.8 pvp, on the other clients it will appear to use 1.9 pvp but there isn't a cooldown or any of it. If the core server version is 1.8, it'll use 1.8 stuff. also, what doesnt work? post what happens in a picture when you get killed.
 
And you're broadcasting the variable? Try this:
code_language.skript:
    if attacker is not a player:
        if attacker is set:
            player has permission "tag.player"
            set {_eachWordCaps} to "%attacker%"
            set {_eachWordCaps} to 1st char in each word of "%{_eachWordCaps}%" to caps
            set the death message to "&9Death » &7%victim% &7was killed by a &a%attacker%&7."
 
And you're broadcasting the variable? Try this:
code_language.skript:
    if attacker is not a player:
        if attacker is set:
            player has permission "tag.player"
            set {_eachWordCaps} to "%attacker%"
            set {_eachWordCaps} to 1st char in each word of "%{_eachWordCaps}%" to caps
            set the death message to "&9Death » &7%victim% &7was killed by a &a%attacker%&7."
No, that code is wrong. You're broadcasting the attacker still. Use

Code:
set the death message to "&9Death » &7%victim% &7was killed by a &a%{_eachWordCaps}%&7."
 
No, that code is wrong. You're broadcasting the attacker still. Use

Code:
set the death message to "&9Death » &7%victim% &7was killed by a &a%{_eachWordCaps}%&7."
It was a mistake, I'm sure he would have caught that and fixed it, if not there isn't any hope lol.
 
Okay, Thanks. I also made some scripts so people can't swear, etc. But it doesn't work with my messaging script, could you please add Anti Swear to my message script (it will say don't swear) also Anti Spam (1 second) (it will say don't spam) also Anti Threat so it will say "don't accuse people of hacking" if they say "hack or hacker"

code_language.skript:
command /message [<offline player>] [<text>]:
    usage: send a msg to a player
    trigger:
        if arg 1 is not set:
            send "&9Error »&7 Wrong usage. Try again with &a/message <player> <message>&7."
        if arg 1 is set:
            if arg 2 is not set:
                send "&9Error »&7 Wrong usage. Try again with &a/message <player> <message>&7."
            if arg 1 is online:
                if arg 2 is set:
                    send "&9To » &a%arg 1% &f%arg 2%"
                    send "&9From » &a%player% &f%arg 2%" to arg 1
                    play "ORB_PICKUP" to arg-1 at volume 1.6
            else:
                send "&9Private Message »&7 Sorry but &a%arg-1%&7 is currently offline."

Also add anti ddos to it so whenever a player joins they have to move so they can chat in /message.
here is my anti ddos skript but it only works with the normal chat.

code_language.skript:
on join:
  set {playercanchat::%player%} to player's location
on chat:
  if {playercanchat::%player%} is set:
    if {playercanchat::%player%} is player's location:
      cancel event
    else:
      delete {playercanchat::%player%}
on script unload:
  delete {playercanchat::*}

I know this is hard to do but if you do it then i will give you a big shoutout
[doublepost=1488412194,1488407910][/doublepost]
pls @ThinkingAboutIt
bump
This is my last script i need to fix
try and fix it yourself, it's easy to do.
 
I tried :emoji_rage::emoji_rage::emoji_rage::emoji_rage::emoji_rage::emoji_rage::emoji_rage:
code_language.skript:
variables:
    {test::1} = shit
    {test::2} = fuck
    {test::3} = pussy
    {test::4} = cunt
    {test::5} = cock sucker
command /tell [<offline player>] [<text>]:
    usage: send a msg to a player
    trigger:
        if arg 1 is not set:
            send "&cWrong usage. Try again with &b/tell <player> <message>&c."
        if arg 1 is set:
            if arg 2 is not set:
                send "&cWrong usage. Try again with &b/tell <player> <message>&c."
            if arg 1 is online:
                if arg 2 is set:
                    if {test::*} does not contain arg-2:
                        send "&bTo: &a%arg 1% &f%arg 2%"
                        send "&bFrom: &a%player% &f%arg 2%" to arg 1
                        play "ORB_PICKUP" to arg-1 at volume 1.6
                    else:
                        send "&bWatch your language!"
            else:
                send "&cSorry but &b%arg-1%&c is currently offline."
            on join:
            set {playercanchat::%player%} to player's location
            on chat:
                if {playercanchat::%player%} is set:
                if {playercanchat::%player%} is player's location:
                cancel event
                message "&9Chat » &7Sorry, but you have to move a little more before you can chat."
        else:
      delete {playercanchat::*}
        on script unload:
        delete {playercanchat::*}
You can't say "if arg-1 is online" because you're doing a offline player instead of player, why would you need to message a offline player? you can't.
 
i made <offlineplayer> so the message will work "offline player" also this is my last script, so if you fix it, you won't have to worry about me any more :/
you would also get a shoutout on /credits, i don't know why you ain't helping
[doublepost=1488660258,1488660159][/doublepost]
Also, i have a mysql connected with skript, is there a way to make it so "on start" if it cant connect to skript, the server will shutdown? <- this is my last question
See if you can get info from the table, if it isn't set then shutdown, also why would I need to be oon a server's /credits that no one will ever look at nor care about, and why would I need to be on there anyways?
 
can you give me an example?
i went into my server log a couple of days ago and a lot of people did /credits cus it was on the server "announcments" and its good because then people can go on your skunity profile and like you etc..
I don't need likes or views, and there's good MySQL documentation on the skunity docs, skellet is good for that.
 
Status
Not open for further replies.