Партиклы в одной ?цене по ?лоям.
Please login or register.

Login with username, password and session length
Advanced search  

News:

This forum provides RSS feed. To query recent posts use this url. More...


Author Topic: Партиклы в одной ?цене по ?лоям.  (Read 2464 times)

0 Members and 1 Guest are viewing this topic.

Borbel

  • Lurker
  • *
  • Karma: 0
  • Offline Offline
  • Posts: 42
    • View Profile
Партиклы в одной ?цене по ?лоям.
« on: November 16, 2010, 11:58:30 AM »

Logged

s.belov

  • Lurker
  • *
  • Karma: 0
  • Offline Offline
  • Posts: 38
    • View Profile
Re: Партиклы в одной ?цене по ?лоям.
« Reply #1 on: November 16, 2010, 12:09:16 PM »

Logged

Borbel

  • Lurker
  • *
  • Karma: 0
  • Offline Offline
  • Posts: 42
    • View Profile
Re: Партиклы в одной ?цене по ?лоям.
« Reply #2 on: November 16, 2010, 12:32:54 PM »

Code: [Select]
var Ent = Scene.GetNode("Emitter");
Ent.MakeSnow();

var Ent2 = Scene.GetNode("Emitter2");
Ent.MakeSnow2();
Code: [Select]
////////////////////////////////////////////////////////////////////////////////
method MakeSnow()
{
  
  this.CreateParticleEmitter();
  
  var Emit = this.ParticleEmitter;
    
  Emit.AddSprite("particles\snowflake.sprite");
  Emit.X = 0;
  Emit.Y = 550;
  Emit.Width = Scene.Width;
  
  Emit.SetBorder(0, 0, Scene.Width, Scene.Height);
  Emit.SetBorderThickness(0, 0, 0, 100);
  
  Emit.LifeTime1 = -1;
  Emit.LifeTime2 = -1;
  Emit.LifeTimeZBased = true;
  
  Emit.Velocity1 = 20;
  Emit.Velocity2 = 50;
  Emit.VelocityZBased = true;
  
  Emit.Scale1 = 5;
  Emit.Scale2 = 60;
  Emit.ScaleZBased = true;
  
  Emit.Angle1 = 360;
  Emit.Angle2 = 70;
  
  Emit.MaxParticles = 300;
  
  
  Emit.GenerationInterval = 1000;
  Emit.GenerationAmount = 30;
      
  Emit.FadeOutTime = 1000;
  
  Emit.Start(20000);
}

////////////////////////////////////////////////////////////////////////////////
method MakeSnow2()
{
  
  this.CreateParticleEmitter();
  
  var Emit = this.ParticleEmitter;
    
  Emit.AddSprite("particles\snowflake.sprite");
  Emit.X = 0;
  Emit.Y = 550;
  Emit.Width = Scene.Width;
  
  Emit.SetBorder(0, 0, Scene.Width, Scene.Height);
  Emit.SetBorderThickness(0, 0, 0, 100);
  
  Emit.LifeTime1 = -1;
  Emit.LifeTime2 = -1;
  Emit.LifeTimeZBased = true;
  
  Emit.Velocity1 = 20;
  Emit.Velocity2 = 50;
  Emit.VelocityZBased = true;
  
  Emit.Scale1 = 5;
  Emit.Scale2 = 60;
  Emit.ScaleZBased = true;
  
  Emit.Angle1 = 360;
  Emit.Angle2 = 70;
  
  Emit.MaxParticles = 300;
  
  
  Emit.GenerationInterval = 1000;
  Emit.GenerationAmount = 30;
      
  Emit.FadeOutTime = 1000;
  
  Emit.Start(20000);
}
Logged

s.belov

  • Lurker
  • *
  • Karma: 0
  • Offline Offline
  • Posts: 38
    • View Profile
Re: Партиклы в одной ?цене по ?лоям.
« Reply #3 on: November 16, 2010, 12:48:22 PM »

   var Ent = Scene.GetNode("Emitter");
   Ent.MakeSnow();
   
   var Ent2 = Scene.GetNode("Emitter2");
   Ent.MakeSnow2();   <------------- должно быть Ent2.MakeSnow2()
Logged

Borbel

  • Lurker
  • *
  • Karma: 0
  • Offline Offline
  • Posts: 42
    • View Profile
Re: Партиклы в одной ?цене по ?лоям.
« Reply #4 on: November 16, 2010, 12:53:04 PM »

Logged
 

Page created in 0.199 seconds with 22 queries.