EOSERV Forum > EOSERV > NPC Spells
Page: << 1 >>
NPC Spells
Author Message
Post #201831 NPC Spells

This is just a very basic small bit of code I added into my rev as a way to stop players autoing with pets back when I first made my first pet code. But due to upgrades I was able to enhance it quite a bit. Here's the code at it's simpliest tho, I'm sure can edit it to your liking!

Edited the code; should work on a vanilla rev now, if you get any errors post or pm me and I'll edit it!

Code

The txt is messy so you will need to switch on and read it. But I didn't want to paste it all on here and make a mess.. Hope you guys find it useful!

7 years, 20 weeks ago
Post #201832 Re: NPC Spells

So adding this in would allow me to to do what sausage did and let the npcs use spells? Like bosses using spells against players?

7 years, 20 weeks ago
Post #201834 Re: NPC Spells

If I remember correctly DeathRespawn(); in the character::Damage() function is custom??


"Reminds me" Did you ever see my poionous npc code?

7 years, 20 weeks ago
Post #201837 Re: NPC Spells
insomniac posted: (16th Dec 2016, 10:56 pm)

If I remember correctly DeathRespawn(); in the character::Damage() function is custom??


"Reminds me" Did you ever see my poionous npc code?


I believe there is a few custom functions in there which are just for ease, I think recover was another custom aha.. I'll re upload it fit for a vanilla trunk tho it might be a bit messy with the packers in there!

I've actually been playing with poison npcs and ended up doing it using buffs, maybe I'll post that too if it's something people want!


@arglon: nah this just makes the npc skip a walk and cast the spell instead, it was so players couldn't use pets to auto by hiding behind npc walls.. I've just noticed aswell you'll need to add the npc speech fix insomniac mentioned in the bugs section!

Once I get back on my laptop I'll post an update to it!

7 years, 19 weeks ago
Post #201844 Re: NPC Spells

This code won't work out of box without fixing a few things. Also, it is a very basic configuration that lacks flexibility. My recommendation is to clean up the mistakes and make sure function calls match as well as remove non-existent and unnecessary calls. Oh and consider NPC attack modes and spell types as well. Might even be worth giving NPCs their own TP reserves as well. 

7 years, 19 weeks ago
Post #201846 Re: NPC Spells
Apollo posted: (17th Dec 2016, 06:15 pm)

This code won't work out of box without fixing a few things. Also, it is a very basic configuration that lacks flexibility. My recommendation is to clean up the mistakes and make sure function calls match as well as remove non-existent and unnecessary calls. Oh and consider NPC attack modes and spell types as well. Might even be worth giving NPCs their own TP reserves as well. 

Yeah, I'm home now so I'll be able to post it vanilla. Like I said above, the code was really a cheap fix to stop players using pets to auto, but I recently changed the pets so I decided to revamp the spells too. Just thought I'd post this as It did the job for me and maybe others can find a use for it somewhere.

7 years, 19 weeks ago
Page: << 1 >>

EOSERV Forum > EOSERV > NPC Spells