Gamestudio Links
Zorro Links
Newest Posts
Purchase A8 full licence version
by jcl. 05/05/26 11:20
Z9 getting Error 058
by k_ivan. 04/25/26 19:13
ZorroGPT
by TipmyPip. 04/25/26 16:09
AUM Magazine
Latest Screens
Dorifto samurai
Shadow 2
Rocker`s Revenge
Stug 3 Stormartillery
Who's Online Now
5 registered members (VoroneTZ, AndrewAMD, alibaba, 2 invisible), 5,417 guests, and 14 spiders.
Key: Admin, Global Mod, Mod
Newest Members
dangyc, ukgamer, valino, juergenwue, VladMak
19211 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
Page 2 of 2 1 2
Re: Sprites with sides like in old 2d-3d-games [Re: GamerX] #237440
11/20/08 04:41
11/20/08 04:41
Joined: Jul 2008
Posts: 2,111
Germany
rayp Offline OP

X
rayp  Offline OP

X

Joined: Jul 2008
Posts: 2,111
Germany
maybe i made a mistake,too tired for such things...ive copyed ure code..will give it a try shocked


Acknex umgibt uns...zwischen Dir, mir, dem Stein dort...
"Hey Griswold ... where u gonna put a tree that big ?"
1998 i married my loved wife ... Sheeva from Mortal Kombat, not Evil-Lyn as might have been expected
rayp.flags |= UNTOUCHABLE;
Re: Sprites with sides like in old 2d-3d-games [Re: GamerX] #237585
11/20/08 20:05
11/20/08 20:05
Joined: Jul 2008
Posts: 2,111
Germany
rayp Offline OP

X
rayp  Offline OP

X

Joined: Jul 2008
Posts: 2,111
Germany
Its not so easy...when we do it that way. The directions are only correct if
the player cant walk around the entity...

ive tryed this but it dont works...
Code:
ACTION MY_3d_SPRITE {
my.oriented = on;my.facing = off;my.decal = off;
WHILE(1) {
## SIDE 1
 IF (MY.PAN > 0 &&  < 90) &&
    (CAMERA.PAN > 0) && (CAMERA.PAN < 90) { ENT_MORPH(ME, "BACK.PCX"); }
 IF (MY.PAN > 90) && (MY.PAN < 180) &&
    (CAMERA.PAN > 0) && (CAMERA.PAN < 90) { ENT_MORPH(ME, "FRONT.PCX"); }
 IF (MY.PAN > 180) && (MY.PAN < 270) &&
    (CAMERA.PAN > 0) && (CAMERA.PAN < 90) { ENT_MORPH(ME, "FRONT.PCX"); }
 IF (MY.PAN > 270) && (MY.PAN < 360) &&
    (CAMERA.PAN >0) && (CAMERA.PAN < 90) { ENT_MORPH(ME, "BACK.PCX"); }
################################################################################
## SIDE 2
 IF (MY.PAN > 0) && (MY.PAN < 90) &&
    (CAMERA.PAN > 90) && (CAMERA.PAN < 180) { ENT_MORPH(ME, "FRONT.PCX"); }
 IF (MY.PAN > 90) && (MY.PAN < 180) &&
    (CAMERA.PAN > 90) && (CAMERA.PAN < 180) { ENT_MORPH(ME, "BACK.PCX"); }
 IF (MY.PAN > 180) && (MY.PAN < 270) &&
    (PLAYER > 90) && (CAMERA.PAN < 180) { ENT_MORPH(ME, "RIGHT.PCX"); }
 IF (MY.PAN > 270) && (MY.PAN < 360) &&
    (CAMERA.PAN > 90) && (CAMERA.PAN < 180) { ENT_MORPH(ME, "FRONT.PCX"); }
################################################################################
## SIDE 3
 IF (MY.PAN > 0) && (MY.PAN < 90) &&
    (CAMERA.PAN > 180) && (CAMERA.PAN < 270) { ENT_MORPH(ME, "FRONT.PCX"); }
 IF (MY.PAN > 90) && (MY.PAN < 180) &&
    (CAMERA.PAN > 180) && (CAMERA.PAN < 270) { ENT_MORPH(ME, "LEFT.PCX"); }
 IF (MY.PAN > 180) && (MY.PAN < 270) &&
    (CAMERA.PAN > 180) && (CAMERA.PAN < 270) { ENT_MORPH(ME, "BACK.PCX"); }
 IF (MY.PAN > 270) && (MY.PAN < 360) &&
    (CAMERA.PAN > 180) && (CAMERA.PAN < 270) { ENT_MORPH(ME, "RIGHT.PCX"); }
################################################################################
## SIDE 4
 IF (MY.PAN > 0) && (MY.PAN < 90) &&
    (CAMERA.PAN > 270) && (PLAYER < 360) { ENT_MORPH(ME, "BACK.PCX"); }
 IF (MY.PAN > 90) && (MY.PAN < 180) &&
    (CAMERA.PAN > 270) && (CAMERA.PAN < 360) { ENT_MORPH(ME, "FRONT.PCX"); }
 IF (MY.PAN > 180) && (MY.PAN <270) &&
    (CAMERA.PAN > 270) && (CAMERA.PAN < 360) { ENT_MORPH(ME, "LEFT.PCX"); }
 IF (MY.PAN > 270) && (MY.PAN < 360) &&
    (CAMERA.PAN > 270) && (CAMERA.PAN < 360) { ENT_MORPH(ME, "BACK.PCX"); }
################################################################################

WAIT(5);
}
}

(maybe the sprites are not sortet correct, but the code dont work so i cant
sort them in the right way).
The sprite should have only 4 sides. The camera pans are in 90° steps like.
when walking a circle around the entity it should change like this:
Back Back Right Front Front Front Left Back

Anybody ideas about making Sprites with Sides ?

Last edited by rayp; 11/20/08 20:14.

Acknex umgibt uns...zwischen Dir, mir, dem Stein dort...
"Hey Griswold ... where u gonna put a tree that big ?"
1998 i married my loved wife ... Sheeva from Mortal Kombat, not Evil-Lyn as might have been expected
rayp.flags |= UNTOUCHABLE;
Re: Sprites with sides like in old 2d-3d-games [Re: rayp] #237587
11/20/08 20:11
11/20/08 20:11
Joined: Apr 2008
Posts: 600
Austria
Petra Offline
Support
Petra  Offline
Support

Joined: Apr 2008
Posts: 600
Austria
I think, using the camera.pan is wrong. What you probably need is the angle of the vector from the camera to the sprite. And I would not morph it but better use a 8-frame sprite and switch the frame, that's probably faster.

Re: Sprites with sides like in old 2d-3d-games [Re: Petra] #237588
11/20/08 20:18
11/20/08 20:18
Joined: Jul 2008
Posts: 2,111
Germany
rayp Offline OP

X
rayp  Offline OP

X

Joined: Jul 2008
Posts: 2,111
Germany
Can u explain me how to get this angle ?

Cant use...have to many animations it would be a name+200.tga file smile



Last edited by rayp; 11/20/08 20:40.

Acknex umgibt uns...zwischen Dir, mir, dem Stein dort...
"Hey Griswold ... where u gonna put a tree that big ?"
1998 i married my loved wife ... Sheeva from Mortal Kombat, not Evil-Lyn as might have been expected
rayp.flags |= UNTOUCHABLE;
Page 2 of 2 1 2

Gamestudio download | Zorro platform | shop | Data Protection Policy

oP group Germany GmbH | Birkenstr. 25-27 | 63549 Ronneburg / Germany | info (at) opgroup.de

Powered by UBB.threads™ PHP Forum Software 7.7.1