Jump to content

Using Community Edition's new HazardousLiquid

Recommended Posts


Community Edition is available and with it comes the capability to essentially customise lava.


It's worth noting that there always was a way to recolour lava. For instance, I can turn "lava" into "water" and hence have "eroding water" . This is done by just creating a new biome, and you replace the Lava texture with Water and need to knock up some erosion textures.

Making erosion textures should be straightforward if you have your liquid texture. GIMP is a stupendously powerful if very confusing image editor, and what I did was just layer the "ground" tile on top of the "liquid" tile, then use the Eraser tool with some settings to make holes in the ground to reveal the liquid. Do that enough times, make sure you're on Indexed BMP, export it and hit the checkbox "Do not save colour space information," and you have erosion textures!


However, even doing this, you would get annoying orange plumes of lava smoke.



Now, those smoke plumes are no longer an issue!



Setting it up is pretty straightforward. Open Lego.cfg, go all the way down to the bottom, and add the stuff which Cyrem told you to :


LegoRRCE {

	HazardousLiquidTypes {

	; All our new liquids are going to be defined in here


(Note: changing from Lego* { to LegoRRCE was done in a later build of CE, so watch out for that).


The properties are very staightforward and obvious and not what I was covering here. What I was covering was what can be done with it.

(One thing that's worth noting is that the colour parameters are Red : Green : Blue  and go from 0 to 255 each.)




I have defined a new HazardousLiquidType, Tentacle. I was perhaps hoping that this could have 'alien tentacles' rise out of the water, wave around a bit, and then sink down. To experiment with this idea, it only has one .bmp:




To make this BMP I opened the original SMOKE0.bmp and just set the whole thing to black, then painted over it. This allowed me to get the resolution which I knew LRR wouldn't explode with.


Corresponding code under HazardousLiquidTypes is:

Tentacle {
				ToolTip				Tentacle
				SmokeStream			TRUE
				SmokeStreamRGB		000:255:0
				ErodeSmoke			FALSE
				SmokeStreamBMPCount		1
				SmokeStreamBMPPath		MiscAnims\Smoke\Tentacle

& then in Driller Night (Level01) specified:

HazardousLiquid					Tentacle

NOTE: Cyrem's documentation is that this calls for HazardousLiquidType. This is wrong. :P With his assistance & the logger I determined that it actually checks for HazardousLiquid.

@Cyrem: what are you planning to do with this? Change the documentation to HazardousLiquid, or change CE to check for HazardousLiquidType? I can update this post accordingly.


Unfortunately, the results aren't what I was hoping for:




A whole bunch of tentacles just float up into the air...



Of course, the rotation of the image is easy to fix: just rotate it 90 deg anticlockwise. However this shows what's going on: the textures slowly rise up, growing in size a little and in transparency, until they fade away. Here's a short video showing them rise:



This means that the original idea I had for a waving tentacle just isn't going to work.


Something I didn't show in that video is that the image always rotates to face the camera.




Well, what does work then?


As you may see in that image there are a lot of green tentacles rising out of the water. Well, we can adjust the amount of this by specifying more files that contain empty images. Here's the contents of my Crystal liquid:




& corresponding code:


Crystal {
				ToolTip				Strange_Crystals
				SmokeStream			TRUE
				SmokeStreamRGB		0:255:0
				ErodeSmoke			FALSE
				SmokeStreamBMPCount		6
				SmokeStreamBMPPath		MiscAnims\Smoke\Crystal

As there are now five blank images and only one image that actually has something on it, we get one sixth the amount of images we previously had. You could get complicated fractions like 5/12 if you wanted: of twelve images, five must be crystals, so seven must be blanks.




Are these random? Well, if I set up this:


Numbers {
				ToolTip				OneTwoThreeFour
				SmokeStream			TRUE
				SmokeStreamRGB		255:255:255
				ErodeSmoke			FALSE
				SmokeStreamBMPCount		4
				SmokeStreamBMPPath		MiscAnims\Smoke\Numbers


it looks like this ingame:




which looks pretty random to me!






Now Aiden, have you actually got this to be useful yet?


Well, no, not really. The greatest use is simply speficying SmokeStream FALSE and ErodeSmoke FALSE, so no smoke at all: which makes water erosion look a lot better. 


I have, however, made exceedingly useless things with it:



And I've discovered that certain profile pictures actually work pretty well when converted to greyscale.






Things that (currently) cannot be done:

- Changing erosion smoke colour. This is defined in the .lwo and is probably always going to be orange. I reccomend just setting ErosionSmoke FALSE if your liquid isn't anything orangeish.

- Different colours of different images. They're greyscale with a colouring applied to all images. I can have green bricks float up, and a separate liquid have red bricks float up, but I can't have :grbrick:s float up in changing colours.



Let me know if you get any good ideas...


Share this post

Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

    No registered users viewing this page.

  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.