#AxParticle - Skrypt na efekty z Particli options: Sciezka: AxParticle/config.yml function AxParticle_SetItem(p: player, slot: number, item: text, name: text, lore: text): if {_lore} is not "": set {_p}'s current inventory's slot {_slot} to {_item} parsed as item named "%{_name}%" with lore "%{_lore}%" else: set {_p}'s current inventory's slot {_slot} to {_item} parsed as item named "%{_name}%" function AxParticle_ReturnYML(t: text) :: text: if yaml value "%{_t}%" from file "{@Sciezka}" is set: set {_t} to yaml value "%{_t}%" from file "{@Sciezka}" return "%colored {_t}%" else: return "" function add(p: player, t: text, 1: number, 2: number, 3: number, a: text): set {_n} to 0 loop ("red" and "green" and "blue"): add 1 to {_n} if {_a} is "add": if {AxParticle::%{_t}%::%{_p}%::%loop-value%}+{_%{_n}%} >= 0: if {AxParticle::%{_t}%::%{_p}%::%loop-value%}+{_%{_n}%} <= 255: add {_%{_n}%} to {AxParticle::%{_t}%::%{_p}%::%loop-value%} else: send AxParticle_ReturnYML("Message.Add.Max") to {_p} else: send AxParticle_ReturnYML("Message.Add.Min") to {_p} if {_a} is "set": set {AxParticle::%{_t}%::%{_p}%::%loop-value%} to {_%{_n}%} AxParticle_SetItem({_p}, 13, AxParticle_ReturnYML("Gui.Edit.Colors.Current Color.Item"), AxParticle_ReturnYML("Gui.Edit.Colors.Current Color.Name"), "&7(&4%{AxParticle::%{_t}%::%{_p}%::red}%&7, &2%{AxParticle::%{_t}%::%{_p}%::green}%&7, &9%{AxParticle::%{_t}%::%{_p}%::blue}%&7)") on load: if yaml value "AxConfig" from file "{@Sciezka}" is true: send AxParticle_ReturnYML("Message.Console.Config-Success") to console else: send "&4Konfiguracja AxParticle nie zostala pobrana!" to console send "&4Rozpoczynam pobieranie... (Tworzenie pliku)!" to console create folder "plugins/Skript/scripts/{@Sciezka}" send "&aFolder Folder został pomyślnie stworzony!" to console create file "plugins/Skript/scripts/{@Sciezka}" send "&aPlik yml został pomyślnie stworzony!" to console wait 10 tick download "https://pastebin.com/raw/YTGrg6kh" to "plugins/Skript/scripts/{@Sciezka}" if yaml value "AxConfig" from file "{@Sciezka}" is true: send "&aPomyslnie pobrano konfiguracje!" to console else: send "&4Pobieranie nie powiodlo sie! Pobierz config recznie! https://pastebin.com/YTGrg6kh" to console command /Particle []: trigger: if player has permission "AxParticle": close player's inventory open chest with 1 rows named AxParticle_ReturnYML("Gui.Main.Name") to player loop 9 times: AxParticle_SetItem(player, ((loop-number)-1), AxParticle_ReturnYML("Gui.Main.Background.Item"), AxParticle_ReturnYML("Gui.Main.Background.Name"), AxParticle_ReturnYML("Gui.Main.Background.Lore")) AxParticle_SetItem(player, 1, AxParticle_ReturnYML("Gui.Main.Wings.Item"), AxParticle_ReturnYML("Gui.Main.Wings.Name"), AxParticle_ReturnYML("Gui.Main.Wings.Lore")) AxParticle_SetItem(player, 4, AxParticle_ReturnYML("Gui.Main.Spiral.Item"), AxParticle_ReturnYML("Gui.Main.Spiral.Name"), AxParticle_ReturnYML("Gui.Main.Spiral.Lore")) AxParticle_SetItem(player, 7, AxParticle_ReturnYML("Gui.Main.Ringo.Item"), AxParticle_ReturnYML("Gui.Main.Ringo.Name"), AxParticle_ReturnYML("Gui.Main.Ringo.Lore")) stop else: send AxParticle_ReturnYML("Message.Permission Message") on quit: loop ("Wings" and "Spiral" and "Ringo"): stopEffect "AxParticle.%loop-value%.%player%" on inventory click: if inventory name of current inventory of player is AxParticle_ReturnYML("Gui.Main.Name"): cancel event if clicked slot is 1 or 4 or 7: loop ("Wings" and "Spiral" and "Ringo"): if name of player's current inventory's slot slot is AxParticle_ReturnYML("Gui.Main.%loop-value%.Name"): set {_type} to loop-value set {_n} to AxParticle_ReturnYML("Gui.Management.Name") replace all "{TYPE}" with AxParticle_ReturnYML("Type.%{_type}%") in {_n} close player's inventory open chest with 1 rows named {_n} to player loop 9 times: AxParticle_SetItem(player, ((loop-number)-1), AxParticle_ReturnYML("Gui.Management.Background.Item"), AxParticle_ReturnYML("Gui.Management.Background.Name"), AxParticle_ReturnYML("Gui.Management.Background.Lore")) AxParticle_SetItem(player, 1, AxParticle_ReturnYML("Gui.Management.Stat-On.Item"), AxParticle_ReturnYML("Gui.Management.Stat-On.Name"), AxParticle_ReturnYML("Gui.Management.Stat-On.Lore")) AxParticle_SetItem(player, 3, AxParticle_ReturnYML("Gui.Management.Stat-Off.Item"), AxParticle_ReturnYML("Gui.Management.Stat-Off.Name"), AxParticle_ReturnYML("Gui.Management.Stat-Off.Lore")) AxParticle_SetItem(player, 5, AxParticle_ReturnYML("Gui.Management.Edit.Item"), AxParticle_ReturnYML("Gui.Management.Edit.Name"), AxParticle_ReturnYML("Gui.Management.Edit.Lore")) AxParticle_SetItem(player, 8, AxParticle_ReturnYML("Gui.Management.Back.Item"), AxParticle_ReturnYML("Gui.Management.Back.Name"), AxParticle_ReturnYML("Gui.Management.Back.Lore")) stop loop ("Wings" and "Spiral" and "Ringo"): set {_n} to AxParticle_ReturnYML("Gui.Management.Name") set {_e} to AxParticle_ReturnYML("Gui.Edit.Name") replace all "{TYPE}" with AxParticle_ReturnYML("Type.%loop-value%") in {_n} replace all "{TYPE}" with AxParticle_ReturnYML("Type.%loop-value%") in {_e} if inventory name of current inventory of player is {_n}: cancel event if clicked slot is 1: if {AxParticle::%loop-value%::%player%} is false: send AxParticle_ReturnYML("Message.Stat-Change.Stat-On") set {AxParticle::%loop-value%::%player%} to true if loop-value is "Wings": set {_r} to {AxParticle::Wings::%player%::red} set {_g} to {AxParticle::Wings::%player%::green} set {_b} to {AxParticle::Wings::%player%::blue} drawWings style (AxParticle_ReturnYML("Config.Wings.Style") parsed as number), particle1 "redstone", RGB {_r}, {_g}, {_b}, particle2 "redstone", RGB2 {_r}, {_g}, {_b}, particle3 "redstone", RGB3 {_r}, {_g}, {_b}, center player, id "AxParticle.%loop-value%.%player%", angle (AxParticle_ReturnYML("Config.Wings.Angle") parsed as number), height (AxParticle_ReturnYML("Config.Wings.Height") parsed as number), space (AxParticle_ReturnYML("Config.Wings.Space") parsed as number), visibleRange (AxParticle_ReturnYML("Config.Wings.VisibleRage") parsed as number), tps (AxParticle_ReturnYML("Config.Wings.Tps") parsed as number), second (AxParticle_ReturnYML("Config.Wings.Second") parsed as number) if loop-value is "Spiral": drawComplexSpiral particle "redstone", RGB {AxParticle::Spiral::%player%::red}, {AxParticle::Spiral::%player%::green}, {AxParticle::Spiral::%player%::blue}, center player, id "AxParticle.%loop-value%.%player%", rainbowMode {AxParticle::Spiral::%player%::Rainbow}, clockwise (AxParticle_ReturnYML("Config.Spiral.Clockwise") parsed as boolean), scan (AxParticle_ReturnYML("Config.Spiral.Scan") parsed as boolean), radius (AxParticle_ReturnYML("Config.Spiral.Radius") parsed as number), density (AxParticle_ReturnYML("Config.Spiral.Density") parsed as number), height (AxParticle_ReturnYML("Config.Spiral.Height") parsed as number), effectMod (AxParticle_ReturnYML("Config.Spiral.EffectMod") parsed as number), start (AxParticle_ReturnYML("Config.Spiral.Start") parsed as number), visibleRange (AxParticle_ReturnYML("Config.Spiral.VisibleRage") parsed as number) if loop-value is "Ringo": drawWarpRings style (AxParticle_ReturnYML("Config.Ringo.Style") parsed as number), particle "redstone", RGB {AxParticle::Ringo::%player%::red}, {AxParticle::Ringo::%player%::green}, {AxParticle::Ringo::%player%::blue}, center player, id "AxParticle.%loop-value%.%player%", rainbowMode {AxParticle::Ringo::%player%::Rainbow}, scan (AxParticle_ReturnYML("Config.Ringo.Scan") parsed as boolean), height (AxParticle_ReturnYML("Config.Ringo.Height") parsed as number), radius (AxParticle_ReturnYML("Config.Ringo.Radius") parsed as number), ringCount (AxParticle_ReturnYML("Config.Ringo.RingCount") parsed as number), ringDensity (AxParticle_ReturnYML("Config.Ringo.RingDensity") parsed as number), visibleRange (AxParticle_ReturnYML("Config.Ringo.VisibleRage") parsed as number) else: set {AxParticle::%loop-value%::%player%} to true send AxParticle_ReturnYML("Message.Stat-Change.Stat-Set") if clicked slot is 3: if {AxParticle::%loop-value%::%player%} is true: stopEffect "AxParticle.%loop-value%.%player%" send AxParticle_ReturnYML("Message.Stat-Change.Stat-Off") set {AxParticle::%loop-value%::%player%} to false else: set {AxParticle::%loop-value%::%player%} to false send AxParticle_ReturnYML("Message.Stat-Change.Stat-Set") if clicked slot is 5: close player's inventory set {_n} to AxParticle_ReturnYML("Gui.Edit.Name") replace all "{TYPE}" with AxParticle_ReturnYML("Type.%loop-value%") in {_n} open chest with 3 rows named {_n} to player add(player, "%loop-value%", 0, 0, 0, "add") AxParticle_SetItem(player, 22, AxParticle_ReturnYML("Gui.Edit.Colors.Rainbow.Item"), AxParticle_ReturnYML("Gui.Edit.Colors.Rainbow.Name"), AxParticle_ReturnYML("Gui.Edit.Colors.Rainbow.Lore")) set {_kolory::*} to "0" and "2", "5", "4", "7", "3", "14" set {_sloty::*} to 3 and 4, 5, 12, 14, 21, 23 loop 7 times: AxParticle_SetItem(player, {_sloty::%loop-number%}, "160:%{_kolory::%loop-number%}%", AxParticle_ReturnYML("Gui.Edit.Examples.Name"), " ") set {_n} to 0 loop (AxParticle_ReturnYML("Gui.Edit.Colors.Red.Item") and AxParticle_ReturnYML("Gui.Edit.Colors.Green.Item") and AxParticle_ReturnYML("Gui.Edit.Colors.Blue.Item")): AxParticle_SetItem(player, {_n}, "%loop-value-2%", "&a+1", " ") AxParticle_SetItem(player, {_n}+1, "%loop-value-2%", "&a+10", " ") AxParticle_SetItem(player, {_n}+7, "%loop-value-2%", "&c-1", " ") AxParticle_SetItem(player, {_n}+8, "%loop-value-2%", "&c-10", " ") add 9 to {_n} stop if clicked slot is 8: execute player command "particle" if inventory name of current inventory of player is {_e}: cancel event if type of player's current inventory's slot slot is (AxParticle_ReturnYML("Gui.Edit.Colors.Red.Item") parsed as item): add(player, "%loop-value%", ((uncolored name of player's current inventory's slot slot) parsed as number), 0, 0, "add") if type of player's current inventory's slot slot is (AxParticle_ReturnYML("Gui.Edit.Colors.Blue.Item") parsed as item): add(player, "%loop-value%", 0, 0, ((uncolored name of player's current inventory's slot slot) parsed as number), "add") if type of player's current inventory's slot slot is (AxParticle_ReturnYML("Gui.Edit.Colors.Green.Item") parsed as item): add(player, "%loop-value%", 0, ((uncolored name of player's current inventory's slot slot) parsed as number), 0, "add") if player's current inventory's slot slot is white glass pane or magenta glass pane or light green glass pane or yellow glass pane or gray glass pane or light blue glass pane or red glass pane: if player's current inventory's slot slot is white glass pane: add(player, "%loop-value%", 255, 255, 255, "set") if player's current inventory's slot slot is magenta glass pane: add(player, "%loop-value%", 204, 0, 204, "set") if player's current inventory's slot slot is light green glass pane: add(player, "%loop-value%", 153, 255, 102, "set") if player's current inventory's slot slot is yellow glass pane: add(player, "%loop-value%", 255, 255, 0, "set") if player's current inventory's slot slot is gray glass pane: add(player, "%loop-value%", 128, 128, 128, "set") if player's current inventory's slot slot is light blue glass pane: add(player, "%loop-value%", 0, 64, 255, "set") if player's current inventory's slot slot is red glass pane: add(player, "%loop-value%", 255, 0, 0, "set") if clicked slot is 22: if loop-value is not "Wings": if {AxParticle::%loop-value%::%player%::Rainbow} is true: set {AxParticle::%loop-value%::%player%::Rainbow} to false send AxParticle_ReturnYML("Message.Stat-Change.Rainbow.Stat-Off") else: set {AxParticle::%loop-value%::%player%::Rainbow} to true send AxParticle_ReturnYML("Message.Stat-Change.Rainbow.Stat-On") else: send AxParticle_ReturnYML("Message.Stat-Change.Rainbow.Stat-Wings") send AxParticle_ReturnYML("Message.Edit")