Jump to content

CnCNet Forums

Search In
  • More options...
Find results that contain...
Find results in...
Nyerguds

Terrain tricks: northern island corners

Recommended Posts

As some of you may have noticed, compared to Red Alert 1, C&C1 is lacking a fair bit in terms of tilesets. And to remedy that, map makers have had no choice but to resort to trickery.

However, the point of trickery is of course to actually trick the player. If you have a horrible-looking terrain transition, then sure, pasting a dozen trees over it will probably mostly cover it up... but it's not a pretty solution, and it's hardly subtle. Instead, let's look at some more elegant solutions that only involve map tiles.

Two of the things that requires such trickery are the north-east and north-west shore corners. Plain and simple, C&C1 doesn't have them. And yet, when Chad1233 asked me about them, I distinctly remembered making maps that contained them. Some research later, I realized I made fairly pretty-looking corners by cheating the system; I built them by cleverly combining tiles from different tilesets.

1467040301_islandcorners.gif.c02c69804cc231fd6a9287a099ab2df8.gif

One of these tricks, the one seen at the left side, is fairly easy. I generally call it "the stump", because it always sticks out a bit.

These 'stumps' can be made in two directions, and are done simply by taking the river mouths of both the top- and bottom-facing variety, pasting them together, cutting them in half, and then putting the normal curving-down tileset at the bottom of the half you end up using:

842347944_buttedcorners.png.bcdbcff6ceb06cf56fc3a57a26a7cb56.png

So yeah, fairly simple. But, for the north-east version up there, as you notice, it does not actually stick out. Yes, there's clearly still river-trickery involved, as you can see from the grass leading up to the water, but the shore itself actually has more or less the shape you'd expect from a shore corner.

This process is a bit more tricky, but it can in fact be done without resorting to hex-editing tiles into the map's .bin file (see below for more on that). Here's how I did it:

1740476396_toprightcorner.png.46e7216cde0d931a97574ba899835192.png

Of course, these two final shore pieces in the two last steps can be whatever you want. The actual bit you need is just this:

2047335126_toprightdecomposed.png.cf62791336e78c443abc366e07e1f793.png

And it can just as well be used with other adjacent pieces:

814861809_toprightcorneralternate.png.076d49356bd9513f681c20cb1656b5ac.png

The possibility, as dear Dr. Moebius said... are limitless!

 

I fiddled around a bit, but so far, I haven't been able to construct a non-stump version of the north-west one, though. if I ever figure one out, I'll post it here too.

If anyone else knows similar mapping tricks, please post them! I'd love to see more of these.

  • Upvote 5

Share this post


Link to post
Share on other sites

This where mapmaking becomes an art form. Great tutorial, I hope it will be an inspiration to many people on the forum!

Share this post


Link to post
Share on other sites

Thanks :)

Here's a slightly decreased stump design, which does require a little hex editing. The piece indicated in red on the third frame is moved to the area indicated in blue.

1678792426_topleftcorneredited.png.9ddf151531c100f84f8e919ff4a76bd2.png

Small intro to hex editing maps... a C&C map consists of 64 rows of 64 cells, with 2 bytes per cell, making it always exactly 8192 bytes long. For each of these cells, the first byte is the tileset ID (as can be looked up in my tilesets ini file), and the second indicates which tile number of that tileset to use.

Tileset ID FF is reserved for clear terrain (official maps have all clear terrain saved as "FF 00" cells), but, annoyingly, XCC insists on saving clear terrain as the actual repeating 4x4 tiles pattern of all 16 cells of tileset ID 00, meaning values 00 00, 00 01, 00 02, etc, up to 00 0F.


To hex edit a map, I basically use a 1x1 'marker' block that is easy to recognize. My default marker in the old days was 05 00 (rock in water) but given the aforementioned fact that xcc doesn't use the default terrain marker, there will be a lot of "00 05 00 06" in there already, making the value 05 00 hard to use.

Instead, nowadays, I've been using the P04 "UFO" tile. It's generally rarely used in a map (and if it is, you can leave that for after your editing), and it has an ID higher than 0F so we don't have to deal with XCC's blank terrain mess. Its ID in the map file should be "46 00" (tile ID 70, tile 00). P03 (45 00) is another good one, but the more different markers you use, the more map decoration you have to delay until after all this editing.

Anyway. To copy the piece above, first mark each area using a marker. The terrain to replace can be marked simply by replacing it by the marker. The piece to copy should get a marker to the left or right of it, since maps are saved in horizontal lines, so you'll know the bytes right next to your marker are the bytes to copy.

898094062_topleftcorneredit1.png.8673e4a39a138470b5b34b0d0cc6cfdb.png

Note that you don't strictly need the copy markers; if you know which tileset the tiles are from (XCC editor shows this), and you know which tiles they are, you can figure out that the tileset is SH9, which has ID 91 (in the tilesets.ini file), or 5B in hex, and that the tiles to use are the center right and lower right ones in the 3x3 grid:

0 1 2
3 4[5]
6 7[8]

This means the values we'll find are "5B 05" and "5B 08".

So anyway, P03 is our replace marker, and P04 indicates the cells just right of the tiles to copy. With that done, save the map, open the .bin file in your favourite hex editor, and let's look for 46 00, the ID of our copy marker.

361327908_topleftcorneredit2.png.a2a721d083dd05634bfce124249f0c32.png

As predicted, the values before the copy markers are "5B 05"  and "5B 08". Now we remember those, and we go find our replace markers, 45 00.

662700121_topleftcorneredit3.png.57b983181271983fdbf8683329ba29ba.png

Well, that wasn't too hard; they're right there. So now we replace those two by the two values we found.

1780871238_topleftcorneredit4.png.afbdbcccf84045fe25882d587a921226.png

Done! Save and exit, and let's see the result if we reload the map in XCC Editor:

226648795_topleftcorneredit5.png.de3a4fab93d37f6a8586a6657f8bc2c4.png

The edit is applied! Now you can clean up the copied piece and the copy markers, and your edit is done.

Share this post


Link to post
Share on other sites

Not quite as perfect, but still pretty neat: substituting beach by a piece of road.

466776478_topleftcornereditroad.png.75bea8e1fb65c131d8ae5e7792ee57f1.png

 

  • Like 1

Share this post


Link to post
Share on other sites

Beach-less islands and lakes are also possible in temperate and winter by carefully combining river and river-to-shore tiles. See my Fjord map for reference.

I had an example, but on another computer: I might later post a pic of a land bridge in desert. I.e. faking a river going through a tunnel under a cliff. Rudimentary stuff, but with some hexing it can work better.

  • Upvote 1

Share this post


Link to post
Share on other sites
4 minutes ago, cn2mc said:

Beach-less islands and lakes are also possible in temperate and winter by carefully combining river and river-to-shore tiles. See my Fjord map for reference.

I had an example, but on another computer: I might later post a pic of a land bridge in desert. I.e. faking a river going through a tunnel under a cliff. Rudimentary stuff, but with some hexing it can work better.

I can't believe I never really looked at this... is that entire lake made from disjointed river tiles?
And the island too, for that matter?

Edited by AchromicWhite
  • Confused 1

Share this post


Link to post
Share on other sites

Small lake is only rivers, I think. Island probably too. The fjord itself is a combination of shore and river. It switches to beach in the West. The idea came to me before, when I was one time making a similar fjord-like mission, and I wanted to have cliffs as near to the water as possible.

  • Like 1

Share this post


Link to post
Share on other sites

Here it is: a land bridge in the desert theatre. Only the two top waterfall cells needed actual hex editing, the East part I did by simply overlapping tiles in XCC. Maybe there is a suitable cell in the river tileset that will mask the lack of shadow and blend in with the cliff better than the dumb tree solution.

 

landbridge.png

  • Upvote 3

Share this post


Link to post
Share on other sites

It should... the RA map data is converted to base64 (and compressed I think) but the data is saved the same way, only with 3 bytes per cell IIRC, allowing IDs that span 2 bytes. In fact I think RAED even has features for copying and pasting single template cells.

But the point is rather moot; RA actually has all those tiles we're faking into existence here :P

Share this post


Link to post
Share on other sites

Yeah, but the copy-paste function for tiles sounds tasty. Couldn't that, or a 'deconstructed' template section where you can choose 1 tile out of a set be added to one of the existing editors for TD? 

Share this post


Link to post
Share on other sites

I doubt it, but I could probably write my own if I feel up to it... already got code to read (and write) the tileset format, and the maps are peanuts; all that remains is the mix format, and I doubt that's hard.

Share this post


Link to post
Share on other sites

A different tool for just editing .bins sounds much more streamlined, yes. Is the .mix thing really needed for anything besides hacking in new tiles? Because the way I see it, if you have a tool that can open and edit template files with simple draw and copy/paste functions, you can just have the corresponding bytes for every tile and store them as a standalone palette or something, or am I wrong? 

Anyway, this is kind of going off topic. I'll maybe show 'long bridges' later. I'd like to hear ideas for more things to do with maps, because I like this thread.

Share this post


Link to post
Share on other sites

Yeah, that land bridge is pretty neat. Haven't done any hex editing myself, so I'd have to learn a bit to get started; but it's helpful, for sure. A simple copy/paste tool would be good. It means that people don't have to learn simple hex to be able to make what they want in maps.

Most of the "tricks" I've done in mapping have just been to make roads work when the lengths available are not quite right... pretty simple stuff, lol.

  • Confused 1

Share this post


Link to post
Share on other sites
On 5/12/2018 at 12:25 AM, cn2mc said:

Is the .mix thing really needed for anything besides hacking in new tiles?

There's this little detail called "reading the original theater data to actually show the map"... otherwise you may as well use CC-SCEN :P

It would be kind of a bother if the first line in the manual of such a tool was "extract all files from temperat.mix, desert.mix, winter.mix and snow.mix into a new folder, because this tool can read TMP files but can't read them from mix files" :rolleyes:

Share this post


Link to post
Share on other sites

My tool for doing map previews for RA1/C&C1 just uses loose files so MIX reading isn't needed.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

  • Similar Content

    • By AndrewFord
      on the CncNet5 (RA, TS, TD version) there is usually a flashing green button that says "streaming" whenever someone is live on twitch but it doesn't show anymore. When shall this be fixed.
    • By Doblofino667
      Hi guys, I have for the first time today joined Cncnet, as I really miss Tiberian Dawn and I had a huge itch to play it. The download went nice and quick and I was able to get it onto the pc. 
      When I run it though, I run into problems. It skips the opening animation and immediately goes to the starting menu. When I press "Start new game" the program hangs and then I need to use task manager to close it. I dinked around with the resolution and compatibility settings too but no joy. In the end I saw a user here report something similar and the admin said something to the effect of changing the rendering to GDI instead of Auto. I did that and still not working. (Obviously when you press start, you go to that snowflake screen where you select GDI or NOD - THAT is the screen that doesn't want to load)
      At this point, I have tried all sorts of screen resolutions, rendering options, windowed/fullscreen options and turned comparability settings on and off. Computer still hangs. 
      Interesting to note, that when I click other options like "Load", "Internet Game" or "Exit", those options work fine. BUT when I click on "Intro & Sneak Peek" all I see is a screen saying "Coming Attraction" and then goes back to the menu. I remember this was an advert for Tiberian Sun. It seems that I can't run the cutscenes or animations or movie sequences. 
      Oh, another thing that might be of assistance. When I run the program without comparability, it hangs after selecting "new game" but when I run it in comparability mode for Windows 95, the game does not load, it simply says "can't play movies" or somesuch. 
      I hope the info helps! Please advise. 
      Thanks a lot guys.
      J
    • By Noyjitat
      I played around a bit in tibed and was thinking. Wouldn't it be cool to have a mod that has the rules of c&c renegade but in an rts c&c game?
      Example:
      Guard towers fire quicker, have longer range and are more armored and nearly 1 shot most vehicles.
      Guard towers have line of sight rules meaning infantry and tanks that are really close to buildings and tall objects can avoid being fired upon. (not sure if this even possible)
      You only get 1 guard tower with the exception of 2 - 4 pillboxes or Gun turrets
      You get 1 refinery with a small amount of credits slowly accumulating overtime and then credit dumps as normal when a harvester returns
      Each team is limited to 6 tanks
      Engineer repairs infantry, tanks and structures over time
      I'm  not sure how c4 and stuff would work. Maybe something in the form of an ivan bomb and you need 4 of them placed on a structure to go off in order to destroy it? Engineers should also be able to remove this.
      Vehicle and infantry fire power, rate of fire should be increased to match the values in renegade.
      Beacon placement for super weapons. A soldier drops the beacon and then it has a count down. Can be removed by engineer.
      Beacon placements on barricks ends the match unless removed by engineer/advanced engineer
      Advanced engineers: Hotwire / Nod technicians repair faster, deploy mines, shorter fuse ivan bomb?
      engineers/ advanced engineers equipped with pistols
      The game should basically all the renegade troops you could purchase such as havoc, sakura, etc with the same role sniping, rail gun etc.
      All aircraft replaced by helicopters/orcas, all infantry/vehicles able to hit them with snipers and rocket soldiers doing the most infantry damage to them. 
       
      Basically an exact copy of the renegade game as close as you can get it but in the form of the many rts c&c games we have now. Though i think you'd want to put an limit on the amount infantry just like most renegade servers could only hand so many players. I think 70 was the biggest I remember back in the day on the renstation server.
       
    • By Techstorm
      Hey, so I want to recommend the classic C&Cs to some people I know, and they may be more likely to try it if it's free. However, while the first free C&C games were released as freeware, the primary sources of downloads are down, the only way is through 3rd party mirrors and the C&C Ultimate Collection includes them for a price. So are the first three games still considered freeware?
    • By Nyerguds
      I'll just repost this here, since PPMsite is a mess these days.
      I have been making a tool to create .mrf files for C&C1 (RA seems to generate these tables in memory rather than keeping them as files). These files are basically palette remapping tables, used in the game to make colour effects like shadow, map shroud edges, stealth darkening (though not the actual effect), the targeting flash when giving attack / repair / dock commands, and a bunch more. Since they are relative to the theater's palette, they are a vital step to fully customizing terrain.
      Download:
      FilterCreator_v1.11.rar - The tool, plus all of the mrf creation projects. (requires .NET framework 3.5)
      All icons used in the program (except the actual program icon) are based on the Fugue Icons 16x16 pack by Yusuke Kamiyamane (Copyright © 2010)
      Test data:
      FilterCreator_testdata.rar - All .mrf files in C&C, plus example screenshots to test on.
      Source code:
      FilterCreator_src_v1.11.rar (Visual Studio 2010 project)
      Now, on to the tool itself:

      The actual main tool's purpose is to recreate the existing filters in the game using brightness / contrast / colour balance / etc filters. However, since I already reconstructed all filters in the 11 .mrf files C&C1 needs for a theater, you can just go to [File] -> [Write multiple .MRF files...] and simply generate all the tables you need for a new theater.
      All you need to do for that is selecting the folder with finished projects that comes with the tool, the palette of your new theater, and an output folder:

      This sub-tool can also be started directly by starting FilterCreator from a shortcut with the command line parameter "-mrfui"
      ---
      The current included projects are obviously just my own reconstructions. They were created to quickly allow people to make new theaters, but they're probably far from perfect.
      So, if you want to try your hand at it, or if you simply want to view existing .mrf files, here's the overview of the UI functions of the main tool:
      Right pane: the preview of the original .mrf file. It shows the filename of the loaded mrf file, and the amount of filters inside the file.
      Left pane: the project. The filename of the loaded project is shown in the title bar of the program.
      The controls get more specific as you go down on the left pane. Top is the project description... a completely optional field, really. Below that is the filters dropdown. Each filter is a "sub-project".
      The three palette buttons allow you to manipulate the final palette in three ways. In all three cases, a yellow asterisk will indicate if anything is customized in the three options.
      The first one, "Manual Remap", allows you to force certain colours to certain other colours before applying the filters. This can be used to make index tables as some mrf files have, or just to change certain colours before adding filters to them. Practically all existing filters seemed to have changed the animated water colours to white before applying their effect, so you probably need to use it for the same thing.
      Notes:
      The specific indices set in this way are only preserved as that specific index if no effects are applied to it later. To set colours here that are not affected by the effects on the filter, you need to also set them in the third function, "Never remapped". The second, "sub-palette", allows you to exclude colours from the used palette. This is usually used to exclude index #0 black from the used colours. Note that this can also be used in reverse, to select specifically the only colours to use for generating the palette. This is used for the unit shadow and some other filters like it, which use specific colours on the palette.
      The third palette option is the "never remapped" list. This will allow you to select colours on the palette that will always remap to their own index (unless set to another index by option #1). These indices cannot be affected by the effects in the filter.
      And, the last palette option, located at the top, next to the "enable filter" one, is the "Match back to palette" checkbox. If this is not enabled, you will see the filters as applied to the image, without taking into account the palette to remap back to. This also means it ignores the selected sub-palette, though force-remap and never-remapped entries are taken into account.
       
      Under "Options", you can find an option to synchronize the filter between the left and right pane if possible, so that when you load the .mrf that corresponds to the project, it'll always show you the right filter from the file.
      Then we have the effects. Available effects are Brightness, Contrast, Gamma correct, Colorize, Saturation change, Luminance change, and a combined Hue/Sat/Lum adjustment control. All effects you add to the list stack up to create the final filter. Since their order often makes a lot of difference, you can move effects up and down in the list.
      Below the effects you see the actual effect sliders. The preview on the image is instant, though it might lag a little if you drag it around while "match back to palette" is enabled, because every small change will need to recalculate the remap table and apply it to the image.
      That's it, I guess. The options in the menus should be pretty straightforward.
  • Recently Browsing   0 members

    No registered users viewing this page.

×
×
  • Create New...