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

Offline Ethereal

  • Colonel
  • ****
  • Posts: 299
    • View Profile
Re: OpenXcom Extended (OXCE) main thread
« Reply #30 on: December 09, 2018, 11:48:10 pm »
I mean, it would be nice to undo all the changes in image support that have been made since version 5.0.

Offline Meridian

  • Global Moderator
  • Commander
  • ***
  • Posts: 4957
  • Aaand we're back!
    • View Profile
    • My Wiki
Re: OpenXcom Extended (OXCE) main thread
« Reply #31 on: December 09, 2018, 11:51:16 pm »
I mean, it would be nice to undo all the changes in image support that have been made since version 5.0.

For what reason?

Did something break?
(except for not loading 24bit images... which were not and still are not supported)
« Last Edit: December 09, 2018, 11:52:52 pm by Meridian »

Offline Ethereal

  • Colonel
  • ****
  • Posts: 299
    • View Profile
Re: OpenXcom Extended (OXCE) main thread
« Reply #32 on: December 10, 2018, 12:04:39 am »
For what reason?

Did something break?
(except for not loading 24bit images... which were not and still are not supported)

It's broken, from my point of view. I have are worth both version of. In version 5.0, images work, but in version 5.1 - they don't. The theoretical knowledge that they should not work does not change anything. The fact remains - in version 5.1 there are some changes that lead to the error of previously working images.

Offline Meridian

  • Global Moderator
  • Commander
  • ***
  • Posts: 4957
  • Aaand we're back!
    • View Profile
    • My Wiki
Re: OpenXcom Extended (OXCE) main thread
« Reply #33 on: December 10, 2018, 12:10:16 am »
I don't know what to answer to that.
From my point of view, it was broken before and now it is correct.

If you want more opinions, feel free to ask Yankes/SupSuper/Warboy... maybe they can provide more arguments, or explain better than I can.

Offline Yankes

  • Moderator
  • Commander
  • ***
  • Posts: 2078
    • View Profile
Re: OpenXcom Extended (OXCE) main thread
« Reply #34 on: December 10, 2018, 12:19:24 am »
As in 99% cases OXC use only 8bit images when I did refactor and optimization of surfaces I remove loading of multi byte graphics.

Offline Ethereal

  • Colonel
  • ****
  • Posts: 299
    • View Profile
Re: OpenXcom Extended (OXCE) main thread
« Reply #35 on: December 10, 2018, 12:28:17 am »
I don't know what the arguments, but... I have nothing to replace the images that are not working in the new version. That's the whole point. Apparently I will have to continue using version 5.0. Until find a replacement.
« Last Edit: December 10, 2018, 12:31:38 am by Ethereal »

Offline Meridian

  • Global Moderator
  • Commander
  • ***
  • Posts: 4957
  • Aaand we're back!
    • View Profile
    • My Wiki
Re: OpenXcom Extended (OXCE) main thread
« Reply #36 on: December 10, 2018, 12:32:51 am »
I don't know what the arguments, but... I have nothing to replace the images that are not working in the new version. That's the whole point. Apparently I will have to continue using version 5.0.

You don't know how to convert them into 8bit graphics?

I can help with that if you want... I assumed all modders know how to work with xcom palettes.

I made a small tutorial for luke83 here, maybe it helps you too: https://openxcom.org/forum/index.php/topic,6750.msg107256.html#msg107256

Offline Ethereal

  • Colonel
  • ****
  • Posts: 299
    • View Profile
Re: OpenXcom Extended (OXCE) main thread
« Reply #37 on: December 10, 2018, 12:50:57 am »
You don't know how to convert them into 8bit graphics?

I can help with that if you want... I assumed all modders know how to work with xcom palettes.

I made a small tutorial for luke83 here, maybe it helps you too: https://openxcom.org/forum/index.php/topic,6750.msg107256.html#msg107256

Thank you, of course, but it won't help me much. I don't know English. I'll try using Photoshop to do it. It'll work out eventually.

Offline ohartenstein23

  • Commander
  • *****
  • Posts: 1643
  • Flamethrowers fry cyberdisk circuits
    • View Profile
Re: OpenXcom Extended (OXCE) main thread
« Reply #38 on: December 10, 2018, 05:22:29 pm »
Hi Yankes, can I request that the awardExperience script be given a ptre to the attacking unit instead of a ptr? I'd like to be able to set a tag on a unit when it gains experience for handling of bonus stat gains at the end of a mission, but only once they've gained some experience.

Also, it looks like the getGeoscapeSoldier function is misspelled as getGeosapceSoldier compared to the pointer type GeoscapeSoldier.

Edit: I'm also having an issue with animating an item floorob - the following works to re-select the frames when the item is blit as a handob, but not for floorob. Outputting anim_frame to debug_log shows that it remains 0 for the floorob, and the selectItemSprite script doesn't have access to the BattleGame to get the frame either:
Code: [Select]
items:
  - type: STR_GRENADE
    floorSprite: 100
    scripts:
      selectItemSprite:
        if eq blit_part blit_item_floor;
          set sprite_offset anim_frame;
          mod sprite_offset 3;
          #debug_log 1 anim_frame;
          #debug_log 2 sprite_offset;
        end;

        add sprite_index sprite_offset;
        return sprite_index;
« Last Edit: December 10, 2018, 05:48:21 pm by ohartenstein23 »

Offline Yankes

  • Moderator
  • Commander
  • ***
  • Posts: 2078
    • View Profile
Re: OpenXcom Extended (OXCE) main thread
« Reply #39 on: December 10, 2018, 09:40:01 pm »
Changing `ptr` to `ptre` is usually one line change but I try keep everything read only, main reason is that I can reason what scripts can and what can't do.
If I change it to writable version should I prepare code to handle instant death of unit after this script run? Because of this I leaving this as read only.
One thing I could think is give access only to `tag` object as writable because game engine do not relay on this values.
Btw maybe there is other place where you logic could be placed? Right now after mission you can access `battleUnit.Exp.*` where all stats grain are stored.

For function, you misspelled misspelled function too :D, I will fix it right now.

For script, right, I do not propagate it there, this will be fix too.

Offline ohartenstein23

  • Commander
  • *****
  • Posts: 1643
  • Flamethrowers fry cyberdisk circuits
    • View Profile
Re: OpenXcom Extended (OXCE) main thread
« Reply #40 on: December 10, 2018, 09:47:13 pm »
Ah, I missed the BattleUnit.Exp.<x> in the documentation, that does what I need it to do, thanks! I think it'd still be nice to have access to setting tags even where we have ptr instead of ptre, but not necessary for this application.

Offline Yankes

  • Moderator
  • Commander
  • ***
  • Posts: 2078
    • View Profile
Re: OpenXcom Extended (OXCE) main thread
« Reply #41 on: December 10, 2018, 10:09:39 pm »
bugs fixed, now select sprite can have access to shade and animation frame.

Offline Meridian

  • Global Moderator
  • Commander
  • ***
  • Posts: 4957
  • Aaand we're back!
    • View Profile
    • My Wiki
Re: OpenXcom Extended (OXCE) main thread
« Reply #42 on: December 12, 2018, 06:04:39 pm »
I don't know what the arguments, but... I have nothing to replace the images that are not working in the new version. That's the whole point. Apparently I will have to continue using version 5.0. Until find a replacement.

@Ethereal
I have converted all 24bit images from your mod (the latest available on the forum) to 8bit images.
You can find them in the attachment.

Offline Ethereal

  • Colonel
  • ****
  • Posts: 299
    • View Profile
Re: OpenXcom Extended (OXCE) main thread
« Reply #43 on: December 12, 2018, 10:17:04 pm »
@Ethereal
I have converted all 24bit images from your mod (the latest available on the forum) to 8bit images.
You can find them in the attachment.

Thank you very much!
Unfortunately, I lost the battle with Photoshop as it was my first experience with it. I can not get him to save files in "png" format.

Offline The Reaver of Darkness

  • Commander
  • *****
  • Posts: 1225
    • View Profile
Re: OpenXcom Extended (OXCE) main thread
« Reply #44 on: December 19, 2018, 10:14:41 pm »
I can help with that if you want... I assumed all modders know how to work with xcom palettes.
I guarantee you less than half of modders, by number, know how to work with X-Com palettes. Remember, this is OpenXcom, an incredibly easy format for non-programmers to get into.