Creating NPCs the new way

Get Help on scripting in POL with configurations, config setups, script trouble shooting, etc.
Post Reply
bodom
Former Developer
Posts: 140
Joined: Sat Feb 21, 2015 7:52 pm

Creating NPCs the new way

Post by bodom »

Hi there,

back in the old POL093 times, I was used to follow this long procedure for creating a new NPC, let's a say a skeleton:
1. Create the entry in npcdesc.cfg
2. Create the armor and the weapon entries in itemdesc.cfg
3. Create the equipment entry in equip.cfg

The AI will then call EquipFromTemplate() and my skeleton will get an "invisible" armor and weapon.

I am now using POL098 and trying to accomplish the same using the new npcdesc.cfg attributes. What i do is adding the following to npcdesc.cfg:

Code: Select all

	// Armor and Weapon
	AR               5
	AttackDelay      30
	AttackDamage     2d7
	AttackAttribute  Swords
	AttackHitSound   0x1C6
	AttackMissSound  0x239
	AttackHitScript  :combat:mainhit
	AttackMinRange   0
	AttackMaxRange   0
	AttackAnimation  0
	MaxHp            100
what then happens is... nothing! My skeleton is unarmed and naked.

This is driving me crazy... i am obviously missing something, but i can't figure out what. Could you please point me to the right direction?

Thank you!
bodom
Former Developer
Posts: 140
Joined: Sat Feb 21, 2015 7:52 pm

Re: Creating NPCs the new way

Post by bodom »

I think i've found the problem: one MUST define AttackSpeed for the intrinsic weapon even if the doc doesn't say it.
Post Reply