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 - The Martian

Pages: [1] 2 3 ... 18
1
Help / Re: Remove Weight Encumbrance
« on: January 21, 2020, 02:24:46 am »
My suggestion would be to open the *.rul file that contains the armors: section and add the following to each X-Com wearable armor.

Code: [Select]
    weight: -200
Or whatever weight value suits you.

By making that number a very large negative you'll complete side step the game's weight mechanic as any soldier equipped with that armor has their weight reduced (Or increased) by that amount.

This should be much easier and faster than altering each individual carriable item's weight value and will leave the throwing mechanic's weight based distance intact.


Example:

Code: [Select]
  - type: STR_PERSONAL_ARMOR_UC
    spriteSheet: XCOM_1.PCK
    spriteInv: MAN_1
    spriteFaceGroup: 6
    spriteFaceColor: [96, 96, 96, 96, 160, 160, 163, 163] #M0 F0 M1 F1 M2 F2 M3 F3
    spriteHairGroup: 9
    spriteHairColor: [144, 144, 164, 164, 245, 245, 164, 164] #M0 F0 M1 F1 M2 F2 M3 F3
    corpseBattle:
      - STR_CORPSE_ARMOR
    storeItem: STR_PERSONAL_ARMOR
    weight: 5 # <---------- THIS IS THE LINE OF CODE TO CHANGE
    frontArmor: 50
    sideArmor: 40
    rearArmor: 30
    underArmor: 30
    damageModifier:
      - 1.0
      - 1.0
      - 0.8
      - 1.0
      - 1.0
      - 1.0
      - 0.9
      - 1.0
      - 1.1
      - 1.0
    loftempsSet: [ 3 ]

Changes to this:

Code: [Select]
  - type: STR_PERSONAL_ARMOR_UC
    spriteSheet: XCOM_1.PCK
    spriteInv: MAN_1
    spriteFaceGroup: 6
    spriteFaceColor: [96, 96, 96, 96, 160, 160, 163, 163] #M0 F0 M1 F1 M2 F2 M3 F3
    spriteHairGroup: 9
    spriteHairColor: [144, 144, 164, 164, 245, 245, 164, 164] #M0 F0 M1 F1 M2 F2 M3 F3
    corpseBattle:
      - STR_CORPSE_ARMOR
    storeItem: STR_PERSONAL_ARMOR
    weight: -200   # <---------- THIS IS THE LINE OF CODE TO CHANGE
    frontArmor: 50
    sideArmor: 40
    rearArmor: 30
    underArmor: 30
    damageModifier:
      - 1.0
      - 1.0
      - 0.8
      - 1.0
      - 1.0
      - 1.0
      - 0.9
      - 1.0
      - 1.1
      - 1.0
    loftempsSet: [ 3 ]

2
Work In Progress / Re: [WIP] Chronicles
« on: January 20, 2020, 11:00:37 pm »
and there is it, your nightmare in a future:
Spoiler:
Not only is it a cool new alien unit, but it comes with a bonus toy on opening.

Great work Nord!

3
Help / Re: spriteFaceColor spriteHairColor spriteRankColor
« on: January 19, 2020, 04:54:08 am »
I don't understand how this works yet myself but I believe this post in another thread is related to your question, so I shall link it in case it helps.

If you add this to the armors.rul to the corresponding armor (for mods with a standard set of soldiers):

     spriteFaceGroup: 6
     spriteFaceColor: [96, 96, 96, 96, 160, 160, 163, 163] # M0 F0 M1 F1 M2 F2 M3 F3
     spriteHairGroup: 9
     spriteHairColor: [144, 144, 164, 164, 245, 245, 164, 164] # M0 F0 M1 F1 M2 F2 M3 F3

then ethnicity will be visible on the battlescape.

4
Resources / Re: [UNIT][GRAPHICS] Cyber Cylinder
« on: January 18, 2020, 10:26:22 pm »
Those Cylinders are freaking awesome, The Martian.

Thank you Efrenespartano, please feel free to make use of them.

Pyramid? :)

X-Com is going to need something a lot better than their conventional weaponry if that starts showing up during night missions.

It would be pretty cool though.



I wonder if any of the current unit sprite animation sets would allow for the blade to be dragged behind the unit like that?

Edit:
To clarify what I mean is without building a large 2x2 unit are there any drawingRoutine: settings that would accommodate having a held object with a length that would stick out that far behind the unit?

5
Resources / Re: [GRAPHICS] [RESOURCES] Dioxine's Airtight Hangar
« on: January 18, 2020, 09:46:54 pm »
I like that recd cannon thingh! Don't know whether it's in xpiratez or not
A version of that red cannon is indeed included amongst the massive arsenal found in XPiratez.

6
Released Mods / Re: Question to Endless War uber-mod
« on: January 09, 2020, 01:01:45 am »
(well, sorry, a little bit off-topic, but i dont see (wghere is) the its topic about Endless War (where has its thread)

Unless I'm misunderstanding what you are asking the thread you are looking for can be found HERE.

7
Suggestions / Re: Thin man and xcom 2012 style enemies
« on: January 07, 2020, 01:44:42 am »
I believe you can encounter the Mechtoid in War of Shadows.

8
Resources / Re: New ships [UFO/TFTD]
« on: January 04, 2020, 11:20:23 am »
however asymmetric shapes cannot fly / navigate ::)

The alien's technology is beyond our understanding.



Thankfully a few well placed torpedoes still send them straight to the bottom.


9
Resources / Re: New ships [UFO/TFTD]
« on: January 04, 2020, 09:32:03 am »
№: GT0005.
Class Ship: Double Scout.
Size:  Average.
Game: TFTD.


I like the look of this design.

The middle section immediately offers two methods of attack.

Do you secure the doors on the left USO first before storming the center section and entering the craft on the right?

Or instead come at it from the north and take the increased risk that an alien will step out of either ship and fire into the corridor between the two craft?

I also like that the exterior of the left ship offers a nook that a soldier can duck into for cover while slinking around the sides.

Great work Wolwerin.

10
Work In Progress / Re: [WIP] Chronicles
« on: January 04, 2020, 09:14:00 am »
Also here is improved spikeboar inventory pic, if someone wants it.
I want it, thank you.

11
Does the armored vest preserve the ethnicity of soldiers when worn?
I can confirm it does on the inventory screen.

Downloads attached (extra weapons mod contains small rockets too).
Thank you, I've been having fun using that weapon set.

12
Help / Re: A few questions about this "Poison Script" (OXCE)
« on: January 04, 2020, 08:27:19 am »
You mess up this file, what editor you used to edit this files?
Thank you for catching that.

Normally I use Notepad++ but for those files I used the editor that came with Linux Mint called simply "Text Editor".

I'll stick with using Notepad++ exclusively while editing code from now on.






I'm only starting to read through YAML's documentation so my attempts to alter your script are mostly through experimentation mixed with some guess work and copying the already present formatting and syntax.

My ideal goal would be if a weapon or ammo could be configured so that it had four values:
(1) The amount of damage the poison inflicts per turn.
(2) The amount of turns the poison will last.
(3) The amount the poison damage is reduced by each turn until it hits 0 and the effect is removed.
(4) The amount being struck by this weapon reduces the remaining poison time on an already poisoned unit.


If the last two variables can be applied to an existing poisoned state they can also be used on defencive X-Com equipment to cure the poison afflictions. Either immediately on striking the unit using the fourth variable or gradually via a reduction in damage each turn using the third variable.


So far I've noticed that if "sub poison 1;" is changed to "sub poison 0;" the strength of the poison damage does not decrease between turns.
(So I'm proceeding under the assumption that the "sub" command is to subtract 1 from the poison variable)

When using an item with "POISON_STRENGTH: 1" an infected soldier loses 2 HP per turn while poisoned. I'm not sure why this is 2 and not 1 hp though.

When using an item with "POISON_STRENGTH: 2" an infected soldier loses 4 HP per turn while poisoned.

When using an item with "POISON_STRENGTH: 3" an infected soldier loses 6 HP per turn while poisoned.

So it is pretty clear the POISON_STRENGTH value is being doubled, but I haven't been able to pick out the part of the code that is doing that yet but it does seem to be related to POISON_SUSCEPTIBILITY.


I think it is this section of the code:
Code: [Select]
            mul strength susceptibility;
            div strength 10;

I'm assuming that the command "mul" is multiply and "div" is divide.



POISON_SUSCEPTIBILITY appears to be a resistance setting with 5 as normal damage (Matching the POISON_STRENGTH value) and 10 as double that.

Code: [Select]
      POISON_STRENGTH: 2
POISON_SUSCEPTIBILITY: 10

36
32
28
24
20
16
12
8
4
0  <Dead>

      POISON_STRENGTH: 2
POISON_SUSCEPTIBILITY: 20

36
28
20
12
4
0  <Dead>

      POISON_STRENGTH: 2
POISON_SUSCEPTIBILITY: 5

36
34
32
30
28
26
24
22
20
18
16
14
12
10
8
6
4
2
0 <Dead>



By changing "sub poison 0;" it appears the poison effect no longer runs out.

So I tried counteracting this by adding a new variable POISON_TIME.

Code: [Select]
extended:
  tags:
    RuleItem:
      POISON_STRENGTH: int
      POISON_TIME: int
    RuleArmor:
      POISON_SUSCEPTIBILITY: int
    BattleUnit:
      POISON_LEVEL: int

and altered the code in the scripts: and items: sections as follows:

Code: [Select]
  - type: STR_POISON_EXAMPLE_GUN_AMMO
    tags:
      POISON_STRENGTH: 2
      POISON_TIME: 4

    newTurnUnit:
      - offset: 1
        code: |
          var int poison;
          var int hp;
          unit.getTag poisonTime Tag.POISON_TIME;
          unit.getTag poison Tag.POISON_LEVEL;
          if gt poison 0;
            unit.getHealth hp;
            sub hp poison;
            unit.setHealth hp;
            sub poisonTime 1;
            unit.setTag Tag.POISON_LEVEL poisonTime;
          end;
          return;

However now the unit just appears to change to a green colour and never removes the poison or takes any damage from it.

I thought that the line "unit.getTag poisonTime Tag.POISON_TIME;" was performing the following action:
(1) "unit.getTag"
The poisoned unit's stored tags: values are loaded.

(2) "poisonTime Tag.POISON_TIME"
The variable 'poisonTime' stores the value contained on the poisoned unit in the Tag.POISON_TIME variable.

Is that incorrect?



I've attached a *.zip of the code to make it easier to see what I've done.

13
Help / Re: A few questions about this "Poison Script" (OXCE)
« on: January 03, 2020, 07:59:55 am »
No, only this part need be copy-pasted to any file that want interact with this script:

Code: [Select]
extended:
  tags:
    RuleItem:
      POISON_STRENGTH: int
    RuleArmor:
      POISON_SUSCEPTIBILITY: int
    BattleUnit:
      POISON_LEVEL: int

If I add that code to the *.rul files containing items: or armors: sections the armor and weapon equipment doesn't appear when I try to test it in the "New Battle - Mission Generator" from the main menu.

However if I only have this block of code inside of the *.rul file containing the scripts: section it works:

Code: [Select]
extended:
  tags:
    RuleItem:
      POISON_STRENGTH: int
    RuleArmor:
      POISON_SUSCEPTIBILITY: int
    BattleUnit:
      POISON_LEVEL: int

Have I misunderstood your instructions?

I've attached two *.zip files to this post to better show what I mean, one has the *.rul files with the above code contained in the items: armors: & scripts: files. The other only contains the code for the extended: section inside of the scripts: *.rul.

14
Resources / Re: [UNIT][GRAPHICS] Cyber Cylinder
« on: January 01, 2020, 04:09:28 pm »
I'll look forward to seeing what you are creating Gaffer.

15
Help / A few questions about this "Poison Script" (OXCE)
« on: January 01, 2020, 03:54:40 pm »
This poison script created by Yankes looks very useful.

Simple poison bullets that do damage over time:

Code: [Select]
extended:
  tags:
    RuleItem:
      POISON_STRENGTH: int
    RuleArmor:
      POISON_SUSCEPTIBILITY: int
    BattleUnit:
      POISON_LEVEL: int
  scripts:
    damageUnit:
      - offset: 1
        code: |
          var int susceptibility 0;
          var int strength 0;
          var int temp 0;
          var ptr RuleArmor armor_rule;
          var ptr RuleItem item_rule;
         
          unit.getRuleArmor armor_rule;
          armor_rule.getTag susceptibility Tag.POISON_SUSCEPTIBILITY;
          damaging_item.getRuleItem item_rule;
          item_rule.getTag strength Tag.POISON_STRENGTH;
         
          debug_log 1 strength;
          debug_log 2 susceptibility;
          if and gt strength 0 gt susceptibility 0;
          debug_log 3 3;
            mul strength susceptibility;
            div strength 10;
            unit.getTag temp Tag.POISON_LEVEL;
            if lt temp strength;
              unit.setTag Tag.POISON_LEVEL strength;
            end;
          end;
         
          return;
    newTurnUnit:
      - offset: 1
        code: |
          var int poison;
          var int hp;
          unit.getTag poison Tag.POISON_LEVEL;
          if gt poison 0;
            unit.getHealth hp;
            sub hp poison;
            unit.setHealth hp;
            sub poison 1;
            unit.setTag Tag.POISON_LEVEL poison;
          end;
          return;
    recolorUnitSprite:
      - offset: 4
        code: |
          var int poison;
          unit.getTag poison Tag.POISON_LEVEL;
          if gt poison 0;
            set_color new_pixel 4; #green color
          end;
          return new_pixel;
items:
  - type: STR_PISTOL_CLIP
    tags:
      POISON_STRENGTH: 6
     

armors:
  - type: STR_SOME_MARTIAN
    tags:
      POISON_SUSCEPTIBILITY: 20

I have a few questions about how it is used.


(Question #1):
Which *.rul file does it need to be in to function?

Can I place it in its own PoisonScript.rul file or does it need to be in the same file as the *.rul that has the items: section in it?



(Question #2):
I'm guessing that the variable POISON_STRENGTH: on the item and POISON_SUSCEPTIBILITY: on the unit armor determine how much HP is lost by a poisoned unit per turn and either the number of turns the unit is poisoned or a resistance to the applied poison effect, I'm not sure exactly which from trying to read the code.

How do this work?




(Question #3):
Although the above question may answer this, I'll ask directly as it would be odd to see mechanical tanks succumbing to the effects of poisoning.

Is it possible to prevent a unit from being able to be afflicted with the poison script's effects?



(Question #4):
If a unit is already poisoned and is afflicted with poison again, what happens?
. Does it overwrite the Poison with the new value?
. Does it overwrite the Poison with the highest value?
. Does increase the value of the Poison by combining both?
. Do the instances of Poison stack each running separately?
. Or can a unit already effected by poison not be poisoned further?



(Question #5):
The words recolorUnitSprite: seem to suggest that the poisoned unit will display its affliction by shifting colour to a greenish tint.

Is it possible to cause this effect to display as other colours?
(Red/Blue/Yellow)



(Question #6):
Can a poisoned unit be cured of the poison effect, or must it run its course once inflicted?

For example by a medkit?




(Question #7):
Is it possible to have several versions of this script running simultaneously if these three varables are renamed in an additional copy of the script which is also present in a *.rul file along side the original?
POISON_STRENGTH:
POISON_SUSCEPTIBILITY:
POISON_LEVEL:

For example:
POISON_STRENGTH_B:
POISON_SUSCEPTIBILITY_B:
POISON_LEVEL_B:


If that is possible and the scripts unit affliction display colour can be altered then one version of the script could cause an effected unit to become green coloured when hit while others could switch to different colours representing other damaging afflictions.
(Also they would both have separate instances of damage if applied to the same unit.)

This would be very useful.

Pages: [1] 2 3 ... 18