Skip to content

Dust, so much dust...

Imari edited this page Nov 4, 2012 · 2 revisions

This some temporary information on the particle effect "dust" - We can change the values for the amount (%) of the particles' Intensity, Speed, Size, Spread and the particles Color. Visual effects must be turned on in the configuration file and settings for the particles at start up go in the main lua file.

effects.dust = 90
effects.dustColor = 0xFFADFF2F
effects.dustSize = 90
effects.dustSpeed = 90
effects.dustSpread = 10
effects.dustIntensity = 10[/code]

This is what the Cafeteria looks like with the above settings -
Particle Test -

The values for everything but Color are 1-99. I could barely make out one or two particles below value 3 and at 100 they vanished all together. (I'm not sure what the Intensity setting does exactly as I saw little difference when changing it. Perhaps it's the combination that I didn''t have right.)

The A,R,G,B color values can be found in a handy chart found here ---> http://msdn.microsoft.com/en-us/library/system.windows.media.colors.aspx#Y0 Select the C++ tag under the "Syntax" heading and scroll to the bottom of the page for a neat color chart. I tried several and they worked.

You can change the dust effect when entering or leaving a room. To turn on fuschia particles when going into a new room -

addDoor(node, destination_node, NORTH, "type_of_door_sound",
	function()
		effects.dust = 90
     effects.dustColor = 0xFFFF00FF
	end)	

To turn off particles when exiting the room -

addDoor(node, destination_node, SOUTH, "type_of_door_sound",
	function()
		effects.dust = 0
	end)

For those proficient in C++, the particle characteristics of Color, Intensity, Speed, Size, and Spread are set up in the following C++ library and code files -

  • DGEffectsLib.h
  • DGEffectsManager.cpp

The current particle is rather round and fuzzy. It is contained in binary format in the file called DGDustData.c. If that can be changed, then it might be easier to create different effects. I have not been able to figure out if there's a way to mask the particles (so that they'd play on a waterfall, for instance) or to change the direction of the flow, or to pinpoint the source.

Imari 8-16-2012