Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - Buscher

Pages: 1 [2] 3 4 ... 12
16
Released Mods / Re: [UFO][OXCE][Graphic(al Violence)] Gibs of Gory
« on: February 17, 2023, 11:56:16 am »
# Small How-To-Integrate Guide

## extraSprites

- The Repo/Script can be found here
- for each spriteSheet you need to extend the PCK with the smaller sheets containing the death Animations. The gib sheets can be 256x48 for 8 frames. Other dimensions are probably also possible.
Code: [Select]
extraSprites:
  - type: XCOM_SOLDIER_0_GOG.PCK
    subX: 32
    subY: 40
    width: 256
    height: 1400
    files:
      0: Resources/Vanilla/XCOM_0.PNG
      320: Resources/Vanilla/XCOM_0_normal.PNG
      328: Resources/Vanilla/XCOM_0_gibs.PNG
      336: Resources/Brain_322/human_to_ash.png
      344: Resources/Brain_322/human_to_goo.png
We will need the Indices 320, 328, 336, 344 later. The indices start at 320 as the biggest TFTD sheet has 304 frames and 320 seems to be a good number. There is a difference of 8 to make sure that one gib sheet isn't drawn into another one. If you want to add more kinds of deaths, you just add another line with an additional +8.

Also we probably want to set up a corpse, so FLOOR.PCK and BIGOBS.PCK need to be set up accordingly

Code: [Select]
extraSprites:
  - type: FLOOROB.PCK
    files:
      200: Resources/floorob_gibs.png
      201: Resources/Brain_322/floorob_Ash.png
      202: Resources/Brain_322/floorob_Goo.png

  - type: BIGOBS.PCK
    files:
      200: Resources/floorob_gibs.png
      201: Resources/Brain_322/floorob_Ash.png
      202: Resources/Brain_322/floorob_Goo.png

We will remember 200, 201 and 202. Similar to the spritesheets additional sprites can be added here.

## armors

Then we will need to modify the armor
Code: [Select]
extended:
  tags:
    RuleArmor:
      NORMAL_SPRITESHEET: int
      GIB_SPRITESHEET: int
      BURNED_SPRITESHEET: int
      GOO_SPRITESHEET: int

armors:
  - &STR_GOG_ARMOR
    type: STR_NONE_UC
    spriteSheet: XCOM_SOLDIER_0_GOG.PCK
    deathFrames: 8 # if you want to use more than the default 3
    tags:
      NORMAL_SPRITESHEET: 320 # Resources/Vanilla/XCOM_0_normal.PNG
      GIB_SPRITESHEET: 328 # Resources/Vanilla/XCOM_0_gibs.PNG
      BURNED_SPRITESHEET: 336 # Resources/Brain_322/human_to_ash.png
      GOO_SPRITESHEET: 344 # Resources/Brain_322/human_to_goo.png

The values for the tags are the numbers we set up in extraSprites for the sprite sheet. A normal death spritesheet should be tacked on if you want to use a higher value than 3 for deathFrames.

## corpses

Similar to the armor we need to set a few tags for the corpses.

Code: [Select]
extended:
  tags:
    RuleItem:
      GIB_BIGOB: int
      GIB_FLOOROB: int
      BURNED_BIGOB: int
      BURNED_FLOOROB: int
      GOO_BIGOB: int
      GOO_FLOOROB: int


items:
  - &STR_HUMAN_CORPSE
    type: STR_CORPSE
    tags:
      GIB_BIGOB: 200 # Resources/floorob_gibs.png
      GIB_FLOOROB: 200 # Resources/floorob_gibs.png
      BURNED_BIGOB: 201 # Resources/Brain_322/floorob_Ash.png
      BURNED_FLOOROB: 201 # Resources/Brain_322/floorob_Ash.png
      GOO_BIGOB: 202 # Resources/Brain_322/floorob_Goo.png
      GOO_FLOOROB: 202 # Resources/Brain_322/floorob_Goo.png

17
OXCE Suggestions Y-script / [Suggestion/Y-Scripts]setDeathFrames
« on: February 17, 2023, 11:36:38 am »
For Gibs of Gory it would be helpful if scripting allowed to set the number of DeathFrames. I would like to keep the default 3 for the standard death while being able to extend the more messy ones to 8. For the standard death creating the missing 5 frames or extending the 3 to 8 is a bit prohibitive for mods which have a lot of spritesheets already. 3 DeathFrames for the messy ones works okay but it could look a lot better with 8.

Currently getDeathFrames is attached to RuleArmor which makes sense and of course limits a setDeathFrames as this information can be read-only. Would it be viable to add an override with BattleUnit.setDeathFrames?

Thanks for possible considerations.

18
Open Feedback / Re: Incendiary mod
« on: February 14, 2023, 07:14:02 pm »
ToMorale is a factor, so in essence yes.

But what you have to consider is damageModifier and armor. Let's say you hit a target and roll for 100 power. The target has a damageModifier to the related damageType of 50 % and the affected side of armor has a value of 20.

finalPower = power * damageModifier - remainingArmor
30 = 100 * 50 % - 20
Assuming ToHealth is 1 then it will turn into 30 Health Damage
Assuming ToMorale is 1.7 then it will also turn into 51 Morale Damage

Note that the 100 power in the scenario above is the result of a random value between 0-200% / 50-150% / etc. using the ammo's/weapon's power.

19
40k / Re: [ADDON] ROSIGMA
« on: February 14, 2023, 07:09:00 pm »
A small bug found its way into release.
This will turn the frag grenades back to the expected behavior.

20
Released Mods / [UFO][OXCE][Graphic(al Violence)] Gibs of Gory
« on: February 14, 2023, 07:07:23 pm »
I wanted to try that for a while now.

Gibs of Gory (word play on Wings of Glory) is a little graphical mod that exchanges the death Animations depending on used damage type and remaining weapon power.

Whenever the damage past setting health to 0 exceeds maxHealth, the target will turn to gibs, scorch marks (Plasma, Incendiary) or goo (Acid).

You can download it here.

Credits go to Brain_322 for sprites and Yankes for showing me the wonderful value of RuleList.current.

21
As a side note: I did try my hand at that feature. Major parts of it was integrated in this pull request.
The original proof of concept behavior was that all crafts get the same target. I am not sure how we came to the decision (maybe it was me) but I went for setting up a framework so crafts follow the first craft/the wing leader instead by setting the first craft as destination. For the wing leader framework I did try my hand at intercepting non-hunter-killer with wing crafts having the wing leader as their destination. You can have a look here. One thing I am not sure about this implementation is what happens if you have two wings following two different UFOs.

I suppose the much easier solution is to change the current implementation to the proof of concept behavior. For this purpose you can edit this line to L315 below.

Code: [Select]
310 for (std::vector<Craft*>::iterator i = _crafts.begin(); i != _crafts.end(); ++i)
311 {
312 if ((*i) != _crafts.front())
313 {
314 //(*i)->setDestination(_crafts.front()); // follow wing leader
315 (*i)->setDestination(_target); // get the same target as the wing leader
316 }

You can test the feature by starting a new vanilla campaign. Wait for the first UFO. Open your interceptor window. Shift-leftclick Interceptor-1. Leftclick Interceptor-2. Target UFO.

22
Open Feedback / Re: Incendiary mod
« on: February 11, 2023, 05:30:58 pm »
I assume by look you mean that you want to edit the sprite.

Step one is probably to get the weapon sprites. Each weapon has 3 kind of sprites: Bigobs = Inventory pictures, Handobs = the sprites drawn as held by the soldier/alien for each of the 8 directions and floorob = the sprite on the battleScape floor/ground.

You can obtain the original files when you use Pckview as part of MapView to open the game files. MapView is actually a tool to create map tiles with but contains additional tools. The interesting files can be found in the UFO/UNITS directory: BIGOB.PCK, FLOOROB.PCK and HANDOB.PCK. Using PckView you can export the sprites as PNG for further editing.
Note that when you add elements to extraSprites Handobs will use 8 indices. That means if your gun handob with 8 directions is index 200, the next one should be 208 (200+8).

As for tools to edit the sprites with you can search around on the forum. Some are listed here and the community has made additional tools such as the UnitSprite Studio.

Edit: I meant Handobs when talking about the 8 indices with the 200+8 example

23
You can open UFO-or-TFTD/GEOGRAPH/BASEBITS.pck with PckView which is part of MapView and extract the sprites with it.

24
There are currently two ideas floating around in my head:
- Change turrets of the craft vehicle depending on a specific craftweapon slot (battleScape maptile, spawner grenade, createUnit script with setSpawnUnit, etc.)
- Some kind of battleScape auto-resolve item/craft ammo (for example something like a tactical nuke, singularity bomb)
The latter can probably be resolved differently with an item in the craft inventory that when primed before the battle starts a script will do some magic or with a unit like the orbital beacon. So I am going to focus on the first one.

Essentially my suggestion is to add
Code: [Select]
BattleGame.getCraft [ptr/ptre Craft]
Craft.getCraftWeapon [int (slot)] [ptr/ptre CraftWeapon]
CraftWeapon.getType [text]
CraftWeapon.getAmmoQuantity [int]
CraftWeapon.setAmmoQuantity [int] # optional

Side possibilities for ptre are missions that
- cost craftWeapon ammo and therefore money to deploy specific turrets/close air support.
The ammo would be reduced by a script and it wouldn't matter whether the battleScape ammo is used up on battleScape or not.
... Thinking about it some more, this will probably also create an edge case that in a dogfight the craft will try to expend ammo for the battleScape related craftWeapon.
Could a craftWeapon with range: 0 and ammoMax: 1 create strange behaviour?

- damage/repair hull, etc. (Craft.getFuel/setFuel/getHull/etc.)
for modifying the craft's fuel etc, there are concerns that fuel is modified in such a way that the craft could technically not return to base. This might already be covered  with a sanity check forcing the craft to return to base. Also hull should not be set-able to zero or above the total health.

For this suggestion it's completely sufficient if the type of equipped craftWeapon can be obtained and maybe that the ammo count can be set between 0 and ammoMax.

Thanks for all possible considerations.


25
To my understanding you are supposed to put genMissionRaceFromAlienBase on the alienDeployments related to the base (f. ex. STR_ALIEN_BASE_ASSAULT) and not on the ufo (STR_FLEET_SUPPLY_CRUISER).

When you look in the reference where you can find a description for genMissionRaceFromAlienBase, it says above the table
"The following group of attributes is related only to alien bases"


26
Open Feedback / Re: Incendiary mod
« on: February 06, 2023, 10:12:09 pm »
No clue if there is one for vanilla.
But you can make your own sub mod. For example you can pick up the pistol mod to get you started.
Then you have to set up items: for type: STR_INCENDIARY_ROCKET, etc. and add a damageAlter with RandomType: 2.
For learning about items:, type, damageAlter and RandomType, checkout the handy reference.
Happy modding.

27
40k / Re: 40k Bug/crashes/problemĀ“s report
« on: February 06, 2023, 10:05:59 pm »
You can download the 40k submods for factions and stat strings from this repository.

28
Help / Re: Retaliation missions are spawning with unexpected results?
« on: February 04, 2023, 10:55:56 am »
Quote
Could it be the anchor and refNode: is duplicating the "STR_IAR_LOW_THREAT: 100" raceWeights: in both the Advanced & Elite versions causing the lists to unintentionally read like this:
Spoiler:
Code: [Select]
# [=] Alien Retaliation [=]
# [=] Alien Retaliation [=] <Elite>
  - type: STR_ALIEN_RETALIATION_ELITE
    refNode: *STR_ALIEN_RETALIATION
    raceWeights:
      0:
          STR_IAR_LOW_THREAT: 100 # <====== Potential unexpected duplication
          STR_IAR_HIGH_THREAT: 100


This is exactly what happens (see attached screenshot).

You will need to set
Code: [Select]
# [=] Alien Retaliation [=] <Elite>
  - type: STR_ALIEN_RETALIATION_ELITE
    refNode: *STR_ALIEN_RETALIATION
    raceWeights:
      0:
          STR_IAR_LOW_THREAT: 0 # <--------------
          STR_IAR_HIGH_THREAT: 100

You will also need to do that if you ever want to disable missions created by regions.

29
Help / Re: Retaliation missions are spawning with unexpected results?
« on: February 02, 2023, 08:42:30 am »
Two, maybe three notes:
- When shooting down USOs, the used retaliation is part of alienRaces: retaliationMission/retaliationMissionWeights (see reference). Without any settings they will pick any alienMission with objective: 4
- Debug mode sets all research to true. This also includes STR_THE_ULTIMATE_THREAT.
- For debugging purposes you are best of to provide a savegame on the last day of the month. When savescum (advanced settings) is not enabled, the next month shouuuuullld.... be the same, maybe.

30
Help / Re: UFOs unexpectedly stop spawning after the month of May?
« on: February 01, 2023, 12:38:55 am »
Your mod factually creates missions. For example my savegame for August of the first year says
Spoiler:
Code: [Select]
alienMissions:
  - type: STR_ALIEN_RESOURCE_RAID_ELITE
    region: STR_SOUTH_PACIFIC
    race: STR_IAR_HIGH_THREAT
    nextWave: 3
    nextUfoCounter: 0
    spawnCountdown: 8190
    liveUfos: 0
    uniqueID: 21
    missionSiteZone: -1
  - type: STR_ALIEN_SUPPLY
    region: STR_SOUTH_PACIFIC
    race: STR_IAR_LOW_THREAT
    nextWave: 0
    nextUfoCounter: 0
    spawnCountdown: 5970
    liveUfos: 0
    uniqueID: 22
    alienBase:
      lon: 4.7983683028015633
      lat: 0.51529618532766863
      type: STR_ALIEN_BASE
      id: 4
    missionSiteZone: -1
  - type: STR_ALIEN_SURFACE_ATTACK_ELITE
    region: STR_SOUTH_ATLANTIC
    race: STR_IAR_LOW_THREAT
    nextWave: 0
    nextUfoCounter: 0
    spawnCountdown: 120
    liveUfos: 0
    uniqueID: 23
    missionSiteZone: 0
  - type: STR_ALIEN_PROBE_MISSION_ELITE
    region: STR_SOUTH_CHINA_SEA
    race: STR_IAR_HIGH_THREAT
    nextWave: 0
    nextUfoCounter: 0
    spawnCountdown: 12600
    liveUfos: 0
    uniqueID: 24
    missionSiteZone: -1
  - type: STR_ALIEN_INFILTRATION_ELITE
    region: STR_SOUTH_PACIFIC
    race: STR_IAR_HIGH_THREAT
    nextWave: 0
    nextUfoCounter: 0
    spawnCountdown: 12810
    liveUfos: 0
    uniqueID: 25
    missionSiteZone: -1


Looking at the first mission STR_ALIEN_RESOURCE_RAID_ELITE in alienMissions it says

Spoiler:
Code: [Select]
  - type: STR_ALIEN_RESOURCE_RAID_ELITE
    refNode: *STR_ALIEN_RESOURCE_RAID
    raceWeights:
      0:
          STR_IAR_HIGH_THREAT: 100
    waves:
      - ufo: STR_SURVEY_SHIP_ELITE
        count: 1
        trajectory: P0
        timer: 15000
      - ufo: STR_ESCORT_ELITE
        count: 1
        trajectory: P1
        timer: 18000
      - ufo: STR_CRUISER_ELITE
        count: 1
        trajectory: P3
        timer: 9000
      - ufo: STR_HEAVY_CRUISER_ELITE
        count: 1
        trajectory: P3
        timer: 9000
      - ufo: STR_HEAVY_CRUISER_ELITE
        count: 2
        trajectory: P4
        timer: 60

but there is no ufos: STR_SURVEY_SHIP_ELITE, etc.
The game probably tries to create an UFO and seems to default to spawn nothing.

Pages: 1 [2] 3 4 ... 12