Author Topic: OXCE (OpenXcom Extended) main thread  (Read 292961 times)

Offline Juku121

  • Commander
  • *****
  • Posts: 560
  • We're all mad here.
    • View Profile
Re: OXCE (OpenXcom Extended) main thread
« Reply #1170 on: July 13, 2022, 10:48:55 am »
What do you mean by "just passed the whole install over"? The whole OS or just OXCE in particular?
OXCE plus the mod plus other necessities, of course. I also changed OS-s, so even if I wanted to do the first that wouldn't have worked.

Have you tried a fresh install (of OXCE)?
No, but I doubt it'd change much. A 'fresh install' of OXCE is basically pasting a few files over, anyway.

But just to satisfy my (and your) curiosity, I upgraded to 7.5.19. No change.
« Last Edit: July 13, 2022, 10:51:47 am by Juku121 »

Offline Meridian

  • Global Moderator
  • Commander
  • ***
  • Posts: 7729
    • View Profile
Re: OXCE (OpenXcom Extended) main thread
« Reply #1171 on: July 15, 2022, 11:54:20 am »
New OXCE v7.6 is up.

2022-07-15
QoL:
 - Added mouse wheel scrolling to Monthly Report UI: https://openxcom.org/forum/index.php/topic,10510.0.html
 - Ability to persist PL/NV/B toggles: https://openxcom.org/forum/index.php/topic,10629.msg147476.html#msg147476
 - Added Energy toggle to pathfinding preview (Options > Battlescape): https://openxcom.org/forum/index.php/topic,9556.0.html
 - Save file formatting less verbose in selected cases (functionally same, no performance gain or loss, smaller file size, easier to read by humans)

Features:
 - AI: aliens are now capable of running during escape battle action (if running enabled by armor, and 50% probability)
 - AI: aliens (leeroys only) are now capable of running during aggro if they have a lot of energy (40% of stamina or more)
 - Added support for checking required OXC engine (e.g. OXC, OXCE, FtA, etc.) - `requiredExtendedEngine` in metadata.yml
 - Removed `enforcedExtendedVersion` attribute in metadata.yml (`requiredExtendedVersion` attribute now enforces!)

Modding:
 - Ability to change tile move cost per armor: https://openxcom.org/forum/index.php/topic,6586.msg145137.html#msg145137
 - New movement type Sneaking = force walking even if you can fly (using Alt modifier): see link above
 - Ability to change cost of moving item in the inventory: https://openxcom.org/forum/index.php/topic,6586.msg145244.html#msg145244
 - Custom object counters for completed research: https://openxcom.org/forum/index.php/topic,10318.msg146284.html#msg146284
 - Craft preview: ability to reveal/not reveal the whole map: https://openxcom.org/forum/index.php/topic,10370.msg147475.html#msg147475
 - Ufopedia: unhardcoded colors for Text and TextImage articles: https://openxcom.org/forum/index.php/topic,10484.0.html
 - Ufopedia: draw armor sprite on the background: https://openxcom.org/forum/index.php/topic,10425.0.html

Scripting:
 - Ability to change movement type during battle: https://openxcom.org/forum/index.php/topic,6586.msg145244.html#msg145244
 - Ability to set negative health by script (i.e. overkill): https://openxcom.org/forum/index.php/topic,10535.msg146195.html#msg146195

Bugfixes:
 - (possible breaking change in scripts) Fixed broken fire extinguisher: https://openxcom.org/forum/index.php/topic,10522.msg145855.html#msg145855
 - Fixed trying to delete/process a research project twice: https://openxcom.org/forum/index.php/topic,10504.msg145545.html#msg145545
 - Craft preview: bugfix for crash when craft landed and craft deployed are different
 - Craft preview: bugfix: allowed to dismantle the access lift, if it's the last facility in the base: https://openxcom.org/forum/index.php/topic,6413.msg144635.html#msg144635
 - Craft preview: bugfix: check existence of the battlescape map for preview: https://openxcom.org/forum/index.php/topic,10370.msg145652.html#msg145652
 - Fixed AI using unusable weapons during xcom base defense: https://openxcom.org/forum/index.php/topic,4058.msg145954.html#msg145954
 - Civilians shouldn't destroy xcom bases (see above)
 - Fixed storage check corner case: https://openxcom.org/forum/index.php/topic,10595.0.html
 - Fixed startup checks when sound is muted: https://openxcom.org/forum/index.php/topic,10541.0.html
 - PromotionsState screen now includes in-transit soldiers if promoted (by karadoc): https://github.com/MeridianOXC/OpenXcom/commit/050b86483422e18eb861fc8c98f63df215290e12
 - lowAccuracyHitCounter fix (by Delian): https://github.com/OpenXcom/OpenXcom/commit/761a978cbbe52752ee9a2f1a46cc065fef46e587

Download: https://openxcom.org/forum/index.php/topic,5258.0.html

Ruleset validator was updated.
Wiki ruleset reference was updated.
Auto-update will be available on Windows in 2-3 weeks.

Offline BlackStaff

  • Colonel
  • ****
  • Posts: 319
    • View Profile
Re: OXCE (OpenXcom Extended) main thread
« Reply #1172 on: July 15, 2022, 05:14:34 pm »
New OXCE v7.6 is up.
Thank you very much !

Offline Ethereal

  • Commander
  • *****
  • Posts: 556
    • View Profile
Re: OXCE (OpenXcom Extended) main thread
« Reply #1173 on: July 16, 2022, 04:20:07 pm »
New OXCE v7.6 is up.

Thank you for your work and update.

Offline Ethereal

  • Commander
  • *****
  • Posts: 556
    • View Profile
Re: OXCE (OpenXcom Extended) main thread
« Reply #1174 on: July 19, 2022, 07:03:07 am »
Is there a way to disable the vanilla psionics calculation formula? Just turn it off so that the probability of a successful psi attack is 100% and is reduced only by the "psiDefence" parameter in armor, and increased only by the "accuracyXXX..." parameter in items.

Offline Yankes

  • Moderator
  • Commander
  • ***
  • Posts: 2841
    • View Profile
Re: OXCE (OpenXcom Extended) main thread
« Reply #1175 on: July 19, 2022, 10:05:05 am »
Yes, y-script hook `tryPsiAttackItem`, it is responsible for default algorithm, override `psi_attack_success` to any value you want (value `100` is 100%).

Offline Ethereal

  • Commander
  • *****
  • Posts: 556
    • View Profile
Re: OXCE (OpenXcom Extended) main thread
« Reply #1176 on: July 19, 2022, 10:37:50 am »
Yes, y-script hook `tryPsiAttackItem`, it is responsible for default algorithm, override `psi_attack_success` to any value you want (value `100` is 100%).

I am very weak in scripting, but I found this -

Code: [Select]
    tryPsiAttackUnit:
      - offset: 23   # for Scripted Items - Automatic Success
        code: |
          var int battle_type;
          var ptr RuleItem item_rule;
          var int energy_max;
         
          item.getRuleItem item_rule;

          item_rule.getBattleType battle_type;
         
          if eq battle_type 9; # scripted psi amp
            if or eq battle_action 13 eq battle_action 14;
              debug_log "PsiAttack with scripted item. Automatic success!";
              set psi_attack_success 1;
            end;
          end;
          return psi_attack_success;

Can this be used as a template for "tryPsiAttackItem"?

In addition, it is necessary that the psi-defense also depends solely on the "psiDefence" indicator in the armor.
« Last Edit: July 19, 2022, 10:40:13 am by Ethereal »

Offline Yankes

  • Moderator
  • Commander
  • ***
  • Posts: 2841
    • View Profile
Re: OXCE (OpenXcom Extended) main thread
« Reply #1177 on: July 20, 2022, 12:14:27 pm »
It could be, there are some differences between this too hooks, but basic scripts should be compatible between them, best is look in "verbose logging" to see what parameters are available in both cases, btw it should show too default script for `tryPsiAttackItem` that is responsible for attack algorithm.

Use this as template:
Code: [Select]
var int r;
set psi_attack_success 0; #override original value!!
random.randomRange r 0 55;
add psi_attack_success attack_strength;
add psi_attack_success r;
sub psi_attack_success defense_strength;
sub psi_attack_success distance_strength_reduction;
return psi_attack_success;

Offline Ethereal

  • Commander
  • *****
  • Posts: 556
    • View Profile
Re: OXCE (OpenXcom Extended) main thread
« Reply #1178 on: July 20, 2022, 06:17:28 pm »
You know better. My knowledge of scripts is barely enough to edit them (and not only here, but also in Follaut, and in HMM-3 WoG and so on), but nothing more. Apparently, a special mindset is needed for this, but I, like Geppetto, can only master the serial production of wooden robots of the "Pinocchio" class.

Offline Delian

  • Colonel
  • ****
  • Posts: 228
    • View Profile
Re: OXCE (OpenXcom Extended) main thread
« Reply #1179 on: July 28, 2022, 02:01:51 pm »
A fatal error has occurred: Interface articleTextImage not found
« Last Edit: July 28, 2022, 02:31:49 pm by Delian »

Offline Meridian

  • Global Moderator
  • Commander
  • ***
  • Posts: 7729
    • View Profile
Re: OXCE (OpenXcom Extended) main thread
« Reply #1180 on: July 28, 2022, 02:19:10 pm »
Update the whole OXCE, not just the EXE.

Offline Delian

  • Colonel
  • ****
  • Posts: 228
    • View Profile
Re: OXCE (OpenXcom Extended) main thread
« Reply #1181 on: July 28, 2022, 02:30:22 pm »
Works now ::)

Offline robin

  • Commander
  • *****
  • Posts: 1183
  • ULTIMATE ROOKIE
    • View Profile
    • Email
Re: OXCE (OpenXcom Extended) main thread
« Reply #1182 on: July 30, 2022, 02:25:51 pm »
Quote
aliens are now capable of running during escape battle action
@Meridian: what is that?


I don't get the object title when I use rect_text with type_id: 7 (AKA text image), see attachment.
Ruleset reference says the following about rect_text: In OXCE, it is also applicable to TextImage articles.
Code: [Select]
  - id: STR_DIMPROBE
    type_id: 7
    section: STR_XCOM_CRAFT_ARMAMENT
    image_id: UFOPAEDIA_IMG_DIMPROBE
    rect_text:
      x: 5
      y: 40
      width: 140
      height: 100
    #text_width: 140  # this works correctly
    text: STR_DIMPROBE_UFOPAEDIA

This is not a problem since I'm just going use text_width, but I still wanted to report this.
« Last Edit: July 30, 2022, 02:28:24 pm by robin »

Offline Yankes

  • Moderator
  • Commander
  • ***
  • Posts: 2841
    • View Profile
Re: OXCE (OpenXcom Extended) main thread
« Reply #1183 on: July 30, 2022, 02:47:25 pm »
@Meridian: what is that?
When alien decide to run away, and can run, it will run instead of walking.

Offline Rangerh

  • Colonel
  • ****
  • Posts: 102
    • View Profile
Re: OXCE (OpenXcom Extended) main thread
« Reply #1184 on: August 01, 2022, 05:09:06 pm »
Never had the situation before so i never thought about it.

But after looking in all the menus i can't find anything about it, so is it possible in your base to assign an equipment to your soldier without using the Equip Craft -> Select a Ship -> Equipment -> Inventory ?