dmustanger
New Member
INSERT IGNORE INTO NEWDATABASE.object_classes (Classname, Chance, MaxNum, Damage)Anyone got a SQL command to import the vehicle from REALITY to hives shema?
Can't figure it out. I just want the spawn, don't care of the actual vehicles on the server.
Indepth!
SELECT class_name, 0.50, limit_max, 0.05000 FROM vehicle
INSERT IGNORE INTO NEWDATABASE.object_spawns (Classname, Worldspace, Inventory, Hitpoints)
SELECT vehicle.class_name, worldspace, vehicle.inventory, vehicle.parts FROM world_vehicle inner join vehicle on world_vehicle.vehicle_id = vehicle.id
May want to run these 2 before if you dont want any of the orginal spawn points
TRUNCATE TABLE `object_classes`
TRUNCATE TABLE `object_spawns`
if you run the above truncate query run this also to readd the deployables
INSERT IGNORE INTO NEWDATABASE.object_classes (Classname, Chance, MaxNum, Damage) Values
("BearTrap_DZ", 0, 0, 0),
("CamoNet_DZ", 0, 0, 0),
("DomeTentStorage", 0, 0, 0),
("Hedgehog_DZ", 0, 0, 0),
("Sandbag1_DZ", 0, 0, 0),
("StashMedium", 0, 0, 0),
("StashSmall", 0, 0, 0),
("TentStorage", 0, 0, 0),
("TrapBearTrapFlare", 0, 0, 0),
("TrapBearTrapSmoke", 0, 0, 0),
("TrapTripwireFlare", 0, 0, 0),
("TrapTripwireGrenade", 0, 0, 0),
("TrapTripwireSmoke", 0, 0, 0),
("Trap_Cans", 0, 0, 0),
("Wire_cat1", 0, 0, 0);
This one will transfer the deployables
INSERT IGNORE INTO NEWDATABASE.object_data (ObjectUID, Instance, Classname, Datestamp, CharacterID, Worldspace, Inventory, Hitpoints, Fuel, Damage)
SELECT unique_id, instance_id, deployable.class_name, created, '0', worldspace, inventory, '[]', '0', '0' FROM instance_deployable inner join deployable on instance_deployable.deployable_id = deployable.id