Jump to content


Photo

Active leadership or ping attached to a hero. (SOLVED)


  • Please log in to reply
32 replies to this topic

#21 modboy451

modboy451

    A small Big-time Modder!

  • Project Team
  • 783 posts
  • Location:U.S.A
  •  Experienced INI Coder, Advanced Rigger/Binder.

Posted 21 October 2011 - 01:44 AM

it has to go below the DefaultModelConditionState... and about MOUNTED i think... I can't remember... sombody posted an Order somewhere... xD

John 3:16 (NIV)
For God so loved the world that he gave his one and only Son, that whoever believes in him shall not perish but have eternal life.


Psalm 23:1 (ESV)
A Psalm of David.
The LORD is my shepherd; I shall not want.


Posted Image
Posted Image
Posted Image
Posted Image

#22 Nertea

Nertea

    ...lo sa raptor!

  • Hosted
  • 3,349 posts
  • Location:Vancouver, Canada
  • Projects:Star Villains and Space heroes, The Dwarf Holds
  •  T3A Chamber Member
  • Division:BFME/Unity

Posted 21 October 2011 - 09:24 PM

I have no idea what you're on about.

sig.png
I really don't do requests and my Arnor Soldier is not fit for BFME. Don't ask me for either.


#23 JUS_SAURON

JUS_SAURON

    El Shaddai

  • Members
  • 1,581 posts
  • Location:Trinidad
  • Projects: BFME2 MOD - Power Of The Ring
  •   INI Coder

Posted 22 October 2011 - 02:45 PM

Hmmm ..

You could try a Blademaster style Power that will activate for a duration

Then in the AttributeModifier use an upgrade that is activated
( it can give the HERO some boost if you want as well ...)

ModifierList HeroChargeAttribute
	Category = SPELL
	Modifier = ARMOR 50%   
        Upgrade =  Upgrade_HasWallTrebuchet1   Delay:1     
	Duration = 40000
End

Then the upgrade triggers a Attribute behaviour module that 'Does the Aura Power' you want for the surrounding units

;// Banner Carrier
	Behavior = AttributeModifierAuraUpdate ModuleTag_BannerCarrierBuff
		StartsActive			= No
		BonusName				= GenericHeroLeadershipBattleWagon  ; GenericHeroLeadership
		TriggeredBy				= Upgrade_HeroAura
		RefreshDelay			= 2000
		Range					= 200
		AntiCategory			= BUFF
		ObjectFilter			= GENERIC_BUFF_RECIPIENT_OBJECT_FILTER 
	End

This is the tricky part .. that same upgrade must give an upgrade that cancels the first upgrade
So you can get it again ..
I can never remember this set-up but try this
Its a 'Cylclic Three upgrade' code that each upgrade removes the other
Behavior = ObjectCreationUpgrade MakeTheFreeTreb
		TriggeredBy		= Upgrade_HasWallTrebuchet1
		Delay			= 0		
		GrantUpgrade	= Upgrade_HasWallTrebuchet
                RemoveUpgrade	= Upgrade_WallTrebuchetButtonEnable
		DestroyWhenSold = Yes		
	End

Behavior = ObjectCreationUpgrade MakeTheFreeTreb2
		TriggeredBy		= Upgrade_HasWallTrebuchet
		Delay			= 3000	;;;THIS DETERMINES THE TIME FOR THE AURA TO LAST 	
		RemoveUpgrade	= Upgrade_HasWallTrebuchet1
                GrantUpgrade	= Upgrade_WallTrebuchetButtonEnable		
		DestroyWhenSold = Yes		
	End

Behavior = ObjectCreationUpgrade MakeTheFreeTreb3
		TriggeredBy		= Upgrade_WallTrebuchetButtonEnable
		Delay			= 0		
		RemoveUpgrade	= Upgrade_HasWallTrebuchet                		
		DestroyWhenSold = Yes		
	End

You modify the aura time by adjusting  how long the upgrade lasts before its removed


#24 JUS_SAURON

JUS_SAURON

    El Shaddai

  • Members
  • 1,581 posts
  • Location:Trinidad
  • Projects: BFME2 MOD - Power Of The Ring
  •   INI Coder

Posted 22 October 2011 - 03:02 PM

And a second way

You activate a Heromode Power like the Balrog
The weapon delivers the Aura to ALLIES


	Behavior = FireWeaponUpdate FireWeaponUpdateModuleTag
		FireWeaponNugget
			WeaponName = AuraHeroEffectRadiusWeapon
			FireDelay = 0
			OneShot = No
		End
		HeroModeTrigger = Yes ; this only happens when hero mode is active
	End

His weapon that affects ALLIES only
The weapon is a Radius weapon that constantly fires


Weapon AuraHeroEffectRadiusWeapon ; Shot out every DelayBetweenShots
	RadiusDamageAffects = ALLIES 
	LeechRangeWeapon      = Yes
	AttackRange           = 9999999.0
	MeleeWeapon           = No
	DelayBetweenShots     = 0            ; time between shots, msec
	PreAttackDelay        = 0 ;PreAttackDelay+FiringDuration = UseWeaponTiming = Yes duration
	PreAttackType         = PER_SHOT 
	FiringDuration        = 0 

	AttributeModifierNugget
		AttributeModifier        = HeroAuraModifier
		Radius        		 = 300
		DamageFXType             = MAGIC
		SpecialObjectFilter      = GENERIC_BUFF_RECIPIENT_OBJECT_FILTER 
	End  	

End


The aura should last a few secs and is refreshed each time
When the heromode switches off , the wepon switches off and so does the Attribute

Edited by JUS_SAURON, 22 October 2011 - 03:03 PM.


#25 modboy451

modboy451

    A small Big-time Modder!

  • Project Team
  • 783 posts
  • Location:U.S.A
  •  Experienced INI Coder, Advanced Rigger/Binder.

Posted 23 October 2011 - 09:02 PM

i mean with like...

MOUNTED tag has to come before the HERO tab model condition state or something... and as do others or something.... i can't remember exactly.

John 3:16 (NIV)
For God so loved the world that he gave his one and only Son, that whoever believes in him shall not perish but have eternal life.


Psalm 23:1 (ESV)
A Psalm of David.
The LORD is my shepherd; I shall not want.


Posted Image
Posted Image
Posted Image
Posted Image

#26 Elric

Elric

    Designer

  • Hosted
  • 2,857 posts
  • Projects:Middle-Earth Expanded
  •  Coder
  • Donated

Posted 25 October 2011 - 12:13 AM

Can i ask a question? To bad i am going to.

@ Goubish:

Do you want a leadership power that has a duration and that can increase a heroes power and a hordes power or:

heroes power only or hordes power only.

Because if you want both you could just make 2 attribute modifier codes and have them like to one upgrade.

One of the Attribute modifiers is for the hero, while the other is for the hordes. or you could just have ONE modifier and add a filter to it. saying: ALL +HERO +ALLIES.

Something like that. (Dont have the codes in front of me just going by memory.) I have done something like this before.


@Nertea: Nice Explanation, i have been looking for someone to use the LUA method.

#27 Nertea

Nertea

    ...lo sa raptor!

  • Hosted
  • 3,349 posts
  • Location:Vancouver, Canada
  • Projects:Star Villains and Space heroes, The Dwarf Holds
  •  T3A Chamber Member
  • Division:BFME/Unity

Posted 25 October 2011 - 07:42 PM

Yeah, but that's not what he wants. He wants a power that refreshes constantly so that if you move units into the area of effect halfway through, they gain the bonus. You can't do that via a triggered attribute modifier, because the buff will be applied to units ONLY at the start, and they'll keep the buff if they move out of the effect radius. That has effectively nothing to do with what you're saying.

I suspect JUS's method will work ok, but I have had limited success with removing upgrades in that fashion.

sig.png
I really don't do requests and my Arnor Soldier is not fit for BFME. Don't ask me for either.


#28 Ganon

Ganon

    What's this?

  • Project Team
  • 967 posts
  • Location:Ohio, United States
  • Projects:My Link Mod
  •  Code Scientist

Posted 26 October 2011 - 02:52 AM

Actually JUS's most recent method doesn't even include the removal of upgrades. And it looks really promising.

#29 Gourbish

Gourbish
  • Members
  • 149 posts
  • Location:France

Posted 27 October 2011 - 02:47 PM

Hi all !

I'm back...
I've just read your messages.
I will explore JUS's methods and will make tests this evening or tomorrow.

Thank's.

#30 Nertea

Nertea

    ...lo sa raptor!

  • Hosted
  • 3,349 posts
  • Location:Vancouver, Canada
  • Projects:Star Villains and Space heroes, The Dwarf Holds
  •  T3A Chamber Member
  • Division:BFME/Unity

Posted 27 October 2011 - 10:06 PM

Actually JUS's most recent method doesn't even include the removal of upgrades. And it looks really promising.

Oh, that's even better! And there's no reason for it not work, so go for that one :p

sig.png
I really don't do requests and my Arnor Soldier is not fit for BFME. Don't ask me for either.


#31 Gourbish

Gourbish
  • Members
  • 149 posts
  • Location:France

Posted 02 November 2011 - 12:25 AM

Congratulations JUS_SAURON !
As hoped, your second method (FireWeapon + HeroMode) works perfectly ! Great idea !
Thank you !

One question : why do you set "AttackRange" to 9999999.0 in the weapon ?

Edited by Gourbish, 02 November 2011 - 12:26 AM.


#32 JUS_SAURON

JUS_SAURON

    El Shaddai

  • Members
  • 1,581 posts
  • Location:Trinidad
  • Projects: BFME2 MOD - Power Of The Ring
  •   INI Coder

Posted 02 November 2011 - 01:14 AM

One question : why do you set "AttackRange" to 9999999.0 in the weapon ?

I didn't ...EA did
its a copy of
FloodHorseRadiusWeapon
you can try smaller values to see what happens

I've seen other RadiusWeapon's like ChillSoulRadiusWeapon have range of 50.0

I usually copy paste till somethong works :wink_new:

Edited by JUS_SAURON, 02 November 2011 - 01:23 AM.


#33 Ganon

Ganon

    What's this?

  • Project Team
  • 967 posts
  • Location:Ohio, United States
  • Projects:My Link Mod
  •  Code Scientist

Posted 02 November 2011 - 03:09 AM

Well, simply put, "AttackRange" has no purpose in a weapon of this type. It isn't needed, or rather, "used".

This is an aura weapon. Meaning that the radius is determined by "Radius" in the "nugget". Whether it be an "AttributeModifierNugget" or a "DamageNugget". :good:




1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users