[PlusEmu FIX]Public_Items doesn't have a default value[FIX]

Jan 7, 2016
194
15
(Warning: if you already have rooms made with floor plan editor, this will delete any black screened rooms and I've been searching for ages for this answer.)So for some of you who use *****'s PlusEMU and get this error on emulator, open up your database,
Copy the whole code below
Code:
-- Table structure for `room_models`
-- ----------------------------
DROP TABLE IF EXISTS `room_models`;
CREATE TABLE `room_models` (
  `id` varchar(100) NOT NULL,
  `door_x` int(11) NOT NULL,
  `door_y` int(11) NOT NULL,
  `door_z` double NOT NULL,
  `door_dir` int(4) NOT NULL DEFAULT '2',
  `heightmap` text NOT NULL,
  `public_items` VARCHAR(50) NOT NULL DEFAULT '0',
  `club_only` enum('0','1') NOT NULL DEFAULT '0',
  `poolmap` varchar(100) NOT NULL DEFAULT '',
  `custom` enum('0','1') NOT NULL DEFAULT '0',
  `wall_height` int(11) NOT NULL DEFAULT '-1',
  PRIMARY KEY (`id`),
  UNIQUE KEY `id` (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=latin1;
After you paste this in, take room_models from your original SQL file and paste it in(in short, do not copy above from your database.sql FILE, this WILL mess it up again, only do the actual values.
Open up HeidiSQL(For MariaDB users), login with your root/password, open up your database, and open up room_models, then click on Tab: room_models, basic and change TEXT on public_items to VARCHAR and then put 0 as the default.
Bottom below and code is for fresh starters using another method, if you are using xampp/phpmyadmin, same applies, copy code, do a query(Save as a db.sql file then upload into database).
Remember, this will overwrite your current room_models, if you are fresh starting and a noob and couldn't find this, hope this helps anybody else with the problem!
Warning: You will have to manually remove your rooms from the database itself, they cannot be used and/or fixed. Any editing before doing the above will not fix the rooms already saved with floor plan but will make sure they work next time upon creation.
 
Jan 7, 2016
194
15
if your hotel has a lot of rooms, this will not give you errors on making rooms. This will fix the emulator error and black screen after using the floor plan
 

MasterJiq

Member
Jul 8, 2016
385
23
Yes, some of users using floor plan editor on their room have this problem. So if I ran this SQL, do the room_model has been cleared ?
 

MasterJiq

Member
Jul 8, 2016
385
23
OK Thanks ! @FluffyGreenArrow
 
So for someone just to change the public items just ran:
Code:
ALTER TABLE `room_models` CHANGE `public_items` `public_items` VARCHAR(50) CHARACTER SET latin1 COLLATE latin1_swedish_ci NULL DEFAULT '0';
I don't take any credits!
 
I meant
Code:
ALTER TABLE `room_models` CHANGE `public_items` `public_items` VARCHAR(50) CHARACTER SET latin1 COLLATE latin1_swedish_ci NOT NULL DEFAULT '0';
 

Users who are viewing this thread

Top