mirror of
https://git.krews.org/morningstar/Arcturus-Community.git
synced 2024-11-26 16:30:52 +01:00
Merge branch 'fix-mannequin' into 'dev'
Fix mannequin name See merge request morningstar/Arcturus-Community!539
This commit is contained in:
commit
7e2beb83ce
@ -85,3 +85,6 @@ INSERT INTO `emulator_texts` (`key`, `value`) VALUES ('commands.success.cmd_upda
|
|||||||
|
|
||||||
-- add moodlight configuration
|
-- add moodlight configuration
|
||||||
INSERT INTO `emulator_settings` (`key`, `value`) VALUES ('moodlight.color_check.enabled', '1');
|
INSERT INTO `emulator_settings` (`key`, `value`) VALUES ('moodlight.color_check.enabled', '1');
|
||||||
|
|
||||||
|
-- Mannequin name
|
||||||
|
INSERT INTO `emulator_texts` (`key`, `value`) VALUES ('hotel.mannequin.name.default', 'My look');
|
@ -18,6 +18,11 @@ public class MannequinSaveNameEvent extends MessageHandler {
|
|||||||
|
|
||||||
String[] data = item.getExtradata().split(":");
|
String[] data = item.getExtradata().split(":");
|
||||||
String name = this.packet.readString();
|
String name = this.packet.readString();
|
||||||
|
|
||||||
|
if (name.length() < 3 || name.length() > 15) {
|
||||||
|
name = Emulator.getTexts().getValue("hotel.mannequin.name.default", "My look");
|
||||||
|
}
|
||||||
|
|
||||||
if (data.length == 3) {
|
if (data.length == 3) {
|
||||||
item.setExtradata(this.client.getHabbo().getHabboInfo().getGender().name().toUpperCase() + ":" + data[1] + ":" + name);
|
item.setExtradata(this.client.getHabbo().getHabboInfo().getGender().name().toUpperCase() + ":" + data[1] + ":" + name);
|
||||||
} else {
|
} else {
|
||||||
|
Loading…
Reference in New Issue
Block a user