Announcement

Collapse
No announcement yet.

Vaguely technical question about graphics

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Vaguely technical question about graphics

    This is a question about the graphics formats used by CTP 2.

    The unit animations are listed as .spr. Would I be correct in assuming that this not an industry standard file type? I've been google-ing about sprites because I want to add my own unit graphics (of course) and I haven't found any reference to the .spr file type, only .bmp .gif .tiff etc. From what I can gather 'sprite' is simply a generic name for a sequence of bitmaps and CTP uses .tiff for these. Is the format that CTP calls 'sprite' proprietry? I have browsed some of the conversion threads but they don't seem to tell me exactly what the .spr files 'are' exactly, other than the graphics files for the game. How exactly are they made out of .tiff for example?

    I hope someone understands what I am talking about.

  • #2
    I think the *.spr-format has to be considered "proprietary", actually it is a sort of "container" for the images the unit animation requires (various directions, various kinds of movement etc. ...) and the "animation rules".

    If you wish to add sprites to the game you basically need to create a set of TIFFs. There's a utility for merging this set of images into a *.spr-file: MakeSprite. This utility also contains sample "scripts" for adding standard rules to the different kinds of sprites (units, goods, or cities) -- so you usually don't need to worry about those rules. You will find a couple of guides for sprite creation here (I recommend to read the part about pure black and the "alpha channel" carefully).

    Creating sprites for units like ships, airplanes, or tanks without "full" animation is fairly easy. Creating full animations for "walking" (infantry etc.) units is much more difficult -- you will see what I mean if you take a look at the current unit sprite list
    The modding knowledgebase: CTP2 Bureau (with CTP2 AE Modding Wiki). Modern Times Mod (work in progress): MoT-Mod for CTP2.

    Comment


    • #3
      Originally posted by BureauBert View Post
      I think the *.spr-format has to be considered "proprietary", actually it is a sort of "container" for the images the unit animation requires (various directions, various kinds of movement etc. ...) and the "animation rules".

      If you wish to add sprites to the game you basically need to create a set of TIFFs. There's a utility for merging this set of images into a *.spr-file. This utility also contains sample "scripts" for adding standard rules to the different kinds of sprites (units, goods, or cities) -- so you usually don't need to worry about those rules. You will find a couple of guides for sprite creation. (I recommend to read the part about pure black and the "alpha channel" carefully).

      Creating sprites for units like ships, airplanes, or tanks without "full" animation is fairly easy. Creating full animations for "walking" (infantry etc.) units is much more difficult -- you will see what I mean if you take a look at the current unit sprite list.
      Thanks for the answer. I have a couple more questions if you don't mind:

      1. Would I be correct in assuming that animations are essentially a matter of having all the required .tiffs and entering the names of these .tiffs into the script, or is there something more to it than that? So let's just assume I have a number of correctly named .tiffs each of which is an appropriate frame of animation. I now the rest of making the animated sprite a matter of creating the script and running Makesprite?

      I am looking to automate a lot of this process. I have Gimp and there are scripts that can auto-cut up sprite sheets and create images from the layers or simply cut up gifs and do the same; converting them or creating them as tiffs is pretty much a matter of either finding or writing the script. There are plent of apps that can batch rename files so it seems a lot of innanity can be removed from the operation. If I can find someone who knows the ins and outs of CTP 2's arcane mysteries then asking pointed questions saves me hours of hacking around myself. I want to get this image-adding out of the way as a first step to getting deeper into the game. I have a limited background in programming (Java and C/C++) and after this am going to look at the source code as I have some ideas on revamping the trade system and making it somewhat akin to reality, rather than either a vague diversion (as it is now) or a mindless exercise in pre-scripted micromanagement (as a lot of suggestions seem to be). Ambitious yes but I look at this as a long term project to get my programming skillz back and up.

      Sometimes I wonder if it wouldn't be better to simply start fresh and write a whole new game

      Comment


      • #4
        animations are essentially a matter of having all the required .tiffs and entering the names of these .tiffs into the script
        Yes, that's it -- but you don't even need to enter the names into a script, you just need to provide the tiffs in a certain numbered order which is explained in the readme for MakeSpr.

        CTP 2's arcane mysteries
        Well, we do our best to unveil these mysteries. "Learning" CTP2 certainly requires some work and some patience, but it's still worth the effort because the game really offers extensive modding possibilites. It would sure be great if you'd get involved into the SourcecodeProject as well -- I am sure that Martin Gühmann could need some help in this regard.
        The modding knowledgebase: CTP2 Bureau (with CTP2 AE Modding Wiki). Modern Times Mod (work in progress): MoT-Mod for CTP2.

        Comment

        Working...
        X