ModEnc is currently in Maintenance Mode: Changes could occur at any given moment, without advance warning.

IsSonic: Difference between revisions

From ModEnc
Jump to navigation Jump to search
No edit summary
 
Testid123 (talk | contribs)
mNo edit summary
 
(8 intermediate revisions by 6 users not shown)
Line 1: Line 1:
{{DeeZireInclusion}}<br />
{{Flag
Can be set to 'yes' or 'no' and specifies that the weapon and warhead utilize an internal routine that draws a colored line from the attacker to the target with a kind of 'wave' effect. This is only used by the Dolphin in Red Alert 2 (it is modified code from the Disruptor in Tiberian Sun). It is not known if the line can be made continuous (as in Tiberian Sun) rather than 'broken', although the IsMagBeam=yes tag on a weapon in Yuri's Revenge creates a similar effect.<br />
|name=IsSonic
Projectiles (often referred to throughout the game files as 'bullets' or 'bullet types') form the delivery method of the weapon - the weapon defines what happens, the warhead defines how and what against, and the projectile delivers the effect from the firer to the target. NOTE: the Splits= tag is removed from the game when you install Yuri's Revenge or patch Red Alert 2 to 1.005 or later, although the tag never functioned anyway as only part of the logic was residual from Tiberian Sun: Firestorm, which meant the RetargetAccuracy= tag which was needed for that logic was never present in Red Alert 2. As a result, it no longer gets parsed or acknowledged so for the purposes of this guide it simply does not exist anymore. The same is true of the Parachuted= tag.
|files={{Categ|Rules(md).ini}}
|values=boolean
|default=no
|types={{Categ|Weapon|Weapons}}
|ts=yes
|fs=yes
|ets=yes
|ra2=yes
|yr=yes
|rp=yes
}}
 
If set, the game will draw a colored wave along the projectile path (It is used for the Disruptor in TS and the Dolphin in RA2). In TS, the wave is continuous, in RA2, it is not. In YR, {{f|IsMagBeam|yes|link}} provides a similar effect, but it is drawn in the reverse direction (from the target towards the firing unit) when attacking [[VehicleTypes]].
 
''Note:'' if the projectile is invisible, then the warhead will detonate when the wave hits the target. If it is visible, this wave will be only a graphic effect, and the warhead will detonate when the visible projectile hits. However, AI units will "sense" the wave and try to scatter before the projectile hits.<br>
 
Usually <b>IsSonic=yes</b> will cause damage to [[TechnoTypes]] that also belongs to you. To prevent this, add the {{f|AffectsAllies|no|link}} tag to the Sonic weapon warhead.
 
==Damage calculation==
{{HorizontalBar|This section details the way this logic works in the '''{{yr}}''' EXE. Handling in other games supporting this flag may be different.|image=Cc alert.png}}
As noted by [http://www.youtube.com/watch?v=Q3UiNo7Oy1E some community members] in the past, {{f|IsSonic}} deals more damage to closer units than to units that are further away. The reason for this lies (logically), in the way {{f|IsSonic}} works and applies its damage: A sonic wave exists for precisely 20 frames, regardless of how far it has to travel. On each of these frames, it will damage all targets it has passed up to that frame. This, in turn, means a target that is closer to the shooter, and is hit early in the life cycle of the wave, takes considerably more damage, simply because it is longer under the influence of the wave, and damage is applied to it more often.
 
===Example===
Let us assume there are three targets to be hit by a sonic wave.<br>
One will be reached after 5 frames, one after 10, and one after 15 frames.<br>
The table below illustrates how damage would be applied to them, and makes very obvious why closer targets take so much more damage than those further away:
 
 
{|align="center" cellpadding="4" class="table_descrow"
!Frame
!Target 1
!Target 2
!Target 3
|-
|1
|{{co|no damage|Grey}}
|{{co|no damage|Grey}}
|{{co|no damage|Grey}}
|-
|2
|{{co|no damage|Grey}}
|{{co|no damage|Grey}}
|{{co|no damage|Grey}}
|-
|3
|{{co|no damage|Grey}}
|{{co|no damage|Grey}}
|{{co|no damage|Grey}}
|-
|4
|{{co|no damage|Grey}}
|{{co|no damage|Grey}}
|{{co|no damage|Grey}}
|-
|5
|{{co|no damage|Grey}}
|{{co|no damage|Grey}}
|{{co|no damage|Grey}}
|-
|6
|damage
|{{co|no damage|Grey}}
|{{co|no damage|Grey}}
|-
|7
|damage
|{{co|no damage|Grey}}
|{{co|no damage|Grey}}
|-
|8
|damage
|{{co|no damage|Grey}}
|{{co|no damage|Grey}}
|-
|9
|damage
|{{co|no damage|Grey}}
|{{co|no damage|Grey}}
|-
|10
|damage
|{{co|no damage|Grey}}
|{{co|no damage|Grey}}
|-
|11
|damage
|damage
|{{co|no damage|Grey}}
|-
|12
|damage
|damage
|{{co|no damage|Grey}}
|-
|13
|damage
|damage
|{{co|no damage|Grey}}
|-
|14
|damage
|damage
|{{co|no damage|Grey}}
|-
|15
|damage
|damage
|{{co|no damage|Grey}}
|-
|16
|damage
|damage
|damage
|-
|17
|damage
|damage
|damage
|-
|18
|damage
|damage
|damage
|-
|19
|damage
|damage
|damage
|-
|20
|damage
|damage
|damage
|}
 
{{Bugs}}
Warhead and AmbientDamage of Sonic weapons always read only the Primary weapon.
*This bug has been fixed in Ares 0.1.
Sonic weapons don't normally fire at targets over 8 spaces.
*This bug has been fixed in Ares 0.B.
[Hardcoded]: IsSonic does not read {{f|Wall|no|link}} on warhead.
*This bug has been fixed in Ares 3.0.<br>
<b>IsSonic=yes</b> disrupts the work of logic [[IsGattling]]

Latest revision as of 11:47, 16 September 2024

Tiberian Dawn The Covert Operations Red Alert Counterstrike Aftermath Tiberian Sun Firestorm HyperPatch Red Alert 2 Yuri's Revenge Ares Generals Zero Hour Tiberium Wars Kane's Wrath
Flag: IsSonic
File(s): Rules(md).ini
Values: boolean
Default: no
Applicable to: Weapons


If set, the game will draw a colored wave along the projectile path (It is used for the Disruptor in TS and the Dolphin in RA2). In TS, the wave is continuous, in RA2, it is not. In YR, IsMagBeam=yes provides a similar effect, but it is drawn in the reverse direction (from the target towards the firing unit) when attacking VehicleTypes.

Note: if the projectile is invisible, then the warhead will detonate when the wave hits the target. If it is visible, this wave will be only a graphic effect, and the warhead will detonate when the visible projectile hits. However, AI units will "sense" the wave and try to scatter before the projectile hits.

Usually IsSonic=yes will cause damage to TechnoTypes that also belongs to you. To prevent this, add the AffectsAllies=no tag to the Sonic weapon warhead.

Damage calculation

This section details the way this logic works in the Yuri's Revenge EXE. Handling in other games supporting this flag may be different.

As noted by some community members in the past, IsSonic deals more damage to closer units than to units that are further away. The reason for this lies (logically), in the way IsSonic works and applies its damage: A sonic wave exists for precisely 20 frames, regardless of how far it has to travel. On each of these frames, it will damage all targets it has passed up to that frame. This, in turn, means a target that is closer to the shooter, and is hit early in the life cycle of the wave, takes considerably more damage, simply because it is longer under the influence of the wave, and damage is applied to it more often.

Example

Let us assume there are three targets to be hit by a sonic wave.
One will be reached after 5 frames, one after 10, and one after 15 frames.
The table below illustrates how damage would be applied to them, and makes very obvious why closer targets take so much more damage than those further away:


Frame Target 1 Target 2 Target 3
1 no damage no damage no damage
2 no damage no damage no damage
3 no damage no damage no damage
4 no damage no damage no damage
5 no damage no damage no damage
6 damage no damage no damage
7 damage no damage no damage
8 damage no damage no damage
9 damage no damage no damage
10 damage no damage no damage
11 damage damage no damage
12 damage damage no damage
13 damage damage no damage
14 damage damage no damage
15 damage damage no damage
16 damage damage damage
17 damage damage damage
18 damage damage damage
19 damage damage damage
20 damage damage damage

Bugs/Side-Effects/Unexpected Limitations

Warhead and AmbientDamage of Sonic weapons always read only the Primary weapon.

  • This bug has been fixed in Ares 0.1.

Sonic weapons don't normally fire at targets over 8 spaces.

  • This bug has been fixed in Ares 0.B.

[Hardcoded]: IsSonic does not read Wall=no on warhead.

  • This bug has been fixed in Ares 3.0.

IsSonic=yes disrupts the work of logic IsGattling