Skip to content

Commit

Permalink
Merge remote-tracking branch 'upstream/develop' into trajectory-proje…
Browse files Browse the repository at this point in the history
…ctile

# Conflicts:
#	docs/Whats-New.md
#	src/Ext/Anim/Body.cpp
  • Loading branch information
Coronia committed Oct 13, 2024
2 parents 424f2e5 + b3ad958 commit 6aee40b
Show file tree
Hide file tree
Showing 57 changed files with 2,012 additions and 430 deletions.
9 changes: 8 additions & 1 deletion CREDITS.md
Original file line number Diff line number Diff line change
Expand Up @@ -243,6 +243,14 @@ This page lists all the individual contributions to the project by their author.
- Forbidding parallel AI queues for specific TechnoTypes
- Nonprovocative Warheads
- Customizing effect of level lighting on air units
- Reimplemented `Airburst` & `Splits` logic with more customization options
- Buildings considered as destroyable pathfinding obstacles
- Animation visibility customization settings
- Light effect customizations
- Building unit repair customizations
- Build area customizations
- `Scorch` / `Flamer` fire animation customization
- EM Pulse cannon logic improvements
- **Morton (MortonPL)**:
- `XDrawOffset` for animations
- Shield passthrough & absorption
Expand Down Expand Up @@ -383,7 +391,6 @@ This page lists all the individual contributions to the project by their author.
- **SukaHati (Erzoid)** - Minimum interceptor guard range
- **E1 Elite** - TileSet 255 and above bridge repair fix
- **AutoGavy** - interceptor logic, Warhead critical hit logic
- **Ollerus** - Enhance bombard trajectory with vertical & meteor trajectory
- **Chasheen (Chasheenburg)** - CN docs help
- **tomsons26** - all-around help, assistance and guidance in reverse-engineering, YR binary mappings
- **CCHyper** - all-around help, current project logo, assistance and guidance in reverse-engineering, YR binary mappings, custom locomotors example implementation
Expand Down
1 change: 1 addition & 0 deletions Phobos.vcxproj
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,7 @@
<ClCompile Include="src\Misc\Hooks.Gamespeed.cpp" />
<ClCompile Include="src\Misc\Hooks.Ares.cpp" />
<ClCompile Include="src\Misc\Hooks.Crates.cpp" />
<ClCompile Include="src\Misc\Hooks.LightEffects.cpp" />
<ClCompile Include="src\Misc\Hooks.VeinholeMonster.cpp" />
<ClCompile Include="src\Misc\PhobosToolTip.cpp" />
<ClCompile Include="src\Misc\TextInput.cpp" />
Expand Down
115 changes: 113 additions & 2 deletions docs/Fixed-or-Improved-Logics.md
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,6 @@ This page describes all ingame logics that are fixed or improved in Phobos witho
- Fixed Engineers being able to enter `Grinding` buildings even when they shouldn't (such as ally building at full HP).
- Aircraft & jumpjet units are now affected by speed modifiers such as `SpeedAircraft/Infantry/UnitsMult` on `Countries`, `VeteranSpeed` and Crates / AttachEffect (Ares feature).
- Both voxel and SHP vehicle units should now correctly respect custom palette set through `Palette`.
- Weapons fired by EMPulse superweapons without `EMPulse.TargetSelf=true` *(Ares feature)* can now create radiation.
- Setting `RadarInvisible` to true on TerrainTypes now hides them from minimap display.
- Mind control indicator animations will now correctly restore on mind controlled objects when uncloaked.
- Animations from Warhead `AnimList` & `SplashList` etc. as well as animations created through map trigger `41 Play Anim At` now have the appropriate house set as owner of the animation by default.
Expand Down Expand Up @@ -127,7 +126,6 @@ This page describes all ingame logics that are fixed or improved in Phobos witho
- Fixed `DeployToFire` not considering building placement rules for `DeploysInto` buildings and as a result not working properly with `WaterBound` buildings.
- Fixed `DeployToFire` not recalculating firer's position on land if it cannot currently deploy.
- `Arcing=true` projectile elevation inaccuracy can now be fixed by setting `Arcing.AllowElevationInaccuracy=false`.
- `EMPulseCannon=yes` building weapons now respect `Floater` and Phobos-added `Gravity` setting.
- You can now specify houses named `<Player @ A>` through `<Player @ H>` as the owner of TechnoTypes preplaced on the map in the editor, and they will be correctly given to players starting on points 1-8. Originally, it was only possible to use these house names in events, actions and teams.
- Wall overlays are now drawn with the custom palette defined in `Palette` in `artmd.ini` if possible.
- `Secondary` will now be used against walls if `Primary` weapon Warhead has `Wall=false`, `Secondary` has `Wall=true` and the firer does not have `NoSecondaryWeaponFallback` set to true.
Expand Down Expand Up @@ -171,9 +169,14 @@ This page describes all ingame logics that are fixed or improved in Phobos witho
- Animations with `MakeInfantry` and `UseNormalLight=false` that are drawn in unit palette will now have cell lighting changes applied on them.
- Removed 0 damage effect on jumpjet infantries from `InfDeath=9` warhead.
- Fixed Nuke & Dominator Level lighting not applying to AircraftTypes.
- Projectiles created from `AirburstWeapon` now remember the WeaponType and can apply radiation etc.
- Fixed damaged aircraft not repairing on `UnitReload=true` docks unless they land on the dock first.

## Fixes / interactions with other extensions

- Weapons fired by EMPulse superweapons *(Ares feature)* now fully respect the firing building's FLH.
- Weapons fired by EMPulse superweapons *(Ares feature)* without `EMPulse.TargetSelf=true` can now create radiation.
- Weapons fired by EMPulse superweapons *(Ares feature)* now respect `Floater` and Phobos-added `Gravity` setting.
- `IsSimpleDeployer` units with Hover locomotor and `DeployToLand` no longer get stuck after deploying or play their move sound indefinitely.
- All forms of type conversion (including Ares') now correctly update the warp-in delay if unit with teleport `Locomotor` was converted while the delay was active.
- All forms of type conversion (including Ares') now correctly update `MoveSound` if a moving unit has their type changed.
Expand Down Expand Up @@ -267,6 +270,41 @@ SplashAnims.PickRandom=false ; boolean
ExtraShadow=true ; boolean
```

### Fire animations spawned by Scorch & Flamer

- Tiberian Sun allowed `Scorch=true` and `Flamer=true` animations to spawn fire animations from `[AudioVisual]` -> `SmallFire` & `LargeFire`. This behaviour has been reimplemented and is fully customizable.
- `ConstrainFireAnimsToCellSpots` controls whether or not spawned animations are locked to cell spots (e.g the subcell positions infantry are also constrained to).
- `FireAnimDisallowedLandTypes` controls which landtypes the fire animations are not allowed to spawn on. Defaults to `water,rock,beach,ice` for `Scorch=true`, `none` otherwise.
- `AttachFireAnimsToParent` controls if the spawned animations are attached to the owner of the parent animation if it is also attached. Defaults to true for `Scorch=true`, otherwise false.
- `SmallFireCount` determines number of small fire animations to spawn by both `Scorch=true` and `Flamer=true` animations. Defaults to 2 for `Flamer=true`, otherwise 1.
- `SmallFireAnims` can be used to set the animation types, defaults to `[AudioVisual]` -> `SmallFire` (single animation).
- `SmallFireChances` is a list of probabilities for the animations to spawn, up to `SmallFireCount` amount of items are read. Last item listed is used if count exceeds the number of listed probabilities. Defaults to `1.0,0.5` for `Flamer=true`, `1.0` otherwise.
- `SmallFireDistances` is a list of distances in cells for the animations to spawn at from the parent animation's coordinates, up to `SmallFireCount` amount of items are read. Last item listed is used if count exceeds the number of listed probabilities. Defaults to `0.25,0.625` for `Flamer=true`, `0.0` otherwise.
- `LargeFireCount` determines number of large fire animations to spawn by`Flamer=true` animations only.
- `LargeFireAnims` can be used to set the animation types, defaults to `[AudioVisual]` -> `LargeFire` (single animation).
- `LargeFireChances` is a list of probabilities for the animations to spawn, up to `SmallFireCount` amount of items are read. Last item listed is used if count exceeds the number of listed probabilities.
- `LargeFireDistances` is a list of distances in cells for the animations to spawn at from the parent animation's coordinates, up to `SmallFireCount` amount of items are read. Last item listed is used if count exceeds the number of listed probabilities.

In `artmd.ini`:
```ini
[SOMEANIM] ; AnimationType
ConstrainFireAnimsToCellSpots=true ; boolean
FireAnimDisallowedLandTypes= ; List of LandTypes (none | clear | road | water | rock | wall | tiberium | beach | rough | ice | railroad | tunnel | weeds)
AttachFireAnimsToParent= ; boolean
SmallFireCount= ; integer
SmallFireAnims= ; list of animations
SmallFireChances= ; list of floating point values (percent or absolute)
SmallFireDistances= ; list of floating point values, distance in cells
LargeFireCount=1 ; integer
LargeFireAnims= ; list of animations
LargeFireChances=0.5 ; list of floating point values (percent or absolute)
LargeFireDistances=0.4375 ; list of floating point values, distance in cells
```

```{note}
Save for the change that `Flamer? does not spawn animations if the parent animation is in air, the default settings should provide identical results to similar feature from Ares.
```

### Layer on animations attached to objects

- You can now customize whether or not animations attached to objects follow the object's layer or respect their own `Layer` setting. If this is unset, attached animations use `ground` layer.
Expand Down Expand Up @@ -299,6 +337,24 @@ In `rulesmd.ini`:
AircraftDockingDir(N)= ; Direction type (integers from 0-255)
```

### Unit repair customization

- It is now possible to customize the repairing of units by `UnitRepair=true` and `UnitReload=true` buildings.
- `Units.RepairRate` customizes the rate at which the units are repaired. This defaults to `[General]`->`ReloadRate` if `UnitReload=true` and if overridden per AircraftType (Ares feature) can tick at different time for each docked aircraft. Setting this overrides that behaviour. For `UnitRepair=true` buildings this defaults to `[General]`->`URepairRate`.
- On `UnitReload=true` building setting this to negative value will fully disable the repair functionality.
- `Units.RepairStep` how much `Strength` is restored per repair tick. Defaults to `[General]`->`RepairStep`.
- `Units.RepairPercent` is a multiplier to cost of repairing (cost / (maximum health / repair step)). Defaults to `[General]`->`RepairPercent`. Note that the final cost is set to 1 if it is less than that.
- `Units.DisableRepairCost` if set to true disables the repair cost entirely.

In `rulesmd.ini`:
```ini
[SOMEBUILDING] ; BuildingType
Units.RepairRate= ; floating point value, ingame minutes
Units.RepairStep= ; integer
Units.RepairPercent= ; floating point value, percents or absolute
Units.DisableRepairCost=false ; boolean
```

### Airstrike target eligibility

- By default whether or not a building can be targeted by airstrikes depends on value of `CanC4`, which also affects other things. This can now be changed independently by setting `AllowAirstrike`. If not set, defaults to value of `CanC4`.
Expand Down Expand Up @@ -417,6 +473,45 @@ Gas.MaxDriftSpeed=2 ; integer (TS default is 5)

## Projectiles

### Airburst & Splits

- `AirburstWeapon` logic has been reimplemented and thus there are several additions & changes to it.
- `Splits` can be set to true to use projectile splitting logic from Firestorm, with the number of split projectiles defined by `Cluster`.
- `RetargetAccuracy` defines the probability that the splitted projectiles head to the same target as the original projectile.
- `RetargetSelf` determines if it is possible for the splitted projectiles to aim at the firer of the original projectile.
- `RetargetSelf.Probability` is the probability that if the original firer is chosen as a target, it is kept as the target instead of rerolled to another.
- `Splits.TargetingDistance` is the distance in cells that any potential target has to be within from the original target coordinates to be eligible for targeting by the splitted projectiles.
- `Splits.TargetCellRange` is the distance in whole cells from the original target cell from which the splitted projectiles can pick new target cells if not enough TechnoType targets were found nearby.
- `Splits.UseWeaponTargeting`, if set to true, enables weapon targeting filter for when checking targets for splitted projectiles. Target's `LegalTarget` setting, Warhead `Verses` against `Armor` as well as `AirburstWeapon` [weapon targeting filters](#weapon-targeting-filter) & [AttachEffect filters](#attached-effects) will be checked.
- Do note that this overrides checking Warhead for `AffectsAllies/Owner/Enemies` for targeting. You can use `CanTargetHouses` on `AirburstWeapon` to achieve similar behaviour, however.
- Behaviour for if `Airburst` is set to true can also be customized.
- `AirburstSpread` is the distance in cells that the effect covers, with each cell in range being targeted by `AirburstWeapon` by default.
- `Airburst.UseCluster`, if set to true, makes it so that only number of cells in the affected area dictated by `Cluster` will be affected, instead of all of them.
- If `Airburst.RandomClusters` is set to true, the cells affected will be picked by random. Otherwise they will be evenly spaced (counting from center to edges of affected area).
- `AroundTarget` controls whether or not targets for projectiles created by `Airburst` or `Splits` are checked for in area around the original projectile's intended target, or where the original projectile detonated. Defaults to value of `Splits`.
- `AirburstWeapon.ApplyFirepowerMult` determines whether or not firepower modifiers from the firer of the original projectile are applied on the projectiles created from `AirburstWeapon`.

In `rulesmd.ini`:
```ini
[SOMEPROJECTILE] ; Projectile
Splits= ; boolean
RetargetAccuracy=0.0 ; floating point value, percents or absolute (0.0-1.0)
RetargetSelf=true ; boolean
RetargetSelf.Probability=0.5 ; floating point value, percents or absolute (0.0-1.0)
Splits.TargetingDistance=5.0 ; floating point value, distance in cells
Splits.TargetCellRange=3 ; integer, cell offset
Splits.UseWeaponTargeting=false ; boolean
AirburstSpread=1.5 ; floating point value, distance in cells
Airburst.UseCluster=false ; boolean
Airburst.RandomClusters=false ; boolean
AroundTarget= ; boolean
AirburstWeapon.ApplyFirepowerMult=false ; boolean
```

```{note}
`Splits`, `AirburstSpread`, `RetargetAccuracy`, `RetargetSelf` and `AroundTarget`, beyond the other additions, should function similarly to the equivalent features introduced by Ares and take precedence over them if Phobos is used together with Ares.
```

### Cluster scatter distance customization

- `ClusterScatter.Min` and `ClusterScatter.Max` can be used to set minimum and maximum distance, respectively, in cells from the original detonation coordinate any additional detonations if `Cluster` is set to value higher than 1 can appear at.
Expand Down Expand Up @@ -1275,6 +1370,21 @@ In `rulesmd.ini`:
AllowDamageOnSelf=false ; boolean
```

### Combat light customizations

- You can now set minimum detail level at which combat light effects are shown by setting `[AudioVisual]` -> `CombatLightDetailLevel` or `CombatLightDetailLevel` on Warhead, latter defaults to former.
- You can now set a percentage chance a combat light effect is shown on Warhead impact by setting `CombatLightChance`.

In `rulesmd.ini`:
```ini
[AudioVisual]
CombatLightDetailLevel=0 ; integer

[SOMEWARHEAD] ; WarheadType
CombatLightDetailLevel= ; integer
CombatLightChance=1.0 ; floating point value, percents or absolute (0.0-1.0)
```

### Customizing decloak on damaging targets

- You can now specify whether or not the warhead decloaks objects that are damaged by the warhead.
Expand All @@ -1299,6 +1409,7 @@ In `rulesmd.ini`:
Nonprovocative=false ; boolean
```


```{note}
Due to technical constraints, this does not suppress warnings from Ares' EMP effect.
```
Expand Down
Loading

0 comments on commit 6aee40b

Please sign in to comment.