jimbox114
06-13-2008, 01:46 AM
I tried to search but couldn't really find a straight answer for this. I have a server up and running with the PEQ DB. Everything seems to be running good, however I am more interested in making a custom content server.
I would like to keep things like the items database, factions, doors, etc. I just want to remove every single spawn so that I can make my own. I figure its probably just a simple mysql command but I am not sure what it would be? I am not very knowledgeable on how to use mysql, any ideas what I would need to type just to remove all the spawns?
ChaosSlayer
06-13-2008, 02:15 AM
my BEST advise is to get George tool for spawn tables control.
however if just want to wipe everything clean and promise you won't have any regrets, you need to wipe off 3 separate DB tables:
spawngroup
spawn2
spawnentry
other related tables are those contianing pathing grids:
grid
gridentries
I do not remeber sql delete command (i rarely use them) - but if you using anything like mySQL query browser - you simply open those tables, highlite evrything, and click DELETE =)
I am sure our sql experts can help you with direct sql command
BUT what you can do you DROP the table complitly and recreate as blank:
for exmaple: (peqz - the Db name, and grid_entries - is the table you wish to wipe, and rest tables below)
DROP TABLE IF EXISTS `peqz`.`grid_entries`;
CREATE TABLE `peqz`.`grid_entries` (
`gridid` int(10) NOT NULL default '0',
`zoneid` int(10) NOT NULL default '0',
`number` int(10) NOT NULL default '0',
`x` float NOT NULL default '0',
`y` float NOT NULL default '0',
`z` float NOT NULL default '0',
`heading` float NOT NULL default '0',
`pause` int(10) NOT NULL default '0',
PRIMARY KEY (`zoneid`,`gridid`,`number`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
DROP TABLE IF EXISTS `peqz`.`grid`;
CREATE TABLE `peqz`.`grid` (
`id` int(10) NOT NULL default '0',
`zoneid` int(10) NOT NULL default '0',
`type` int(10) NOT NULL default '0',
`type2` int(10) NOT NULL default '0',
PRIMARY KEY (`zoneid`,`id`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
DROP TABLE IF EXISTS `peqz`.`spawn2`;
CREATE TABLE `peqz`.`spawn2` (
`id` int(11) NOT NULL auto_increment,
`spawngroupID` int(11) NOT NULL default '0',
`zone` varchar(16) NOT NULL default '',
`x` float(14,6) NOT NULL default '0.000000',
`y` float(14,6) NOT NULL default '0.000000',
`z` float(14,6) NOT NULL default '0.000000',
`heading` float(14,6) NOT NULL default '0.000000',
`respawntime` int(11) NOT NULL default '0',
`variance` smallint(4) NOT NULL default '0',
`pathgrid` int(10) NOT NULL default '0',
`timeleft` bigint(16) NOT NULL default '0',
`_condition` mediumint(8) unsigned NOT NULL default '0',
`cond_value` mediumint(9) NOT NULL default '1',
PRIMARY KEY (`id`),
KEY `ZoneGroup` (`zone`,`spawngroupID`)
) ENGINE=InnoDB DEFAULT CHARSET=latin1;
DROP TABLE IF EXISTS `peqz`.`spawnentry`;
CREATE TABLE `peqz`.`spawnentry` (
`spawngroupID` int(11) NOT NULL default '0',
`npcID` int(11) NOT NULL default '0',
`chance` smallint(4) NOT NULL default '0',
PRIMARY KEY (`spawngroupID`,`npcID`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
DROP TABLE IF EXISTS `peqz`.`spawngroup`;
CREATE TABLE `peqz`.`spawngroup` (
`id` int(11) NOT NULL auto_increment,
`name` varchar(30) NOT NULL default '',
`spawn_limit` tinyint(4) NOT NULL default '0',
PRIMARY KEY (`id`),
UNIQUE KEY `name` (`name`)
) ENGINE=MyISAM AUTO_INCREMENT=33590155 DEFAULT CHARSET=latin1;
NOTE: THIS IS UN-REVERSEABLE. screw up at your own risk =)
again - the drop way a bit too complex for such simple goal, but i simply do not remeber how to delete - anyone? =)
nosfentora
06-13-2008, 08:25 AM
I think it's just
DELETE FROM <tablename>
if i'm not mistaken.
vBulletin® v3.8.11, Copyright ©2000-2025, vBulletin Solutions Inc.