Project Perfect Mod Forums
:: Home :: Get Hosted :: PPM FAQ :: Forum FAQ :: Privacy Policy :: Search :: Memberlist :: Usergroups :: Register :: Profile :: Log in to check your private messages :: Log in ::


The time now is Thu Apr 18, 2024 8:21 am
All times are UTC + 0
Some implementation of Tech Upgrades
Moderators: Ares Support Team at PPM, Global Moderators, Red Alert 2 Moderators
Post new topic   Reply to topic Page 1 of 1 [3 Posts] Mark the topic unread ::  View previous topic :: View next topic
Author Message
RehteA
Soldier


Joined: 16 Oct 2013

PostPosted: Fri Mar 19, 2021 4:54 am    Post subject:  Some implementation of Tech Upgrades Reply with quote  Mark this post and the followings unread

Unlike using use Prerequisite and Prerequisite.Negative, all following methods work on existing units.

1: Using AttachEffect
The Upgrade Building provide a superweapon applying buffs to specific types.
Example: Upgrade armor for all GrizzlyTank
Code:
[BuffSpecial]
...
Type=GenericWarhead
SW.AutoFire=yes
SW.AITargeting=base
SW.Damage=0
SW.Warhead=BuffWH

[BuffWH]
CellSpread=255 ;full map effect
Versus.someType=3%
AttachEffect.Duration=-1
AttachEffect.ArmorMultipler=1.25
...
AffectsEnemies=no
AffectsAllies=no
AffectsOwner=yes


Advanced: Using Attach Animation effects
Use attached Animation features like damage or weapon
Example: Upgrade all APOC Tanks with a speaker tower which can heal and buff nearby unit
Code:
[BuffWH]
AttachEffect.Animation=AniSpeaker

[AniSpeaker] ;Animation
Weapon=Speaker


Note: Animation weapons may have owner issue

Advanced: Using AE Firepower Multiplier and Warhead AnimList
Warhead animation will be picked from AnimList depends on weapon's damage.

from modenc:
The animation is acquired by dividing this delivered damage by 25 and truncating the result.For example, to 24 damage, the first animation in the list will be played. From 25 to 49 damage, the second animation.

We can use AE to buff unit's damage and change warhead animation for different effects;
Example: Upgrade Fireball weapon to make it leave a larger burning area on the ground

Code:
[BuffWH]
AttachEffect.FirepowerMultipler=1.5

[FireBallWeapon]
Damage=20

[FireBallWH]
AnimList=NormalFlameBurst,BuringArea


Note: Since there are many ways to modify firepower, unit may be accidentally gained or lost the upgrade.

2.Battery Superweapon
Just use the Battery superweapon to make base defense use new weapon;
Example: Upgrade Gun Turret to use railgun
Code:
[GAGUNT]
Primary=TurretGun
Secondary=TurretRailgun
[UpgradeSpecial]
Type=Battery
SW.AITargeting=base
RechargeTime=0.01
SW.ChargeToDrainRatio=10000
Battery.Overpower=GAGUNT


3.Elite Spawn Missile
Use academy logic to make Spawned Missile to fire Elite weapon
Example: Upgrade all V3Rockets. Make it split into multiple warhead;
Code:
[UpgradeBuilding]
Academy.AircraftVeterancy=2
Academy.Types=V3Rocket

[V3Rocket]
ElitePrimary=V3Airburst


Note: For the launcher unit already exist on map, first shot missile after upgrade will still be rookie. Next one will be elite.

4.Using Spawn Aircraft to add or upgrade weapon/ability
First make a invisible 'hornet' type unit with limited life time
Code:
[SPAWNEE] ;Aircraft Type
Image=SomeInvisibleVXL
Spawned=yes
LegalTarget=no
Armor=Spawnee
Landable=no
AttachEffect.Animation=KillSpawnee
AttachEffect.InitialDelay=100 ;should be long enough for firing its weapon
AttachEffect.Duration=-1
Fighter=yes ; Important.
Speed=1;Very Slow Speed
ROT=20 ;High ROT

We can use PoweredBy logic to activate the spawnee
Example: Grant Lasher Tank FlashBang ability;
Code:
[FlashBangFirer] ;spawnee Aircraft Type
Primary=FlashBang
FlightLevel=110 ;near ground
PoweredBy=UpgradBuilding

[FlashBangFirerLauncher] ;spawnee launcher weapon
ROF=1 ;should be very low.We use SpawnRegenRate for cool down

[LTNK]
;spawner logic
Spawns=FlashBangFirer
SpawnsNumber=1 ;must be 1,multiple spawnees take too long to takeoff
SpawnRegenRate=300 ; the cooldown time for the ability
SpawnReloadRate=1 ;not useful since spawee will never land and reload

;cycle gattling logic
Weapon1=FlashBangFirerLauncher
Weapon3=ATGUN

Before upgrade,without being powered, FlashBangFirer will be destroyed immediately once launched;
After upgrade,spawnee will survive and fire its weapon and destroyed by animation afterwards.

Known issue: Since there is always some delay between spawnee launching and weapon firing, the spawnee cannot keep position with its parent unit.
The ability weapon may always be seen fired from nothing.
Invisible projectile looks best. Missile looks OK. Don't use laser effect since it looks bad when fired from nothing.

You can also use academy logic to change spawnee weapon for making different upgrade effects.

Back to top
View user's profile Send private message
XxpeddyxX
Commander


Joined: 03 Sep 2004

PostPosted: Fri Mar 19, 2021 5:37 am    Post subject: Reply with quote  Mark this post and the followings unread

I've explored many different upgrade methods but I've never come across the powered by spawned method, it's very clever. I will try this to see if it will be a good substitute for unit replacement!

_________________

ayylmao on Discord

Back to top
View user's profile Send private message
Mr.Hymn
Missile Trooper


Joined: 01 May 2020

PostPosted: Sun Oct 03, 2021 9:41 am    Post subject: Re: Some implementation of Tech Upgrades Reply with quote  Mark this post and the followings unread

RehteA wrote:
Unlike using use Prerequisite and Prerequisite.Negative, all following methods work on existing units.

1: Using AttachEffect
The Upgrade Building provide a superweapon applying buffs to specific types.
Example: Upgrade armor for all GrizzlyTank
Code:
[BuffSpecial]
...
Type=GenericWarhead
SW.AutoFire=yes
SW.AITargeting=base
SW.Damage=0
SW.Warhead=BuffWH

[BuffWH]
CellSpread=255 ;full map effect
Versus.someType=3%
AttachEffect.Duration=-1
AttachEffect.ArmorMultipler=1.25
...
AffectsEnemies=no
AffectsAllies=no
AffectsOwner=yes


Advanced: Using Attach Animation effects
Use attached Animation features like damage or weapon
Example: Upgrade all APOC Tanks with a speaker tower which can heal and buff nearby unit
Code:
[BuffWH]
AttachEffect.Animation=AniSpeaker

[AniSpeaker] ;Animation
Weapon=Speaker


Note: Animation weapons may have owner issue

Advanced: Using AE Firepower Multiplier and Warhead AnimList
Warhead animation will be picked from AnimList depends on weapon's damage.

from modenc:
The animation is acquired by dividing this delivered damage by 25 and truncating the result.For example, to 24 damage, the first animation in the list will be played. From 25 to 49 damage, the second animation.

We can use AE to buff unit's damage and change warhead animation for different effects;
Example: Upgrade Fireball weapon to make it leave a larger burning area on the ground

Code:
[BuffWH]
AttachEffect.FirepowerMultipler=1.5

[FireBallWeapon]
Damage=20

[FireBallWH]
AnimList=NormalFlameBurst,BuringArea


Note: Since there are many ways to modify firepower, unit may be accidentally gained or lost the upgrade.

2.Battery Superweapon
Just use the Battery superweapon to make base defense use new weapon;
Example: Upgrade Gun Turret to use railgun
Code:
[GAGUNT]
Primary=TurretGun
Secondary=TurretRailgun
[UpgradeSpecial]
Type=Battery
SW.AITargeting=base
RechargeTime=0.01
SW.ChargeToDrainRatio=10000
Battery.Overpower=GAGUNT


3.Elite Spawn Missile
Use academy logic to make Spawned Missile to fire Elite weapon
Example: Upgrade all V3Rockets. Make it split into multiple warhead;
Code:
[UpgradeBuilding]
Academy.AircraftVeterancy=2
Academy.Types=V3Rocket

[V3Rocket]
ElitePrimary=V3Airburst


Note: For the launcher unit already exist on map, first shot missile after upgrade will still be rookie. Next one will be elite.

4.Using Spawn Aircraft to add or upgrade weapon/ability
First make a invisible 'hornet' type unit with limited life time
Code:
[SPAWNEE] ;Aircraft Type
Image=SomeInvisibleVXL
Spawned=yes
LegalTarget=no
Armor=Spawnee
Landable=no
AttachEffect.Animation=KillSpawnee
AttachEffect.InitialDelay=100 ;should be long enough for firing its weapon
AttachEffect.Duration=-1
Fighter=yes ; Important.
Speed=1;Very Slow Speed
ROT=20 ;High ROT

We can use PoweredBy logic to activate the spawnee
Example: Grant Lasher Tank FlashBang ability;
Code:
[FlashBangFirer] ;spawnee Aircraft Type
Primary=FlashBang
FlightLevel=110 ;near ground
PoweredBy=UpgradBuilding

[FlashBangFirerLauncher] ;spawnee launcher weapon
ROF=1 ;should be very low.We use SpawnRegenRate for cool down

[LTNK]
;spawner logic
Spawns=FlashBangFirer
SpawnsNumber=1 ;must be 1,multiple spawnees take too long to takeoff
SpawnRegenRate=300 ; the cooldown time for the ability
SpawnReloadRate=1 ;not useful since spawee will never land and reload

;cycle gattling logic
Weapon1=FlashBangFirerLauncher
Weapon3=ATGUN

Before upgrade,without being powered, FlashBangFirer will be destroyed immediately once launched;
After upgrade,spawnee will survive and fire its weapon and destroyed by animation afterwards.

Known issue: Since there is always some delay between spawnee launching and weapon firing, the spawnee cannot keep position with its parent unit.
The ability weapon may always be seen fired from nothing.
Invisible projectile looks best. Missile looks OK. Don't use laser effect since it looks bad when fired from nothing.

You can also use academy logic to change spawnee weapon for making different upgrade effects.


This one is very unique and interesting of battery weapon. I will spend time more learning from this.

Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic Page 1 of 1 [3 Posts] Mark the topic unread ::  View previous topic :: View next topic
 
Share on TwitterShare on FacebookShare on Google+Share on DiggShare on RedditShare on PInterestShare on Del.icio.usShare on Stumble Upon
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Powered by phpBB © phpBB Group

[ Time: 0.1418s ][ Queries: 11 (0.0083s) ][ Debug on ]