【发布时间】:2010-02-02 16:58:11
【问题描述】:
我正在为我们的学生游戏编写粒子系统,但遇到了一些障碍。我想提高对飞船火箭的影响,但我似乎不知道如何。
以下是静止船的效果:
这是它在移动的船上的样子:
我希望火焰始终保持相同的长度。这是Particle 的Tick 函数:
void Particle::Tick(float a_DT)
{
// temporarily turned off to see the effect of the rest of the code more clearly
//m_Pos += m_Vel;
if (m_Owner) { m_Pos += m_Owner->GetParentSpeed(); }
m_Life -= 1;
if (m_Life <= 0) { m_Alive = false; }
}
提前致谢。
编辑:为了澄清一点,我希望效果跟随,但无论发射器的速度如何,我都希望它以相同的方式跟随。
【问题讨论】:
-
我不明白你所说的“长度一致”是什么意思,你的意思是你不希望效果有痕迹?