mirror of
https://github.com/2006-Scape/apollo.git
synced 2026-07-03 00:38:21 +00:00
12 lines
427 B
Ruby
12 lines
427 B
Ruby
require 'java'
|
|
|
|
java_import 'org.apollo.game.model.setting.PrivacyState'
|
|
java_import 'org.apollo.game.message.impl.SendFriendMessage'
|
|
|
|
on :message, :privacy_option do |ctx, player, message|
|
|
player.chat_privacy = message.chat_privacy
|
|
player.friend_privacy = message.friend_privacy
|
|
player.trade_privacy = message.trade_privacy
|
|
|
|
update_friends(player, message.friend_privacy == PrivacyState::OFF ? 0 : player.world_id)
|
|
end |