Log In  


New Feature: Texture Loop can now be set to 1-4.

Small Feature: Texture image import can now be undo'd.

Sample Code

The rendering engine for this tool has been adjusted to make it easier to handle multiple models.

Global rotation, camera coordinates, pivot coordinates. We'll refine these features as we create game models, and if we find any useful patterns, we'll share them.

_p_grot={0,0,0}
_p_gscale=3

v1=objload({1,2},{3},{4,5}) --eggplant
v1.scale={1,1,1}
v1.rot={0.18,0.02,0}
objrot(v1,nil,nil,nil,5) --hold rotated vtx
v1.orig={-8,-1.5,0}
v1.rot={0,0,0}

v2=objload({1,2},{3},{4,5}) --eggplant(reversed)
v2.scale={1,1,1}
v2.rot={0.08,0.24,0}
objrot(v2,nil,nil,nil,5) --hold rotated vtx
v2.orig={0,-6,0}
v2.rot={0,0,0}

v3=objload({1,2},{3},{4,5}) --eggplant
v3.scale={1,1,1}
v3.rot={0.12,0.02,0}
objrot(v3,nil,nil,nil,5) --hold rotated vtx
v3.orig={8,-1.5,0}
v3.rot={0,0,0}

v4=objload({16,17,18},,{20,21,22}) --plate
v4.scale={2,2,2}
v4.rot={0,0,0}
objrot(v4,nil,nil,nil,5) --hold rotated vtx
v4.orig={0,2,0}
v4.rot={0,0,0}

_p_grot={0.50,-0.04,0}
_cnt=0
_set_fps(60)
while 1 do
cls(3)
_cnt+=1
_p_grot[1]=_cnt/1024
objrot(v1)
objrot(v2)
objrot(v3)
objrot(v4)
addraster(v1,'tx')
addraster(v2,'tx')
addraster(v3,'tx')
addraster(v4,'tx')
drawraster()
_p_lpos={sin(time()/2)*64+64,16,cos(time()/2)*64+64}
_p_gscale=sin(time()/8)*1+3
flip()
end

Learn more

https://bitchunk.itch.io/pelogen2/devlog/1018175/pelogen2-v24-released

2



[Please log in to post a comment]