command /librus: trigger: librus(player) function uwagiPOZ(p: player): if {uwagiPOZ::%{_p}%::*} is not set: send "&cNie masz żadnych uwag pozytywnych :c" to {_p} stop set {_gui} to chest inventory with 3 rows named "&aUwagi pozytywne: " loop {uwagiPOZ::%{_p}%::*}: add book named "&cUwaga pozytywna" with lore "" and "&7Treść uwagi: " and "&a%loop-value%" and "" to {_gui} set slot (integers between 18 and 26) of {_gui} to gray stained glass pane named "&7-" set slot 26 of {_gui} to red dye named "&cPowrót " open {_gui} to {_p} function uwagiNEG(p: player): if {uwagiNEG::%{_p}%::*} is not set: send "&aNie masz żadnych uwag negatywnych!" to {_p} stop set {_gui} to chest inventory with 3 rows named "&cUwagi negatywne: " loop {uwagiNEG::%{_p}%::*}: add book named "&cUwaga negatywna" with lore "" and "&7Treść uwagi: " and "&a%loop-value%" and "" to {_gui} set slot (integers between 18 and 26) of {_gui} to gray stained glass pane named "&7-" set slot 26 of {_gui} to red dye named "&cPowrót " open {_gui} to {_p} function ogloszenia(p: player): if {ogłoszenia::*} is not set: send "&cNie ma żadnych ogłoszeń!" to {_p} stop set {_gui} to chest inventory with 3 rows named "&8Ogłoszenia: " loop {ogłoszenia::*}: add painting named "&bOgłoszenie: " with lore "" and "&7Treść: &a%loop-value%" to {_gui} set slot (integers between 18 and 27) of {_gui} to gray stained glass pane named "&7-" set slot 26 of {_gui} to red dye named "&cPowróć " open {_gui} to {_p} function librus(p: player): set {_gui} to chest inventory with 3 rows named "&8Librus" set slot (integers between 0 and 27) of {_gui} to gray stained glass pane named "&7-" set slot 10 of {_gui} to bookshelf named "&cUwagi&7/&aPochwały" set slot 13 of {_gui} to enchanted book named "&6Oceny" set slot 16 of {_gui} to map named "&bOgłoszenia" open {_gui} to {_p} function uwagi(p: player): set {_gui} to chest inventory with 1 rows named "&3Uwagi" set slot (integers between 0 and 9) of {_gui} to gray stained glass pane named "&7-" set slot 2 of {_gui} to written book named "&cUwagi negatywne" set slot 4 of {_gui} to red dye named "&cPowrót" set slot 6 of {_gui} to written book named "&aUwagi pozytywne" open {_gui} to {_p} on inventory click: if name of event-inventory is "&8Librus": cancel event if clicked slot is 10: uwagi(player) if clicked slot is 13: oceny(player) if clicked slot is 16: ogloszenia(player) if name of event-inventory is "&3Uwagi": cancel event if clicked slot is 2: uwagiNEG(player) if clicked slot is 4: librus(player) if clicked slot is 6: uwagiPOZ(player) if name of event-inventory is "&6Oceny": cancel event if clicked slot is 0 or 1 or 2 or 3 or 4 or 5 or 6 or 7 or 8: set {_slot} to uncolored name of clicked slot wait 1 ticks ocenyCHECK(player, {_slot}) else if clicked slot is 17: librus(player) if name of event-inventory contains "&8Przedmiot: ": cancel event if clicked slot is 26: oceny(player) if name of event-inventory is "&aUwagi pozytywne: ": cancel event if clicked slot is 26: uwagi(player) if name of event-inventory is "&cUwagi negatywne: ": cancel event if clicked slot is 26: uwagi(player) if name of event-inventory is "&8Ogłoszenia: ": cancel event if clicked slot is 26: librus(player) command /dodajocene [] [] []: permission: nauczyciel.exe permission message: &cNie możesz wstawiać ocen ponieważ nie jesteś nauczycielem! trigger: if arg 1 is not set: send "&cPoprawne użycie: /dodajocene [przedmiot] [ocena 1-6] [gracz]" else if arg 2 is not "1" or "2" or "3" or "4" or "5" or "6": send "&cPoprawne użycie: /dodajocene [przedmiot] [ocena 1-6] [gracz]" else if arg 3 is not set: send "&cPoprawne użycie: /dodajocene [przedmiot] [ocena 1-6] [gracz]" else: if arg 1 is "matematyka" or "chemia" or "fizyka" or "biologia" or "historia" or "polski" or "angielski" or "geografia" or "wf": add "%arg 2%" to {oceny::%arg 1%::%player%::*} send "&7Pomyślnie dodano ocene &a%arg 2% &7 do przedmiotu: &a%arg 1%&7 dla gracza: &a%arg 3%" else: send "&cNie możesz dodać oceny do przedmiotu którego nie ma!" command /dodajuwage [] [] []: permission: nauczyciel.exe permission message: &cNie możesz wstawiać uwag ponieważ nie jesteś nauczycielem! trigger: if arg 1 is "pozytywna" or "negatywna": if arg 2 is set: if arg 3 is set: if arg 1 is "pozytywna": add arg 3 to {uwagiPOZ::%player%::*} send "&7Pomyślnie dodano uwagę pozytywną graczowi: &a%arg 2%" send "&7o treści: &a%arg 3%" if arg 1 is "negatywna": add arg 3 to {uwagiNEG::%player%::*} send "&7Pomyślnie dodano uwagę negatywną graczowi: &a%arg 2%" send "&7o treści: &a%arg 3%" else: send "&cPoprawne użycie: /dodajuwage " else: send "&cPoprawne użycie: /dodajuwage " else: send "&cPoprawne użycie: /dodajuwage " command /zresetujuwage [] []: permission: nauczyciel.exe permission message: &cNie możesz wstawiać uwag ponieważ nie jesteś nauczycielem! trigger: if arg 1 is "pozytywna" or "negatywna": if arg 2 is set: if arg 1 is "pozytywna": clear {uwagiPOZ::%arg 2%::*} send "&aPomyślnie zresetowano uwagi pozytywne graczowi %arg 2%" if arg 1 is "negatywna": clear {uwagiNEG::%arg 2%::*} send "&aPomyślnie zresetowano uwagi negatywne graczowi %arg 2%" else: send "&cPoprawne użycie: /zresetujuwage " function oceny(p: player): set {_gui} to chest inventory with 2 rows named "&6Oceny" set slot 0 of {_gui} to knowledge book named "&2Matematyka" set slot 1 of {_gui} to knowledge book named "&3Polski" set slot 2 of {_gui} to knowledge book named "&4Biologia" set slot 3 of {_gui} to knowledge book named "&6Angielski" set slot 4 of {_gui} to knowledge book named "&5Historia" set slot 5 of {_gui} to knowledge book named "&9Geografia" set slot 6 of {_gui} to knowledge book named "&bWf" set slot 7 of {_gui} to knowledge book named "&cFizyka" set slot 8 of {_gui} to knowledge book named "&aChemia" set slot (integers between 9 and 17) of {_gui} to gray stained glass pane named "&7-" set slot 17 of {_gui} to red dye named "&cPowrót " open {_gui} to {_p} function ocenyCHECK(p: player, slot: text): set {_gui} to chest with 3 rows named "&8Przedmiot: &9%{_slot}%" if {oceny::%{_slot}%::%{_p}%::*} is not set: send "&7Nie masz żadnej oceny z przedmiotu: &a%{_slot}%!" to {_p} stop loop {oceny::%{_slot}%::%{_p}%::*}: add book named "&aOcena: &6%loop-value%" with lore "" and "&7To jest ocena ktrórą" and "&7dostałeś z przedmiutu: &a%{_slot}%!" and "" to {_gui} set slot 26 of {_gui} to red dye named "&cPowrót " open {_gui} to {_p} command /zresetujocene [] []: permission: nauczyciel.exe permission message: &cNie możesz wstawiać uwag ponieważ nie jesteś nauczycielem! trigger: if arg 1 is "matematyka" or "chemia" or "fizyka" or "biologia" or "historia" or "polski" or "angielski" or "geografia" or "wf": if arg 2 is set: clear {oceny::%arg 1%::%arg 2%::*} send "&7Pomyślnie zresetowano oceny z przedmiotu: &a%arg 1%!" else: send "&cPoprawne użycie: /zresetujocene " else: send "&cPoprawne użycie: /zresetujocene " command /dodajogłoszenie []: permission: nauczyciel.exe permission message: &cNie możesz wstawiać uwag ponieważ nie jesteś nauczycielem! trigger: if arg 1 is set: add arg 1 to {ogłoszenia::*} send "&7Poprawnie dodano ogłoszenie " send "&7o treści: &a%arg 1%" else: send "&cPoprawne użycie: /dodajogłoszenie " command /zresetujogłoszenia: usage: &cPoprawne użycie: /zresetujogłoszenia permission: nauczyciel.exe permission message: &cNie możesz wstawiać uwag ponieważ nie jesteś nauczycielem! trigger: clear {ogłoszenia::*} send "&aPomyślnie zresetowano ogloszenia!" on tab complete of "/dodajocene": set tab completions for position 1 to "polski", "matematyka", "angielski", "biologia", "geografia", "historia", "wf", "chemia" and "fizyka" set tab completions for position 2 to 1, 2, 3, 4, 5 and 6 on tab complete of "/zresetujocene": set tab completions for position 1 to "polski", "matematyka", "angielski", "biologia", "geografia", "historia", "wf", "chemia" and "fizyka" on tab complete of "/zresetujuwage": set tab completions for position 1 to "negatywna" and "pozytywna" on tab complete of "/dodajuwage": set tab completions for position 1 to "negatywna" and "pozytywna"