Author Topic: Ufopaedia screens for Armor and Vehicles  (Read 13670 times)

Offline skymarshall

  • Sergeant
  • **
  • Posts: 22
    • View Profile
Ufopaedia screens for Armor and Vehicles
« on: August 19, 2014, 01:06:26 am »
I'm new to openxcom and decided to take a look at the source code for my own amusement - it is a very nicely coded project and lots of fun to play with :)

One of the minor things that irritated me on the original was the inconsistent look of the ufopaedia screens, especially that the screens for new armor and vehicles looked really uninspiring despite these techs being a major deal in the game.  OpenXcom has made some improvements by putting in extra information, but the inconsistent look is still there.  I thought I'd try improving this as a way to find my way around the code.

Here's how armor and vehicle screens look in openxcom (excuse white borders from sloppy image grabbing):




By comparison, this is how the equipment screens look:



By fighting with palattes to create a new background image to match the weapons/ammo pages, and adding a few (hacky) lines of code to assemble unit sprites on the vehicles ufopaedia page, I have a much nicer look for the armor and vehicle pages on my local build:




Does anyone else care about this or just me?  If anyone has any opinion on whether this is worth doing properly and submitting for consideration, let me know.

Offline SIMON BAILIE

  • Commander
  • *****
  • Posts: 676
    • View Profile
Re: Ufopaedia screens for Armor and Vehicles
« Reply #1 on: August 19, 2014, 01:24:51 am »
I agree, what you are proposing would be a big improvement, good luck!

Offline ivandogovich

  • Commander
  • *****
  • Posts: 2381
  • X-Com Afficionado
    • View Profile
    • Ivan Dogovich Youtube
Re: Ufopaedia screens for Armor and Vehicles
« Reply #2 on: August 19, 2014, 02:28:22 am »
I've been trying to do some Ufopedia modding with little success.  Do you have to use a custom .exe for your mod to work?  If so that would conflict with Soldier Diaries, which I want to keep using. 

I'm very interested in what you are doing here, and will be following this closely.

Cheers, Ivan :D

Offline Arthanor

  • Commander
  • *****
  • Posts: 2488
  • XCom Armoury Quartermaster
    • View Profile
Re: Ufopaedia screens for Armor and Vehicles
« Reply #3 on: August 19, 2014, 05:53:22 am »
A big improvement as far as I am concerned! I wish you the best getting it in the main code!

Offline Solarius Scorch

  • Global Moderator
  • Commander
  • *****
  • Posts: 11721
  • WE MUST DISSENT
    • View Profile
    • Nocturmal Productions modding studio website
Re: Ufopaedia screens for Armor and Vehicles
« Reply #4 on: August 19, 2014, 08:13:12 am »
I love the idea of having pics for tanks, I've always wanted them.

But I don't like the armour change much, they look way better on black. Yes, I know it makes the Ufopaedia inconsistent, but still.

Offline skymarshall

  • Sergeant
  • **
  • Posts: 22
    • View Profile
Re: Ufopaedia screens for Armor and Vehicles
« Reply #5 on: August 19, 2014, 10:28:21 am »
Wow - I was 50/50 that this thread would go completely ignored!

@ivandogovich - yeah, a tiny code change is needed to put a background pic on the armor page, although you could do it in a very hacky way without a code change for a mod.

My change was to add a line of code to the ArticleStateArmor constructor:

      _game->getResourcePack()->getSurface("BACK_ARMOR.BMP")->blit(_bg);

I then created a BACK_ARMOR.BMP from the in-game BACK08.SCR, which is the equipment page background.

If you wanted to do it without a code change for a mod, I think you could do it by creating a duplicate armor in the "armors" section of the rules, give it a modified inventory sprite with a full page background, and then reference the duplicate armor from the ufopaedia entry instead of the actual one. 


@Solarius - yep, whether or not it looks better is totally subjective.  What would you think to adding an optional background image in the armor ufopaedia rules, allowing modders to have (potentially different) background sprites at their discretion?


Offline Dioxine

  • Commander
  • *****
  • Posts: 5455
  • punk not dead
    • View Profile
    • Nocturnal Productions
Re: Ufopaedia screens for Armor and Vehicles
« Reply #6 on: August 19, 2014, 10:51:26 am »
Well to be honest I don't find these new entries "nicer" in any way... I like the original setup where every kind of entry has a different layout (and I think Microprose designers shared that view). If you simply want to have tank's picture and extended armor stats for it, it's as easy as creating ufopaedia entry for TANK_ARMOR...

Offline skymarshall

  • Sergeant
  • **
  • Posts: 22
    • View Profile
Re: Ufopaedia screens for Armor and Vehicles
« Reply #7 on: August 19, 2014, 10:59:14 am »
I wonder if this layout would work for Solarius:




Agree with Dioxine that the nicest look for the tanks would be to have an artist do some nice 320x200 images for the vehicles similar to the craft screens.  You can almost do that without a code change, but would probably want to be able to move the stat and text sections around, which you can't do just from the ruleset. 

Mostly, I wanted to experiment and see how easy it was to print up unit battlescape sprites on the UFOpaedia screens - I think that could be quite useful for modders who want to show pictures on their UFOpaedia pages but can't find relevant art.
« Last Edit: August 19, 2014, 11:03:45 am by skymarshall »

Offline Gifty

  • Colonel
  • ****
  • Posts: 138
    • View Profile
Re: Ufopaedia screens for Armor and Vehicles
« Reply #8 on: August 19, 2014, 11:23:25 am »
I like this, I never liked how the armor entries just kind of existed in this black void.

Offline Solarius Scorch

  • Global Moderator
  • Commander
  • *****
  • Posts: 11721
  • WE MUST DISSENT
    • View Profile
    • Nocturmal Productions modding studio website
Re: Ufopaedia screens for Armor and Vehicles
« Reply #9 on: August 19, 2014, 12:45:05 pm »
I wonder if this layout would work for Solarius:



Yeah, it's a reasonable compromise... But it doesn't look as good as the original, I'm afraid. Which I consider a bigger problem than the inconsistency.

Offline skymarshall

  • Sergeant
  • **
  • Posts: 22
    • View Profile
Re: Ufopaedia screens for Armor and Vehicles
« Reply #10 on: August 19, 2014, 01:40:02 pm »
OK - I think opinion on this is sufficiently divided that my new screens wouldn't suit everyone and so they definitely shouldn't be inflicted on the main build.  It stays on my build though, that's the beauty of open source :)

What would be very useful for modding (and not detract from replicating the original game) is the ability to have

- configurable background image and choice between ufopaedia/battlepedia palette
- battle scape unit images
- moveable text and stat boxes (as for craft)

as options in the ruleset for the vehicle and armor ufopaedia screens.   The first especially, would be a very minor code change, and give an incentive for a talented artist modder to produce some professional looking screens for the tanks.



Offline clownagent

  • Colonel
  • ****
  • Posts: 380
    • View Profile
Re: Ufopaedia screens for Armor and Vehicles
« Reply #11 on: August 22, 2014, 09:16:09 pm »
More consistent Ufopedia entries would be really an improvement, especially for the HWP pages.

Offline skymarshall

  • Sergeant
  • **
  • Posts: 22
    • View Profile
Re: Ufopaedia screens for Armor and Vehicles
« Reply #12 on: August 22, 2014, 10:39:35 pm »
Sadly, all this is a matter of taste rather than my ideas being a strict improvement - so replicating the original game has to win out for the moment

I like my changes, but unless I hear loud noises from the community to submit them properly, I think they just stay on my local build

Offline Aldorn

  • Commander
  • *****
  • Posts: 750
    • View Profile
Re: Ufopaedia screens for Armor and Vehicles
« Reply #13 on: August 23, 2014, 11:51:01 am »
I agree for both HWP and Armor Ufopaedia  :)

Offline Vulgar Monkey

  • Sergeant
  • **
  • Posts: 45
    • View Profile
Re: Ufopaedia screens for Armor and Vehicles
« Reply #14 on: August 23, 2014, 05:13:40 pm »
I've actually already got some 3d models of tanks and a redesigned skyranger if anyone wants them.
I'd say they'd be a suitable basis for a paintover, but at low-resolution and 256 colour you might as well just do a straight conversion - I can't see it being possible to do much other than maybe use a few filters to make sure the image indexing comes out nicely.











I never actually bothered to mention it because.....well, we didnt have images in the research screens!

I was going for something a bit like the Wiesel mini-tank, but the funny thing is that if you look at some of the little TALON (?) drones being tested out by the US army atm, they can mount just as much firepower on a chassis half the size! If we dont want the HWP tanks to be underpowered, I guess we can say narratively that the extra mass comes from armour, fuel and extended rough-terrain ability or something. Plus they're much faster, so it's mostly engine I guess.

Actually, one thing I did think with these is that the storage bins could carry gear and the rack along the rear could seat troops or carry the wounded. Is it possible to give vehicles their own inventory space?
« Last Edit: August 23, 2014, 05:36:30 pm by Vulgar Monkey »