Particle

mharezlak96

06-03-2011 14:44:30

I have .particle file with script. I'd like use this, but i don't kown how i can do that. How i can insert to my game particle fire. I have file in media folder.

Jo0oker

06-03-2011 19:07:22

Try this:


cSystem = SceneManager.CreateParticleSystem("Rain", "Examples/Rain")
SceneManager.RootSceneNode.CreateChildSceneNode(new Vector3(0, 1000, 0)).AttachObject(cSystem);


Greats,
Jo0oker

mharezlak96

07-03-2011 14:21:43

I copy the smoke.particle from ogre media folder from sdk. I don't change game code. But it doesn't work. It's log: 15:16:39: Parsing script smoke.particle
15:16:39: OGRE EXCEPTION(2:InvalidParametersException): Cannot find requested emitter type. in ParticleSystemManager::_createEmitter at ..\..\ogre\OgreMain\src\OgreParticleSystemManager.cpp (line 353)


smoke.particle code:
// Example particle systems

// smoke
particle_system Examples/Smoke
{
material Examples/Smoke
particle_width 35
particle_height 35
cull_each true
quota 500
billboard_type point
sorted true

// Area emitter
emitter Point
{
position 0 15 -15
angle 35
emission_rate 15
time_to_live 4
direction 0 1 0
velocity_min 50
velocity_max 80
}

affector ColourImage
{
image smokecolors.png
}

affector Rotator
{
rotation_range_start 0
rotation_range_end 360
rotation_speed_range_start -60
rotation_speed_range_end 200
}

affector Scaler
{
rate 50
}

}

smiley80

07-03-2011 14:50:54

Looks like you don't load the ParticleFX plugin.
Make sure 'Plugin_ParticleFX.dll' is in the correct folder and there's a 'Plugin=Plugin_ParticleFX' entry in plugins.cfg.

mharezlak96

07-03-2011 16:18:16

Where Can i download this plugin?

tafkag

07-03-2011 16:21:36

Where Can i download this plugin?

It's part of (M)ogre, so if you built it or downloaded the sdk you'll find it in the respective bin folder.

ianhfar

07-03-2011 16:43:21

Can you confirm that your

plugins.cfg

looks similar to the example below and that the file "Plugin_ParticleFX.dll" is in the expected (same as the other plugin) folder.

As indicated by smiley80


# Defines plugins to load

# Define plugin folder
PluginFolder=.

# Define plugins
Plugin=RenderSystem_Direct3D9
Plugin=RenderSystem_GL
Plugin=Plugin_ParticleFX
Plugin=Plugin_BSPSceneManager
Plugin=Plugin_OctreeSceneManager
Plugin=Plugin_CgProgramManager

mharezlak96

07-03-2011 17:26:13

Thank you. Now work.