Jump to content

Emitter always horizontal?


Doctor Visage
 Share

You are about to reply to a thread that has been inactive for 1582 days.

Please take a moment to consider if this thread is worth bumping.

Recommended Posts

Hello! This part of the script allows to change the position of the emitter depending on the speed. But how to add here the possibility that the emitter is always exactly horizontal?

(and even better is it possible to make the emitter always at the same height and horizontally? 🤩)' <- regardless of speed and throttle.

Particle system is a ribbon, and due to the tilt of the vehicle, the ribbon sometimes goes wrong.

vector emitter_pos_max = < -1.15, 0.0, -0.170 > ;
vector emitter_pos_min = < -1.15, 0.0, -0.250 > ;
vector emitter_pos_range;

float speed_max = something;
float current_speed;

default
{
    state_entry ()
    {
        emitter_pos_range = emitter_pos_max - emitter_pos_min;
    }

    some_event ()
    {
        llSetLinkPrimitiveParamsFast (emitter_link_number, 
        [
            PRIM_POS_LOCAL, emitter_pos_min + (emitter_pos_range * (current_speed / speed_max))
        ]);
    }
}

 

Edited by Doctor Visage
Link to comment
Share on other sites

You are about to reply to a thread that has been inactive for 1582 days.

Please take a moment to consider if this thread is worth bumping.

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
 Share

×
×
  • Create New...