Files
helpop.sk
Code
1 324
helpop.sk
# ═══════════════════════════════════════════════════════════
# HelpOpGUI - Advanced Player Reporting System
# Version: 1.0
# Author: Generated
# ═══════════════════════════════════════════════════════════
options:
prefix: &6&l[&e&lHelpOp&6&l]&r
admin-permission: helpop.admin
use-permission: helpop.use
# GUI Settings
main-gui-title: &6&lReport a Player
admin-gui-title: &c&lManage Reports
# Messages
no-permission: &cYou don't have permission to use this!
report-sent: &aYour report has been sent to online staff!
no-online-staff: &cNo staff members are currently online!
report-closed: &aReport has been closed!
# Colors
color-cheating: &c
color-toxicity: &6
color-griefing: &4
color-bug: &e
color-other: &b
# ═══════════════════════════════════════════════════════════
# VARIABLES
# ═══════════════════════════════════════════════════════════
# {reports::*} - List of all active reports
# {report::%id%::reporter} - Who reported
# {report::%id%::reported} - Who was reported
# {report::%id%::reason} - Report reason
# {report::%id%::category} - Report category
# {report::%id%::time} - When reported
# {report::%id%::server} - Server location
# {report.id} - Current report ID counter
on load:
if {report.id} is not set:
set {report.id} to 0
send "{@prefix} &aHelpOpGUI loaded successfully!" to console
send "&7- Main command: /report or /helpop" to console
send "&7- Admin command: /reports" to console
# ═══════════════════════════════════════════════════════════
# MAIN REPORT COMMAND
# ═══════════════════════════════════════════════════════════
command /report [<offline player>]:
aliases: /helpop
permission: {@use-permission}
permission message: {@no-permission}
trigger:
if arg-1 is set:
set {_target} to arg-1
if {_target} is player:
send "{@prefix} &cYou cannot report yourself!" to player
stop
open_report_gui(player, {_target})
else:
open_player_selection_gui(player)
command /reports [<text>]:
permission: {@admin-permission}
permission message: {@no-permission}
trigger:
if arg-1 is "clear":
clear {reports::*}
loop all players:
clear {report::%loop-player%::*}
send "{@prefix} &aAll reports have been cleared!" to player
stop
open_admin_reports_gui(player)
# ═══════════════════════════════════════════════════════════
# PLAYER SELECTION GUI
# ═══════════════════════════════════════════════════════════
function open_player_selection_gui(p: player):
open chest with 6 rows named "{@main-gui-title} &7- Select Player" to {_p}
# Decorative borders
loop 54 times:
if loop-number <= 9:
format slot (loop-number - 1) of {_p}'s current inventory with light gray stained glass pane named "&7" to be unstealable
else if loop-number >= 46:
format slot (loop-number - 1) of {_p}'s current inventory with light gray stained glass pane named "&7" to be unstealable
# Add online players
set {_slot} to 10
loop all players:
if loop-player is not {_p}:
if {_slot} < 44:
set {_lore::*} to "&7Click to report this player", "", "&eOnline", "&7Right now"
format slot {_slot} of {_p}'s current inventory with loop-player's skull named "&e%loop-player%" with lore {_lore::*} to close then run [make {_p} execute "/report %loop-player%"]
add 1 to {_slot}
# Go back button
format slot 49 of {_p}'s current inventory with barrier named "&cClose" to close
# ═══════════════════════════════════════════════════════════
# MAIN REPORT GUI (CATEGORY SELECTION)
# ═══════════════════════════════════════════════════════════
function open_report_gui(p: player, target: offline player):
set {report.temp::%{_p}%::target} to {_target}
open chest with 6 rows named "{@main-gui-title}" to {_p}
# Decorative borders with colored glass
loop 54 times:
if loop-number <= 9 or loop-number >= 46:
format slot (loop-number - 1) of {_p}'s current inventory with black stained glass pane named "&7" to be unstealable
else if mod(loop-number, 9) = 1 or mod(loop-number, 9) = 0:
format slot (loop-number - 1) of {_p}'s current inventory with black stained glass pane named "&7" to be unstealable
# Target player info
set {_target.lore::*} to "", "&7You are reporting:", "&e%{_target}%", "", "&7Select a category below"
format slot 4 of {_p}'s current inventory with {_target}'s skull named "&6&lReporting: &e%{_target}%" with lore {_target.lore::*} to be unstealable
# Category: Cheating
set {_cheating.lore::*} to "", "&7Report for:", "&fX-Ray, Fly, Kill Aura", "&fSpeed, Reach, etc.", "", "&eClick to select"
format slot 20 of {_p}'s current inventory with red wool named "{@color-cheating}&l⚠ Cheating / Hacking" with lore {_cheating.lore::*} to close then run [handle_report({_p}, {_target}, "Cheating")]
# Category: Toxic Behavior
set {_toxic.lore::*} to "", "&7Report for:", "&fRude behavior, Harassment", "&fHate speech, Bullying", "", "&eClick to select"
format slot 22 of {_p}'s current inventory with orange wool named "{@color-toxicity}&l💬 Toxic Behavior" with lore {_toxic.lore::*} to close then run [handle_report({_p}, {_target}, "Toxic Behavior")]
# Category: Griefing
set {_grief.lore::*} to "", "&7Report for:", "&fDestroying builds", "&fStealing, Raiding", "", "&eClick to select"
format slot 24 of {_p}'s current inventory with dark red wool named "{@color-griefing}&l🔥 Griefing / Stealing" with lore {_grief.lore::*} to close then run [handle_report({_p}, {_target}, "Griefing")]
# Category: Bug Abuse
set {_bug.lore::*} to "", "&7Report for:", "&fExploiting bugs", "&fDuplication glitches", "", "&eClick to select"
format slot 30 of {_p}'s current inventory with yellow wool named "{@color-bug}&l⚙ Bug Abuse" with lore {_bug.lore::*} to close then run [handle_report({_p}, {_target}, "Bug Abuse")]
# Category: Other
set {_other.lore::*} to "", "&7Report for:", "&fAnything else not", "&flisted above", "", "&eClick to select"
format slot 32 of {_p}'s current inventory with cyan wool named "{@color-other}&l📋 Other Reason" with lore {_other.lore::*} to close then run [handle_report({_p}, {_target}, "Other")]
# Info item
set {_info.lore::*} to "", "&7Reports are reviewed by staff", "&7False reports may result in", "&7punishment for the reporter", "", "&6Thank you for helping", "&6keep our server safe!"
format slot 49 of {_p}'s current inventory with book named "&b&lℹ Information" with lore {_info.lore::*} to be unstealable
# Cancel button
format slot 45 of {_p}'s current inventory with barrier named "&c&l✖ Cancel" to close
# Decoration items
format slot 19 of {_p}'s current inventory with red stained glass pane named " " to be unstealable
format slot 21 of {_p}'s current inventory with orange stained glass pane named " " to be unstealable
format slot 23 of {_p}'s current inventory with orange stained glass pane named " " to be unstealable
format slot 25 of {_p}'s current inventory with dark red stained glass pane named " " to be unstealable
format slot 29 of {_p}'s current inventory with yellow stained glass pane named " " to be unstealable
format slot 31 of {_p}'s current inventory with yellow stained glass pane named " " to be unstealable
format slot 33 of {_p}'s current inventory with cyan stained glass pane named " " to be unstealable
# ═══════════════════════════════════════════════════════════
# REPORT HANDLING
# ═══════════════════════════════════════════════════════════
function handle_report(reporter: player, reported: offline player, category: text):
add 1 to {report.id}
set {_id} to {report.id}
# Store report data
set {report::%{_id}%::reporter} to {_reporter}
set {report::%{_id}%::reported} to {_reported}
set {report::%{_id}%::category} to {_category}
set {report::%{_id}%::time} to now
set {report::%{_id}%::status} to "open"
add {_id} to {reports::*}
# Send confirmation to reporter
send "{@prefix} {@report-sent}" to {_reporter}
send "&7Report ID: &e#%{_id}%" to {_reporter}
send "&7Player: &e%{_reported}%" to {_reporter}
send "&7Category: &e%{_category}%" to {_reporter}
# Play sound
play sound "entity.experience_orb.pickup" with volume 1 and pitch 1.5 to {_reporter}
# Notify all online staff
set {_staffNotified} to false
loop all players:
if loop-player has permission "{@admin-permission}":
send "" to loop-player
send "{@prefix} &c&l⚠ NEW REPORT RECEIVED!" to loop-player
send "&7━━━━━━━━━━━━━━━━━━━━━━━━━━" to loop-player
send "&eReport ID: &f#%{_id}%" to loop-player
send "&eReporter: &f%{_reporter}%" to loop-player
send "&eReported: &f%{_reported}%" to loop-player
send "&eCategory: &f%{_category}%" to loop-player
send "&eTime: &f%now%" to loop-player
send "&7━━━━━━━━━━━━━━━━━━━━━━━━━━" to loop-player
send "&7Use &e/reports &7to manage reports" to loop-player
send "" to loop-player
play sound "block.note_block.pling" with volume 1 and pitch 2 to loop-player