EQEmulator Forums

EQEmulator Forums (https://www.eqemulator.org/forums/index.php)
-   Support::Windows Servers (https://www.eqemulator.org/forums/forumdisplay.php?f=587)
-   -   Changing NPC Stats In One Zone (https://www.eqemulator.org/forums/showthread.php?t=39676)

Aquaojo 05-18-2015 07:29 PM

Changing NPC Stats In One Zone
 
First off...Thanks to everyone in this community for the immense freaking wealth of knowledge in these boards!! I'm new to all this, but y'all have made it pretty simple!!

I've searched for this, but couldn't find anything...I'm looking to make some changes to the mobs in one particular zone. For instance: Lowering the HP of all NPC's in Crushbone.

I know how to do it for NPC's across the board, but can't seem to figure out how to identify the mobs by the zone they are in. So far I have done this by using the faction row in the NPC_TYPES table, but I'm sure there is a more thorough way...Just missing it I guess.

Any help greatly appreciated!!

epilz 05-18-2015 07:34 PM

SELECT * FROM `spawn2` WHERE `zone` LIKE '%crushbone%' LIMIT 0, 1000

epilz 05-18-2015 07:43 PM

lots of way to change shit, what exactly do you want to change?

Aquaojo 05-18-2015 08:14 PM

Thanks Epilz - I'm just looking to make some changes to mobs in Kael...Taking the HP down by 25%, AC by 25%, Min/Max Dmg by 25% for starters.

I know I can do it in EoC using the mass field editor, but that sets everything to the same value. I figure I can use SQL and do it all by percentages.

epilz 05-18-2015 08:29 PM

its much easier to use SQL to do it, give a few, I will build you a query for it

Aquaojo 05-19-2015 10:30 AM

So far I have figured out how to pull the mobs from Kael using this query:

SELECT * FROM spawn2 JOIN spawngroup ON spawngroup.id = spawn2.spawngroupID
JOIN spawnentry ON spawngroup.id = spawnentry.spawngroupID
JOIN npc_types ON spawnentry.npcID = npc_types.id
WHERE spawn2.zone LIKE 'kael'

Admittedly I am just learning about JOIN and figuring out how all this works...So anyone able to tell me how I would now add in:

UPDATE npc_types SET HP = HP * 0.75

in order to decrease all NPC HP in Kael by 25%??

I know it has to be right in front of my face, but I am missing it for some reason...

Thanks everyone!!

NatedogEZ 05-19-2015 11:12 AM

lower HP and AC by 25% in crushbone version 0


Code:

UPDATE npc_types n
INNER JOIN spawnentry se ON n.id = se.npcID
INNER JOIN spawngroup sg ON sg.id = se.spawngroupID
INNER JOIN spawn2 s ON se.spawngroupID = s.spawngroupID
SET
n.`hp` = `hp` * 0.75,
n.`ac` = `ac` * 0.75
WHERE s.zone = 'crushbone'
and s.version = 0;


kimura 05-19-2015 11:15 AM

I am sure there is an easier way but I simply use the ID number range for the zone... kael's mobs are 113000..113552

so..

Update npc_types Set hp=hp*.75 where id between 113000 and 113552;

etc...

kimura 05-19-2015 11:16 AM

well, natedog posted at the same time as me and he knows a lot more than me so...go with him :P

Aquaojo 05-19-2015 11:29 AM

Awesome!! Thanks to all of you guys!! I'm amazed at the wealth of knowledge everyone here has.

NatedogEZ 05-19-2015 12:06 PM

The way Kimura said is 100% better BUT.. only works if you create NPCs in the correct zoneID range..

Exmaple.. zoneID 3 (QRG) or surefall glades... has NPCs from id 3000 - 3999

And the way I posted will miss mobs that are quest spawned.. ect since they are not part of a spawngroup.


All times are GMT -4. The time now is 08:37 PM.

Powered by vBulletin®, Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.