Slimes of many colors

Ask for help about creating mods and scripts for Grimrock 2 or share your tips, scripts, tools and assets with other modders here. Warning: forum contains spoilers!
Post Reply
User avatar
Prozail
Posts: 158
Joined: Mon Oct 27, 2014 3:36 pm

Slimes of many colors

Post by Prozail »

So. Toying around abit with colors and shaders, here is a way to make a red slime, and a nice satin blue slime (using the material from the healing crystal)

Image

shadeTex, shadeTexAngle, and crystalIntensity are not in the scripting reference so i have no real idea on what values are appropriate, but theese definitions seem to work reasonable. You can also try the commented-out goromorg-shield-texture in the blue-slime material definition for a different effect.

Code: Select all


defineMaterial{
   name = "blue_slime",
   diffuseMap = "assets/textures/monsters/green_slime_dif.tga",
   specularMap = "assets/textures/common/white.tga",
   normalMap = "assets/textures/monsters/green_slime_normal.tga",
   shadeTex = "assets/textures/env/healing_crystal_shadetex.tga",
   --shadeTex = "assets/textures/monsters/goromorg_shield_shadetex.tga",
   shadeTexAngle = 1.3,
   crystalIntensity = 3,
   shader = "crystal",
   doubleSided = false,
   lighting = true,
   alphaTest = true,
   blendMode = "Opaque",
   textureAddressMode = "Wrap",
   glossiness = 100,
   depthBias = 0,
}


defineMaterial{
   name = "red_slime",
   diffuseMap = "assets/textures/monsters/green_slime_dif.tga",
   specularMap = "assets/textures/common/white.tga",
   normalMap = "assets/textures/monsters/green_slime_normal.tga",
   shadeTex = "assets/textures/env/red_gem_shadetex.tga",
   shadeTexAngle = 0.8,
   crystalIntensity = 3,
   shader = "crystal",
   doubleSided = false,
   lighting = true,
   alphaTest = true,
   blendMode = "Opaque",
   textureAddressMode = "Wrap",
   glossiness = 100,
   depthBias = 0,
}

defineObject{
   name = "red_slime",
   baseObject = "green_slime",
   components = {
      {
         class = "Model",
         model = "assets/models/monsters/green_slime.fbx",
		 material = "red_slime",
         storeSourceData = true,
      },
	  {
		class = "Light",
		parentNode = "light",
		range = 5, 
		brightness = 5,
		color = vec(5.0,0.2,0.2,0)
	  }
	}
}

defineObject{
   name = "blue_slime",
   baseObject = "green_slime",
   components = {
      {
         class = "Model",
         model = "assets/models/monsters/green_slime.fbx",
		 material = "blue_slime",
         storeSourceData = true,
      },
	  {
		class = "Light",
		parentNode = "light",
		range = 5, 
		brightness = 5,
		color = vec(0.5,0.5,5.0,0)
	  }
	}
}

Last edited by Prozail on Thu Nov 20, 2014 11:22 am, edited 1 time in total.
minmay
Posts: 2780
Joined: Mon Sep 23, 2013 2:24 am

Re: Slimes of many colors

Post by minmay »

crystalIntensity is a multiplier for the light values. shadeTexAngle is the amount to rotate normals around viewspace Z.
Grimrock 1 dungeon
Grimrock 2 resources
I no longer answer scripting questions in private messages. Please ask in a forum topic or this Discord server.
User avatar
Jirodyne
Posts: 211
Joined: Sat Jul 21, 2012 6:07 am

Re: Slimes of many colors

Post by Jirodyne »

I would love to see more slimes in Modded Dungeons, with different elements. Red for Fire, Green is Earth already, Blue would be Water, and Yellow as Air. Would add lots of variety.
GoldenShadowGS
Posts: 168
Joined: Thu Oct 30, 2014 1:56 am

Re: Slimes of many colors

Post by GoldenShadowGS »

These are definitely going into my dungeon. Thanks! Great idea
Post Reply