1. 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!

Dismiss Notice
This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Addon skript-mirror 0.19.1

Natural reflection utilities for Skript

  1. btk5h

    Addon Developer

    Joined:
    Jan 25, 2017
    Messages:
    154
    Likes Received:
    153
    No, Bungeecord servers are separate from Bukkit servers.
     
  2. Spartan9802

    Spartan9802 Member

    Joined:
    Jan 26, 2017
    Messages:
    158
    Likes Received:
    7
    Could you add the possibility to create custom events?
    --- Double Post Merged, Jul 18, 2018, Original Post Date: Jul 18, 2018 ---
    Hey @btk5h,
    I find myself confronted with a small bug here is an example


    Code (Skript):
    1. effect create new quest named %string% [on npc %number%] [test %number%]:
    2.     trigger:
    3.         set {_npc} to CitizensAPI.getNPCRegistry().getById(Integer.parseInt("%expression-2%"))
    4.        
    5.         send "%expression-1% %expression-2% %expression-3%" to "Spartan9802" parsed as player
    6.        
    7.        
    8.        
    9. command /tquest:
    10.     trigger:
    11.         create new quest named "test" test 6
    Expression-2 returns 1 and not null or <none>
     
  3. btk5h

    Addon Developer

    Joined:
    Jan 25, 2017
    Messages:
    154
    Likes Received:
    153
    Working as intended. Optional expressions use their default value when omitted. You must prefix the type with - to mark it as nullable.
     
  4. Spartan9802

    Spartan9802 Member

    Joined:
    Jan 26, 2017
    Messages:
    158
    Likes Received:
    7
    Okay, can you show me I don't understand how to use the type
    Edit: Thanks :emoji_grinning:
     
    #164 Spartan9802, Jul 19, 2018
    Last edited: Jul 19, 2018
  5. _JustDylan_

    Supporter

    Joined:
    Apr 20, 2018
    Messages:
    36
    Likes Received:
    2
    Code (Skript):
    1. on left click:
    2.     broadcast "clicked"
    3.     event.getPlayer().spigot().sendMessage(ChatMessageType.ACTION_BAR!, TextComponent.fromLegacyText("test"))
    4.  
    5. 20.07 21:36:22 [Server] WARN method #sendMessage called with (ACTION_BAR (ChatMessageType), test (BaseComponent[])) threw a ClassCastException: Cannot cast [Lnet.md_5.bungee.api.chat.BaseComponent; to net.md_5.bungee.api.chat.BaseComponent
    I have some issues with action bars, according to donut this was a skript mirror bug, can you look into this
     
  6. jaylawl

    jaylawl Well-Known Member

    Joined:
    Jan 29, 2017
    Messages:
    173
    Likes Received:
    31
    Small bug:
    Code (Skript):
    1. condition test with %text%:
    2.     check:
    3.         continue if expression-1 = "asd"
    4.  
    5. command /test:
    6.     trigger:
    7.         test with "asd"
    8.         send "yes"
    %text% or %texts% will cause the command /test to not load at all, but not giving out any parser errors. however it will work with %string% or %strings%.

    it took me about an hour to find this issue, recommend to accept %texts% or document this better

    not meaning this in a negative way, loving this addon
     
  7. btk5h

    Addon Developer

    Joined:
    Jan 25, 2017
    Messages:
    154
    Likes Received:
    153
    Got it! This should be fixed in the next update.
     
    • Friendly Friendly x 1
  8. ShaneBee

    Supporter + Addon Developer

    Joined:
    Sep 7, 2017
    Messages:
    2,007
    Likes Received:
    138
    • Winner Winner x 1
  9. jaylawl

    jaylawl Well-Known Member

    Joined:
    Jan 29, 2017
    Messages:
    173
    Likes Received:
    31
    Hey, thanks for that recent update. I'm quite glad this add-on keeps receiving improvements. Also very glad to see you're making here-and-there updates to the gitbook.

    Below is one of my codes using skript-mirror. As you can see, there are many sections that require the use of getScoreboardTags and thus i have duplicated code.

    I tried to remove the duplication, by simply putting it in the parse section - but skript-mirror won't allow me to do that. It will state that there are no entities in a custom event (paraphrasing here).

    I'm not sure whether this a bug or intentional.

    Cheers for reading

    Code (Skript):
    1. plural expression:
    2.     patterns:
    3.         %entity%'s [scoreboard(-| )]tags
    4.         [all] [scoreboard(-| )]tags (of|from) %entity%
    5.     return type: texts
    6.     get:
    7.         set {_tags} to "%(expression-1).getScoreboardTags()%"
    8.         {_tags} != "[]":
    9.             replace " " in {_tags} with ""
    10.             set {_tags} to subtext of {_tags} from character 2 to (length of {_tags} - 1)
    11.             set {_tags::*} to {_tags} split at ","
    12.         return {_tags::*}
    13.     set:
    14.         set {_tags} to "%(expression-1).getScoreboardTags()%"
    15.         {_tags} != "[]"
    16.         replace " " in {_tags} with ""
    17.         set {_tags} to subtext of {_tags} from character 2 to (length of {_tags} - 1)
    18.         set {_tags::*} to {_tags} split at ","
    19.         loop {_tags::*}:
    20.             (expression-1).removeScoreboardTag(loop-value)
    21.         loop change values:
    22.             (expression-1).addScoreboardTag(loop-value)
    23.     add:
    24.         loop change values:
    25.             (expression-1).addScoreboardTag(loop-value)
    26.     remove:
    27.         loop change values:
    28.             (expression-1).removeScoreboardTag(loop-value)
    29.     delete:
    30.         set {_tags} to "%(expression-1).getScoreboardTags()%"
    31.         {_tags} != "[]"
    32.         replace " " in {_tags} with ""
    33.         set {_tags} to subtext of {_tags} from character 2 to (length of {_tags} - 1)
    34.         set {_tags::*} to {_tags} split at ","
    35.         loop {_tags::*}:
    36.             (expression-1).removeScoreboardTag(loop-value)
    37.     reset:
    38.         set {_tags} to "%(expression-1).getScoreboardTags()%"
    39.         {_tags} != "[]"
    40.         replace " " in {_tags} with ""
    41.         set {_tags} to subtext of {_tags} from character 2 to (length of {_tags} - 1)
    42.         set {_tags::*} to {_tags} split at ","
    43.         loop {_tags::*}:
    44.             (expression-1).removeScoreboardTag(loop-value)
     
  10. ShaneBee

    Supporter + Addon Developer

    Joined:
    Sep 7, 2017
    Messages:
    2,007
    Likes Received:
    138
  11. Florenthz

    Florenthz Member

    Joined:
    Dec 5, 2017
    Messages:
    8
    Likes Received:
    0
    Hi there, sorry for write here but I dont know how to open a post in this forum, but... Someone knows if is there a version of skript compatible with 1.13? or a dev build?
     
  12. ShaneBee

    Supporter + Addon Developer

    Joined:
    Sep 7, 2017
    Messages:
    2,007
    Likes Received:
    138
    • Like Like x 1
  13. ShaneBee

    Supporter + Addon Developer

    Joined:
    Sep 7, 2017
    Messages:
    2,007
    Likes Received:
    138
    btk5h updated skript-mirror with a new update entry:

    skript-mirror 0.18.0

    Read the rest of this update entry...
     
  14. Florenthz

    Florenthz Member

    Joined:
    Dec 5, 2017
    Messages:
    8
    Likes Received:
    0
    Hi there friend, this plugin replaces original skript?
    Or what is it?

    Excuse my wrong english
     
  15. btk5h

    Addon Developer

    Joined:
    Jan 25, 2017
    Messages:
    154
    Likes Received:
    153
    Hello! skript-mirror is an addon, meaning you run it alongside Skript. Just place it in your plugins folder like any other plugin and you'll have access to the features that skript-mirror adds.
     
  16. Spartan9802

    Spartan9802 Member

    Joined:
    Jan 26, 2017
    Messages:
    158
    Likes Received:
    7
    Really great!
    You forgot to add instance usage in your doc :emoji_wink:
    - Are you thinking of adding custom event support? :emoji_grinning:
    - Will you create a simple support for powerful ArrayList? :emoji_slight_smile:
     
  17. btk5h

    Addon Developer

    Joined:
    Jan 25, 2017
    Messages:
    154
    Likes Received:
    153
    1. Instance usage?
    2. Yes, this has been mentioned in #91
    3. No, that is outside the scope of this addon. You can already use ArrayLists with skript-mirror.
     
  18. Spartan9802

    Spartan9802 Member

    Joined:
    Jan 26, 2017
    Messages:
    158
    Likes Received:
    7
    Yes you have a condition instance of, but it is not written in the doc yet it is important I find ^^
    Ah I hadn't seen great!
    Too bad I'm not sure I use them well, I wouldn't want to fill my ram for nothing ^^
     
  19. Uzumaki

    Uzumaki Well-Known Member

    Joined:
    Feb 20, 2017
    Messages:
    289
    Likes Received:
    8
    can anyone help me with this
    Code (Skript):
    1.  
    2. # SkyWars X
    3.  
    4. import:
    5.     me.wazup.skywars.events.SWPlayerJoinArenaEvent
    6.  
    7. on SWPlayerJoinArenaEvent:
    8.     set {_p} to event.getPlayer()
    9.     set {_arena} to event.getArena() #Not work
    10.     broadcast "%{_p}%, %{_arena}%"
    how i can get the arena of player?
    thanks.

    Edit: solved, it was 'getArenaName'
     
    #179 Uzumaki, Sep 6, 2018
    Last edited: Sep 6, 2018
  20. ShaneBee

    Supporter + Addon Developer

    Joined:
    Sep 7, 2017
    Messages:
    2,007
    Likes Received:
    138
    btk5h updated skript-mirror with a new update entry:

    skript-mirror 0.19.0

    Read the rest of this update entry...
     
Loading...