Single Surface Particles
Blitz3D Forums/Blitz3D Programming/Single Surface Particles
| ||
anyone got code for single surface particles that can use animated textures? |
| ||
I think what you need to do, is store the frames inside the one texture. Then adjust the UV co-ords to select the frame you want. I imagine you could make a function that would copy the animated texture into a single texture. The result would be the same :o) |
| ||
thats what i thought.. MAN i hate the Blitz3D sprite system! how does the textures fix. are the 1=100% of texture? iv got an image 256 x 2176 what about the number be if wanted 64x64 my brain isn't working.. to much drink from lastnight considering... s.sprite=New sprite s\verti[0]=AddVertex(surf,0,0,0,0,1) ;topleft ;0--1 s\verti[1]=AddVertex(surf,0,0,0,1,1) ;topright ;| /| s\verti[2]=AddVertex(surf,0,0,0,0,0) ;bottomleft ;|/ | s\verti[3]=AddVertex(surf,0,0,0,1,0) ;bottomright ;2--3 AddTriangle(surf,s\verti[1],s\verti[2],s\verti[3]) AddTriangle(surf,s\verti[2],s\verti[1],s\verti[0]) VertexTexCoords surf,s\verti[0],0,.25 VertexTexCoords surf,s\verti[1],.005,.005 VertexTexCoords surf,s\verti[2],0,0 VertexTexCoords surf,s\verti[3],.005,0 |
| ||
Yes, 1 = 100%. But what about 'LoadAnimTexture'? Rhy :) |
| ||
it wouldn't work for single surface's i have multiple particle graphics and the only way to do it is positioning the texture coords to vertex. I hate this stuff! takes too long for me to do but i need a single serface sprite system now |
| ||
Why not use one of the free libraries already available, like RottParticles or Lotus? (Thanks Rottbott and Noel! =) ) |
| ||
i got something working here, its a simple one iv created based on someone's single surface particle thing... iv even got "frame animations" working too! |