Jump to content


Gandalf17

Member Since 03 Dec 2010
Offline Last Active Feb 27 2012 09:28 PM

Posts I've Made

In Topic: Gandalf's coding questions

17 March 2011 - 07:18 PM

I'm having trouble with my Mazgul Morgul Blade ability. The instant I trigger the ability in game, the game crashes. As far as i can tell, I dont see any error in my coding. But I'm probably missing something. Codes are below:

Nazgul.ini
;;; MORGUL BLADE ;;;
	Behavior = SpecialPowerModule ModuleTag_MorgulBladeStarter                      
		SpecialPowerTemplate		= SpecialAbilityNazgulMorgulBladeAttack
		UpdateModuleStartsAttack	= Yes
		StartsPaused			= No
		TriggerFX			= FX_GothmogSwordFlash
		;InitiateSound			= GandalfVoiceAttackWizardBlast	;this plays when he targets, not when he fires
	End

	Behavior = WeaponFireSpecialAbilityUpdate ModuleTag_MorgulBladeWeaponFireUpdate
		SpecialPowerTemplate    = SpecialAbilityNazgulMorgulBladeAttack
		WhichSpecialWeapon		= 2
		SkipContinue			= Yes

		UnpackTime              = 50
		PreparationTime         = 1   
		PersistentPrepTime      = 1500 
		PackTime                = 1100 

		AwardXPForTriggering    = 0		
		StartAbilityRange		= 19.0
		MustFinishAbility		= Yes
		SpecialWeapon			= NazgulMorgulBladeAttack							End
	End

Weapon.ini
;-------------------------------------------------------------------------------
Weapon NazgulMorgulBladeAttack     ; Poison targeted enemy until death
	LeechRangeWeapon      = Yes
	AttackRange           = 20.0
	MeleeWeapon           = Yes
	DelayBetweenShots     = WITCHKING_DELAYBETWEENSHOTS 	; time between shots, msec
	PreAttackDelay        = WITCHKING_SWORD_PREATTACKDELAY 	; 300 is mace swing delay time before contact with target.
	PreAttackType         = PER_SHOT ; Do the delay each time we attack
	FireFX                = FX_GondorSwordHit
	FiringDuration        = WITCHKING_FIRINGDURATION 	; Duration of the mace swing 

	DamageNugget                        ; A basic Nugget that just does damage
		Damage        = 200 ;WITCHKING_DAMAGE				
		Radius        = 0.0
		DelayTime     = 0
		DamageType    = SLASH
		;DamageFXType  = NONE
		DeathType     = NORMAL
		DamageScalar  = 10% NONE +RohanEowyn
	End
	DamageFieldNugget                   ; A Nugget that lays down an area of damage that persists independantly
    		WeaponTemplateName = PersistingMorgulBladeWeapon  
    		Duration = 30000                            
  	End
End

;------------------------------------------------------------------------------
Weapon PersistingMorgulBladeWeapon
  DelayBetweenShots           = 25                ; time between shots, msec
  DamageNugget                        ; A basic Nugget that just does damage
    Damage        = 10.0
    Radius        = 5.0
    DelayTime     = 0
    DamageType    = FLAME
    DamageFXType  = FLAME
    DeathType     = BURNED
  End
End

SpecialPower.ini
;------------------------------------------------------------------------------
SpecialPower SpecialAbilityNazgulMorgulBladeAttack
	Enum			= SPECIAL_WIZARD_BLAST
	ReloadTime		= 60000
	PublicTimer		= No
	;InitiateSound	= GandalfVoiceAttackWizardBlast	;this plays when he fires, not when he targets
End

I think it has something to do with the "DamageFieldNugget" cuz I tried getting a Poison Arrows ability, which also has a "DamageFieldNugget", to work for one of my units and the game also crashed the instant the attack was triggered. But I cant seem to find any error in my code. I'd appreciate any help with this.

In Topic: BoundingBox problem.

12 March 2011 - 03:42 PM

I dont know if the geometry has anything to do with. I was just trying to throw a possibility out there, and seeing if the veteran modders could confirm.
Just a question: when ingame, is it possible to click the unit when the cursor is next to the unit rather then directly over the unit? I had a problem recently where it was as if the bounding box was shifted to the right, so in order to click my unit i had to always click to the right of him. Never got it working but i think it had something to do with the "unit" not being in the center of the perspective box in Renx. I dont know if this could be your problem, but maybe its worth a check...

In Topic: BoundingBox problem.

10 March 2011 - 04:43 AM

Could the Geometry in the units code cause an issue with the Bounding Box maybe?

In Topic: Gandalf's coding questions

09 March 2011 - 09:28 PM

I've stumbled across a little problem. I've given my Citadel a commandset switcher, so it toggles commandsets between purchasing heroes and purchasing various upgrades. It works perfectly, no problems. However, when the citadel is destroyed, and i try to rebuild it, the "CommandSet Switch" button is still there as an option. So basically, I can either choose to Rebuild my citadel or Switch the commandset. But I only want the Commandset Switcher feature available ONLY when the citadel is built. Is there a way to fix this?

In Topic: Gandalf's coding questions

05 March 2011 - 07:42 PM

Thankyou Lauri, I appreciate the reply. I have never done any LUA coding or scripts before, but i guess its time i learned it. and I think i get most of what you said, I'm gonna have a go at it later today. thanks again!