Hello,
I'm really stuck with this, if anyone could have a look at it that'd be much appreciated..
I've got particles as sprites and I would like a different sprite for every particle.
Appended to my Popnet is an attribute that overrides the material, that works fine.
Only when I tell it retrieve different images for each sprite does it bomb! See the render below.
I'm using the string: path/sprite`$ID%2`.tga
Thanks
Different Sprites
4110 5 1- aah
- Member
- 10 posts
- Joined: Feb. 2008
- Offline
- JColdrick
- Member
- 4140 posts
- Joined: July 2005
- Offline
- aah
- Member
- 10 posts
- Joined: Feb. 2008
- Offline
ah, brilliant thanks J.C - I'm such a knuckle head :? - I got the numbering of my maps all wrong. I had sprite1.tga & sprite2.tga.. it works now, thankyou.
The only other thing I'd like to get my head around is having 2 different image sequences that loop for the sprite material.
Lets say I have sprite1_000.tga to sprite1_010.tga
and sprite2_000.tga to sprite2_010.tga
what kind of expressions would I dabble with to get a result?
alex
The only other thing I'd like to get my head around is having 2 different image sequences that loop for the sprite material.
Lets say I have sprite1_000.tga to sprite1_010.tga
and sprite2_000.tga to sprite2_010.tga
what kind of expressions would I dabble with to get a result?
alex
- stevenong
- Member
- 1631 posts
- Joined: July 2005
- Offline
- JColdrick
- Member
- 4140 posts
- Joined: July 2005
- Offline
If you're happy without any time offset:
sprite`$ID%2`_$F3.tga
would work, but again make sure the root names are sprite0 and sprite1. You could always add 1 to the mod calculation I guess.
with a time offset, you'll want something along the lines of:
sprite`$ID%2_`padzero(3,$F + int(fit01(rand($ID),0,20)))`.tga
although I'm typing that blindy and someone will likely mock me soon…
That should add up to 20 frames to the current frame number, so you'd need to have post 20 frames as tmaps.
cheers,
J.C.
sprite`$ID%2`_$F3.tga
would work, but again make sure the root names are sprite0 and sprite1. You could always add 1 to the mod calculation I guess.
with a time offset, you'll want something along the lines of:
sprite`$ID%2_`padzero(3,$F + int(fit01(rand($ID),0,20)))`.tga
although I'm typing that blindy and someone will likely mock me soon…
That should add up to 20 frames to the current frame number, so you'd need to have post 20 frames as tmaps.
cheers,
J.C.
John Coldrick
- aah
- Member
- 10 posts
- Joined: Feb. 2008
- Offline
-
- Quick Links