View Single Post
Slaz Slaz's Avatar

JCF Member

Joined: Aug 2004

Posts: 1,315

Slaz is OFF DA CHARTSlaz is OFF DA CHARTSlaz is OFF DA CHART

May 24, 2015, 04:13 AM
Slaz is offline
Reply With Quote
Quote:
Originally Posted by Violet CLM View Post
You may want to use some more sophisticated approach than jjRandom, or a frequency different than one particle per tick (regardless of screen width), but the important thing is that jjPLAYER::cameraX and jjPLAYER::cameraY are used for translating between level coordinates and screen coordinates.

If you end up deciding against PARTICLE::ICETRAIL, though, you could also create your own tiny particle class containing position, (maybe) color and (maybe) lifetime values, make an array of that class, and draw blue pixels (or small rectangles or something) directly to a non-layer jjCANVAS based on the array's contents' positions. But ICETRAIL is simpler if you don't want to figure out classes.
Your piece of code combined with ICETRAIL's color & delta values gave the exact result I was looking for. Many thanks! jjRandom makes it look fine, naturally there are more particles on the screen while standing still and less while the screen is scrolling. There's no need looking into classes or changing the frequency at all.

I will comment your name atop the script file.
__________________
Add SlazRabbit on Xbox Live if you want to play some GoW1/2/3/J or Destiny1/2.
Jazz Jackrabbit 2 Forever!!
Civilian Defence Force - Jazz2 Visual Fantasers