#report system gui
1 messages · Page 1 of 1 (latest)
vanilla
yeah
name would be report with the report number
the info you can get by setting some variables when the report is created
you would start by looping the reports list
trigger:
loop {reports::*}:```
ye
usage: &c/report <player> <reason>
trigger:
set {_reports} to a new chest inventory with 6 row named "&cReports"
add {report::%player's uuid%} to {reports::*}
command /reports:
trigger:
loop {reports::*}:```
trigger:
open chest inventory named "reports" to player
loop {reports::*}:``` forgot the gui itself
trigger:
open chest inventory named "reports" to player
loop size of {reports::*} times:
set slot loop-value - 1 to book named "Report ##%loop-value%"```
no, {_reports} is a local variable
and it's not an inventory
mb
do i copy the edited one?
trigger:
open chest inventory named "reports" to player
loop size of {reports::*} times:
set slot loop-value - 1 of player's top inventory to book named "Report ##%loop-value%"```
alr
I always forget the "of player's top inventory" part after the slot for some reason
ye it opened it
usage: &c/report <player> <reason>
trigger:
add {report::%player's uuid%} to {reports::*}
command /reports:
trigger:
open chest inventory named "reports" to player
loop size of {reports::*} times:
set slot loop-value - 1 of player's top inventory to book named "Report ##%loop-value%"```
now this should open an inventory with books with numbers and the amount of books should be equal to the amount of reports
wdym?
well you didn't add anything to it
{report::%player's uuid%} isn't set
it added that report to the gui tho
usage: &c/report <player> <reason>
trigger:
add arg-2 to {reports::*}
command /reports:
trigger:
open chest inventory named "reports" to player
loop size of {reports::*} times:
set slot loop-value - 1 of player's top inventory to book named "Report ##%loop-value%"```
works
thank you bro
how can i make it that it will delete it after i right click it?
usage: &c/report <player> <reason>
trigger:
add arg-2 to {reports::*}
command /reports:
trigger:
open chest inventory named "reports" to player
loop size of {reports::*} times:
set slot loop-value - 1 of player's top inventory to book named "Report ##%loop-value%"
on inventory click:
if name of event-inventory = "reports":
event-slot = loop-value:
set slot loop-value to air```
hm
that would theoretically work but it would show it again after you open it again because it's not deleted from the list
well it gotten errors anywayt
usage: &c/report <player> <reason>
trigger:
add arg-2 to {reports::*}
command /reports:
trigger:
open chest inventory named "reports" to player
loop size of {reports::*} times:
set slot loop-value - 1 of player's top inventory to book named "Report ##%loop-value%"
on inventory click:
if clicked inventory's name = "reports":
set clicked slot to air```
I know
how can i fix that
for right now you could do
usage: &c/report <player> <reason>
trigger:
add arg-2 to {reports::*}
command /reports:
trigger:
open chest inventory named "reports" to player
loop size of {reports::*} times:
if {reports::%loop-value%} is set:
set slot loop-value - 1 of player's top inventory to book named "Report ##%loop-value%"
on inventory click:
if clicked inventory's name = "reports":
set clicked slot to air
clear {reports::%clicked slot's index + 1%}```
it's not very pretty and will probably leave holes in the GUI after removing reports but I don't have much time, I'll try helping you later
it worked anyway too
but after ur done do u know how to sort them out?
like after u remove report 1, then report 2 will go to the first slot
I gotta figure something out for that
which also benefits me because when I'm done I can use this for my server for people to put job applications on a gui
nice haha
usage: &c/report <player> <reason>
trigger:
add arg-2 to {reports::*}
command /reports:
trigger:
open chest inventory named "&cReports" to player
loop size of {reports::*} times:
if {reports::%loop-value%} is set:
set slot loop-value - 1 of player's top inventory to book named "<##F51414>&lREPORT <##F51414>&l##%loop-value%" with lore "&8ᴘʟᴀʏᴇʀ ʀᴇᴘᴏʀᴛ" and "" and " <##F51414>&l▎ <##F51414>ɪɴꜰᴏʀᴍᴀᴛɪᴏɴ" and " <##F51414>&l▎ &fʀᴇᴘᴏʀᴛᴇᴅ ʙʏ: %arg-1%"
on inventory click:
if clicked inventory's name = "&cReports":
set clicked slot to air
clear {reports::%clicked slot's index + 1%}```
they cant see who they got reported by
cuz of this
how do i fix it
like I said I'll help with all that later, you'd have to add some values to the list or another way
ill wait
I just realized how confusing that was
im having a issue i just realized
i remove these
but when i reopen the inventory
it comes back
usage: &c/report <player> <reason>
trigger:
add arg-2 to {reports::*}
command /reports:
trigger:
open chest inventory named "&cReports" to player
loop size of {reports::*} times:
if {reports::%loop-value%} is set:
set slot loop-value - 1 of player's top inventory to book named "<##F51414>&lREPORT <##F51414>&l##%loop-value%" with lore "&8ᴘʟᴀʏᴇʀ ʀᴇᴘᴏʀᴛ" and "" and " <##F51414>&l▎ <##F51414>ɪɴꜰᴏʀᴍᴀᴛɪᴏɴ" and " <##F51414>&l▎ &fʀᴇᴘᴏʀᴛᴇᴅ ʙʏ: "
on inventory click:
if clicked inventory's name = "&cReports":
set clicked slot to air
clear {reports::%clicked slot's index + 1%}```
add 2 spaces before the set slot....
I don't have time rn tho, I'm at a barber
and I gotta do something else this evening so I'm not sure if I can do much else today but we'll see
kk
just realized there was no tab
gotta set it to a global var if u want that to work
btw about the removing part, couldnt u set the slot to air and remove the report from the list
that's what we did
i wanna content arg-1 of /report to the GUI of reports
alr
@topaz warren
usage: &c/report <player> <reason>
trigger:
add arg-2 to {reports::*}
command /reports:
trigger:
open chest inventory named "&cReports" to player
loop size of {reports::*} times:
if {reports::%loop-value%} is set:
set slot loop-value - 1 of player's top inventory to book named "<##F51414>&lREPORT <##F51414>&l##%loop-value%" with lore "&8ᴘʟᴀʏᴇʀ ʀᴇᴘᴏʀᴛ" and "" and " <##F51414>&l▎ <##F51414>ɪɴꜰᴏʀᴍᴀᴛɪᴏɴ" and " <##F51414>&l▎ &fʀᴇᴘᴏʀᴛᴇᴅ ʙʏ: "
on inventory click:
if clicked inventory's name = "&cReports":
cancel event
set clicked slot to air
clear {reports::%clicked slot's index + 1%}```
i want "ʀᴇᴘᴏʀᴛᴇᴅ ʙʏ: %arg-1%
but it doesnt work
cuz /reports doesnt have arg-1
so i smh need to connect arg-1 of /report to the gui
isnt arg1 the player ur reporting
yes
reported by would be the player who reports arg1 innit?
oh yeah its %player%
ye
%arg-1% doesnt work?
why would it
/reports doesnt have any arguments
look
usage: &c/report <player> <reason>
trigger:
add arg-2 to {reports::*}
command /reports:
trigger:
open chest inventory with 6 rows named "&cReports" to player
loop size of {reports::*} times:
if {reports::%loop-value%} is set:
set slot loop-value - 1 of player's top inventory to book named "<##F51414>&lREPORT <##F51414>&l##%loop-value%" with lore "&8ᴘʟᴀʏᴇʀ ʀᴇᴘᴏʀᴛ" and "" and " <##F51414>&l▎ <##F51414>ɪɴꜰᴏʀᴍᴀᴛɪᴏɴ" and " <##F51414>&l▎ &fʀᴇᴘᴏʀᴛᴇᴅ ʙʏ: %player%" and " <##F51414>&l▎ &fᴘʟᴀʏᴇʀ ʀᴇᴘᴏʀᴛᴇᴅ: %arg-1%"
on inventory click:
if clicked inventory's name = "&cReports":
cancel event
set clicked slot to air
clear {reports::%clicked slot's index + 1%}```
uh, what
??
the command has 2 args
what u mean
offlineplayer and text
/reports has no arguments
oh that one
wait so ur tryna get the arg1 from /report to put it in /reports
ye
thats easy just set arg1 of that to a var
idk how tho man
set {arg1} to %arg-1%
put this in /report
?
nothing
awesome
np
you made it!
what u got
why
cuz i deleted it
but i want report 5 to go to report 4 slot
so it looks more organized
try reopening the gui rq
ye it stays
huh
same place
did u delete report 4 from the list aswell?
do u understand what i mean
i do
?
once i remove a report
mate i get it
take a look?
i need ur updated code
bett
usage: &c/report <player> <reason>
trigger:
set {arg-1} to "%arg-1%"
set {arg-2} to "%arg-2%"
add arg-2 to {reports::*}
send "<##F51414>&lREPORT &f→ <##F51414>Your complaint has been sent."
play sound "entity.experience_orb.pickup" with volume 100 and pitch 1 to player
command /reports:
trigger:
open chest inventory with 6 rows named "&cReports" to player
loop size of {reports::*} times:
if {reports::%loop-value%} is set:
set slot loop-value - 1 of player's top inventory to book named "<##F51414>&lREPORT <##F51414>&l##%loop-value%" with lore "&8ᴘʟᴀʏᴇʀ ʀᴇᴘᴏʀᴛ" and "" and " <##F51414>&l▎ <##F51414>ɪɴꜰᴏʀᴍᴀᴛɪᴏɴ" and " <##F51414>&l▎ &fʀᴇᴘᴏʀᴛᴇᴅ ʙʏ: <##F51414>%player%" and " <##F51414>&l▎ &fᴘʟᴀʏᴇʀ ʀᴇᴘᴏʀᴛᴇᴅ: <##F51414>%{arg-1}%" and " <##F51414>&l▎ &fʀᴇᴀꜱᴏɴ: <##F51414>%{arg-2}%" and "" and "&8(( &7ᴄʟɪᴄᴋ ᴛᴏ ᴅᴇʟᴇᴛᴇ ))"
on inventory click:
if clicked inventory's name = "&cReports":
cancel event
set clicked slot to air
clear {reports::%clicked slot's index + 1%}```
gui gotta refresh yk
everytime i delete
a report
broadcast the reports list rq and tell me what it says
probably, the contents of 3 reports, then <none> and then the content of the 5th report
i might know why
use remove instead of clear if this is the case ^
wdym
alr
nvm
that doesnt work
do u not know how broadcast works
broadcast the list then
broadcast %{report::*}%?
yes..
alr
Dont forget the quotes
yeah.. i saw that coming from a mile away
is that bad
its {reports::*} not {report::*} mate
I think remove and clear do the same thing
i dont get it, why are you adding arg-2 to list
according to my skript
yeah meant delete
also the problem here is that skript doesn't automatically organizes lists, I know a way to fix this I think
oh ur not actually using the list contents for anything, just for counting
u talking about the gui?
im not sure why this is though since the list clearly updated but the gui didnt?
talking bout the list
if you read the code you get why this happens
I already told Mike that this would happen but that I had to go earlier
can you send the newest version?
alr
usage: &c/report <player> <reason>
trigger:
set {arg-1} to "%arg-1%"
set {arg-2} to "%arg-2%"
add arg-2 to {reports::*}
send "<##F51414>&lREPORT &f→ <##F51414>Your complaint has been sent."
play sound "entity.experience_orb.pickup" with volume 100 and pitch 1 to player
command /reports:
trigger:
open chest inventory with 6 rows named "&cReports" to player
loop size of {reports::*} times:
if {reports::%loop-value%} is set:
set slot loop-value - 1 of player's top inventory to book named "<##F51414>&lREPORT <##F51414>&l##%loop-value%" with lore "&8ᴘʟᴀʏᴇʀ ʀᴇᴘᴏʀᴛ" and "" and " <##F51414>&l▎ <##F51414>ɪɴꜰᴏʀᴍᴀᴛɪᴏɴ" and " <##F51414>&l▎ &fʀᴇᴘᴏʀᴛᴇᴅ ʙʏ: <##F51414>%player%" and " <##F51414>&l▎ &fᴘʟᴀʏᴇʀ ʀᴇᴘᴏʀᴛᴇᴅ: <##F51414>%{arg-1}%" and " <##F51414>&l▎ &fʀᴇᴀꜱᴏɴ: <##F51414>%{arg-2}%" and "" and "&8(( &7ᴄʟɪᴄᴋ ᴛᴏ ᴅᴇʟᴇᴛᴇ ))"
on inventory click:
if clicked inventory's name = "&cReports":
cancel event
set clicked slot to air
clear {reports::%clicked slot's index + 1%}
command /reportbroadcast:
trigger:
broadcast "%{reports::*}%"```
i dont though, the code adds the list to gui every time the command runs, so if the list updated, so should the gui slots
if it does, they it should sort it since the number changed from 5 to 4
i deleted slot 4
im talking about the contents of the list, changes from 5 contents to 4
not talking about the gui here mate
mb
if you have a list {numbers::*} with the contents 1, 2, 3, 4 and 5 in order and you would delete {numbers::4} the contents of the list are 1, 2, 3, <none> and 5
so {numbers::4} would be <none>
but the list doesn't show none
usage: &c/report <player> <reason>
trigger:
set {arg-1} to "%arg-1%"
set {arg-2} to "%arg-2%"
add arg-2 to {reports::*}
send "<##F51414>&lREPORT &f→ <##F51414>Your complaint has been sent."
play sound "entity.experience_orb.pickup" with volume 100 and pitch 1 to player
command /reports:
trigger:
open chest inventory with 6 rows named "&cReports" to player
loop {reports::*}:
set slot loop-counter - 1 of player's top inventory to book named "<##F51414>&lREPORT <##F51414>&l##%loop-counter%" with lore "&8ᴘʟᴀʏᴇʀ ʀᴇᴘᴏʀᴛ" and "" and " <##F51414>&l▎ <##F51414>ɪɴꜰᴏʀᴍᴀᴛɪᴏɴ" and " <##F51414>&l▎ &fʀᴇᴘᴏʀᴛᴇᴅ ʙʏ: <##F51414>%player%" and " <##F51414>&l▎ &fᴘʟᴀʏᴇʀ ʀᴇᴘᴏʀᴛᴇᴅ: <##F51414>%{arg-1}%" and " <##F51414>&l▎ &fʀᴇᴀꜱᴏɴ: <##F51414>%loop-value%" and "" and "&8(( &7ᴄʟɪᴄᴋ ᴛᴏ ᴅᴇʟᴇᴛᴇ ))"
on inventory click:
if clicked inventory's name = "&cReports":
cancel event
set clicked slot to air
clear {reports::%clicked slot's index + 1%}
command /reportbroadcast:
trigger:
broadcast "%{reports::*}%"```
this won't let you delete anything but just try it for the gui
alr ima try this
also what is setting {arg-1} and {arg-2} supposed to do?
arg-1 is the player arg-2 is the text
that means it will just be the same for every report
yes it is
lemme try
no it doesn't
but you shouldn't worry about that
try this first
alr gimme a min
what skript version do you have?
2.7.3
k
on both?
both what?
nvm
works
it reloaded
lemme see
it reloaded
but idk if it works cuz i cant delete
ik
usage: &c/report <player> <reason>
trigger:
set {arg-1} to "%arg-1%"
set {arg-2} to "%arg-2%"
add arg-2 to {reports::*}
send "<##F51414>&lREPORT &f→ <##F51414>Your complaint has been sent."
play sound "entity.experience_orb.pickup" with volume 100 and pitch 1 to player
command /reports:
trigger:
open chest inventory with 6 rows named "&cReports" to player
loop {reports::*}:
set slot (loop-counter) - 1 of player's top inventory to book named "<##F51414>&lREPORT <##F51414>&l##%loop-counter%" with lore "&8ᴘʟᴀʏᴇʀ ʀᴇᴘᴏʀᴛ" and "" and " <##F51414>&l▎ <##F51414>ɪɴꜰᴏʀᴍᴀᴛɪᴏɴ" and " <##F51414>&l▎ &fʀᴇᴘᴏʀᴛᴇᴅ ʙʏ: <##F51414>%player%" and " <##F51414>&l▎ &fᴘʟᴀʏᴇʀ ʀᴇᴘᴏʀᴛᴇᴅ: <##F51414>%{arg-1}%" and " <##F51414>&l▎ &fʀᴇᴀꜱᴏɴ: <##F51414>%loop-value%" and "" and "&8(( &7ᴄʟɪᴄᴋ ᴛᴏ ᴅᴇʟᴇᴛᴇ ))"
on inventory click:
if clicked inventory's name = "&cReports":
cancel event
set clicked slot to air
clear {reports::%clicked slot's index + 1%}
command /reportbroadcast:
trigger:
broadcast "%{reports::*}%"```
can you send a ss?
works right?
usage: &c/report <player> <reason>
trigger:
set {arg-1} to "%arg-1%"
set {arg-2} to "%arg-2%"
add arg-2 to {reports::*}
send "<##F51414>&lREPORT &f→ <##F51414>Your complaint has been sent."
play sound "entity.experience_orb.pickup" with volume 100 and pitch 1 to player
command /reports:
trigger:
open chest inventory with 6 rows named "&cReports" to player
loop {reports::*}:
set slot (loop-counter) - 1 of player's top inventory to book named "<##F51414>&lREPORT <##F51414>&l##%loop-counter%" with lore "&8ᴘʟᴀʏᴇʀ ʀᴇᴘᴏʀᴛ" and "" and " <##F51414>&l▎ <##F51414>ɪɴꜰᴏʀᴍᴀᴛɪᴏɴ" and " <##F51414>&l▎ &fʀᴇᴘᴏʀᴛᴇᴅ ʙʏ: <##F51414>%player%" and " <##F51414>&l▎ &fᴘʟᴀʏᴇʀ ʀᴇᴘᴏʀᴛᴇᴅ: <##F51414>%{arg-1}%" and " <##F51414>&l▎ &fʀᴇᴀꜱᴏɴ: <##F51414>%loop-value%" and "" and "&8(( &7ᴄʟɪᴄᴋ ᴛᴏ ᴅᴇʟᴇᴛᴇ ))"
on inventory click:
if clicked inventory's name = "&cReports":
cancel event
set clicked slot to air
loop {reports::*}:
if loop-counter = clicked slot's index + 1:
clear {reports::%loop-index%}
broadcast loop-index
command /reportbroadcast:
trigger:
broadcast "%{reports::*}%"```
edit
edit
edit
yeah that's the problem
wait why don't you just copy it?
no they were right
good
usage: &c/report <player> <reason>
trigger:
add arg-2 to {reports::*}
set {reports::%size of {reports::*}%::1} to arg-1
set {reports::%size of {reports::*}%::1} to player
send "<##F51414>&lREPORT &f→ <##F51414>Your complaint has been sent."
play sound "entity.experience_orb.pickup" with volume 100 and pitch 1 to player
command /reports:
trigger:
open chest inventory with 6 rows named "&cReports" to player
loop {reports::*}:
set slot (loop-counter) - 1 of player's top inventory to book named "<##F51414>&lREPORT <##F51414>&l##%loop-counter%" with lore "&8ᴘʟᴀʏᴇʀ ʀᴇᴘᴏʀᴛ" and "" and " <##F51414>&l▎ <##F51414>ɪɴꜰᴏʀᴍᴀᴛɪᴏɴ" and " <##F51414>&l▎ &fʀᴇᴘᴏʀᴛᴇᴅ ʙʏ: <##F51414>%{reports::%loop-index%::2}%" and " <##F51414>&l▎ &fᴘʟᴀʏᴇʀ ʀᴇᴘᴏʀᴛᴇᴅ: <##F51414>%{reports::%loop-index%::1}%" and " <##F51414>&l▎ &fʀᴇᴀꜱᴏɴ: <##F51414>%loop-value%" and "" and "&8(( &7ᴄʟɪᴄᴋ ᴛᴏ ᴅᴇʟᴇᴛᴇ ))"
on inventory click:
if clicked inventory's name = "&cReports":
cancel event
set clicked slot to air
loop {reports::*}:
if loop-counter = clicked slot's index + 1:
clear {reports::%loop-index%}
command /reportbroadcast:
trigger:
broadcast "%{reports::*}%"```
alr
1 sec
player reported <none>
try this
im having a issue
you should try it with some more people later to guarantee that it works
so the last one doesn't delete?
tf
i dont think so
I gtg so I can't help rn
I fixed the "reported by" thing
I hope so, I'm pretty busy
my theory is that ur deleting contents from the list so its showing none
but because you deleted it it shouldn't show
can you send it?
.
k
usage: &c/report <player> <reason>
trigger:
add arg-2 to {reports::*}
set {reports::%size of {reports::*}%::1} to arg-1
set {reports::%size of {reports::*}%::1} to player
send "<##F51414>&lREPORT &f→ <##F51414>Your complaint has been sent."
play sound "entity.experience_orb.pickup" with volume 100 and pitch 1 to player
command /reports:
permission: report.reports
trigger:
open chest inventory with 6 rows named "&cReports" to player
loop {reports::*}:
set slot (loop-counter) - 1 of player's top inventory to book named "<##F51414>&lREPORT <##F51414>&l##%loop-counter%" with lore "&8ᴘʟᴀʏᴇʀ ʀᴇᴘᴏʀᴛ" and "" and " <##F51414>&l▎ <##F51414>ɪɴꜰᴏʀᴍᴀᴛɪᴏɴ" and " <##F51414>&l▎ &fʀᴇᴘᴏʀᴛᴇᴅ ʙʏ: <##F51414>%{reports::%loop-index%::2}%" and " <##F51414>&l▎ &fᴘʟᴀʏᴇʀ ʀᴇᴘᴏʀᴛᴇᴅ: <##F51414>%{reports::%loop-index%::1}%" and " <##F51414>&l▎ &fʀᴇᴀꜱᴏɴ: <##F51414>%loop-value%" and "" and "&8(( &7ᴄʟɪᴄᴋ ᴛᴏ ᴅᴇʟᴇᴛᴇ ))"
on inventory click:
if clicked inventory's name = "&cReports":
cancel event
set clicked slot to air
loop {reports::*}:
if loop-counter = clicked slot's index + 1:
clear {reports::%loop-index%}
command /reportbroadcast:
trigger:
broadcast "%{reports::*}%"```
It removes properly, just close and reopen the GUI window
usage: &c/report <player> <reason>
trigger:
add arg-2 to {reports::*}
set {reports::%size of {reports::*}%::1} to arg-1
set {reports::%size of {reports::*}%::2} to player
send "<##F51414>&lREPORT &f→ <##F51414>Your complaint has been sent."
play sound "entity.experience_orb.pickup" with volume 100 and pitch 1 to player
command /reports:
permission: report.reports
trigger:
openReports(player)
on inventory click:
if clicked inventory's name = "&cReports":
cancel event
set clicked slot to air
loop {reports::*}:
if loop-counter = clicked slot's index + 1:
clear {reports::%loop-index%}
close player's inventory
openReports(player)
function openReports(p: player):
open chest inventory with 6 rows named "&cReports" to {_p}
loop {reports::*}:
set slot (loop-counter) - 1 of {_p}'s top inventory to book named "<##F51414>&lREPORT <##F51414>&l##%loop-counter%" with lore "&8ᴘʟᴀʏᴇʀ ʀᴇᴘᴏʀᴛ" and "" and " <##F51414>&l▎ <##F51414>ɪɴꜰᴏʀᴍᴀᴛɪᴏɴ" and " <##F51414>&l▎ &fʀᴇᴘᴏʀᴛᴇᴅ ʙʏ: <##F51414>%{reports::%loop-counter%::2}%" and " <##F51414>&l▎ &fᴘʟᴀʏᴇʀ ʀᴇᴘᴏʀᴛᴇᴅ: <##F51414>%{reports::%loop-counter%::1}%" and " <##F51414>&l▎ &fʀᴇᴀꜱᴏɴ: <##F51414>%loop-value%" and "" and "&8(( &7ᴄʟɪᴄᴋ ᴛᴏ ᴅᴇʟᴇᴛᴇ ))"
command /reportbroadcast:
trigger:
broadcast "%{reports::*}%"```
Simple fix
oh I also see that I didn't change the {reports::...::1} to {reports::....::2}
I added a function to the current code, which makes it easier to use as well
ah, forgot something, gotta pass the player reported arg, one second
Fixed the code above.
Should work properly
Yes, the code provided here #1222601074351804516 message should work as you want
Why can't I use a plugin? understand, you are not optimizing the script as a plugin
Whatcha mean?
why make a script if there is a plugin
Because people want customizeable stuff that sometimes isn't available to do in a plugin
And then you got people like me that just want to make plugins in skript
because we can
but there is a difference between plugins and scripts, you can make the same world edit in a script, but you don’t optimize it in any way as in a plugin
You're right, but sometimes plugins have a bunch of convoluted features that are unneeded. You can make something quick and simple in skript without all the unnecessary shit