Gamestudio Links
Zorro Links
Newest Posts
Zorro 2.70
by jcl. 09/29/25 09:24
optimize global parameters SOLVED
by dBc. 09/27/25 17:07
ZorroGPT
by TipmyPip. 09/27/25 10:05
assetHistory one candle shift
by jcl. 09/21/25 11:36
Plugins update
by Grant. 09/17/25 16:28
AUM Magazine
Latest Screens
Rocker`s Revenge
Stug 3 Stormartillery
Iljuschin 2
Galactic Strike X
Who's Online Now
2 registered members (AndrewAMD, TipmyPip), 12,709 guests, and 5 spiders.
Key: Admin, Global Mod, Mod
Newest Members
krishna, DrissB, James168, Ed_Love, xtns
19168 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
Page 1 of 2 1 2
Decal shadows problem #366248
04/02/11 11:28
04/02/11 11:28
Joined: Jul 2004
Posts: 785
Serbia
Iglarion Offline OP
User
Iglarion  Offline OP
User

Joined: Jul 2004
Posts: 785
Serbia
I have a problem with the decal shadows if i use an animated scene, which in itself has the frames that slightly deviate from the central position in the MED, or coming out of its initial position, then shadow size follow new hull size of my current player frame. The example, I have a shield in my player model that at some point a player can throw and hit the enemy.
After this, the size of the player shadow get a new size, which is proportional to the size of hull my attack animation scene.
Here is picture where we can see my problem:

http://img820.imageshack.us/i/shadowproblem.jpg/

For the size of the collision hull in my player code i use FAT flag = OFF and NARROW = ON.

How to call a deacal shadow size only from the first frame all the time, i think then it would not have this problem?

Sorry about my bad english crazy

Re: Decal shadows problem [Re: Iglarion] #366251
04/02/11 11:55
04/02/11 11:55
Joined: Nov 2008
Posts: 216
J
jane Offline
Member
jane  Offline
Member
J

Joined: Nov 2008
Posts: 216
for the decal-shadow use a sprite

ENTITY* player_shadow = { type = "your_shadow_sprite.tga";}

action player()
{
set(my,SHADOW);
my.shadow = player_shadow;
while(1)
{
player_shadow.scale_x = 0.5;
player_shadow.scale_y = player_shadow.scale_x;
wait(1);
}
}

Re: Decal shadows problem [Re: jane] #366257
04/02/11 12:26
04/02/11 12:26
Joined: Jul 2004
Posts: 785
Serbia
Iglarion Offline OP
User
Iglarion  Offline OP
User

Joined: Jul 2004
Posts: 785
Serbia
Thank you Jane for replay.
But this wont work, decal shadow again call default shadow sprite from A8 folder, and i again have same problems. I really hate new decal shadow system in A8 (or i missed something?).

Re: Decal shadows problem [Re: Iglarion] #366259
04/02/11 13:47
04/02/11 13:47
Joined: Nov 2008
Posts: 216
J
jane Offline
Member
jane  Offline
Member
J

Joined: Nov 2008
Posts: 216
how you can see this works without problems

http://www.imgbox.de/show/img/NTboO1gL1z.jpg


Edit:

ok, problem: the sprite dont react on scale_x, scale_y

Last edited by jane; 04/02/11 14:35.
Re: Decal shadows problem [Re: jane] #366272
04/02/11 15:10
04/02/11 15:10
Joined: Jul 2004
Posts: 785
Serbia
Iglarion Offline OP
User
Iglarion  Offline OP
User

Joined: Jul 2004
Posts: 785
Serbia
Yes I'm wrong when i said that it reloads the shadow sprite from defuult folder A8, sprite has changed but had no effect on scale_x/y and then i was think that default sprite is load.
There must be some way to keep whole time scale x/y of my shadow sprite?


Re: Decal shadows problem [Re: Iglarion] #366295
04/02/11 17:21
04/02/11 17:21
Joined: Nov 2008
Posts: 216
J
jane Offline
Member
jane  Offline
Member
J

Joined: Nov 2008
Posts: 216
the easiest way is to make a simple invisible passable cubemodel on the player position and let them create the shadow

Last edited by jane; 04/02/11 17:23.
Re: Decal shadows problem [Re: jane] #366302
04/02/11 18:05
04/02/11 18:05
Joined: Jul 2004
Posts: 785
Serbia
Iglarion Offline OP
User
Iglarion  Offline OP
User

Joined: Jul 2004
Posts: 785
Serbia
Yes Jane, i thinking about this and also about make my own shadow code, but why... i still cant belive that there are no other options for this...

Maybe JCL have some solution?


IGRAVISION Page - www.igravision.com
RPG project - The Battle For Forgol 92.75%
Re: Decal shadows problem [Re: Iglarion] #366336
04/02/11 21:46
04/02/11 21:46
Joined: Nov 2008
Posts: 216
J
jane Offline
Member
jane  Offline
Member
J

Joined: Nov 2008
Posts: 216
here a pic with small and big hull, the Decalshadow remains equal.

http://www.imgbox.de/show/img/zn1SgBk7e8.jpg

you have to set shadow_stencil = 4;

and the player:

Code:
ENTITY* player_shadow = { type = "your_shadow_sprite.tga";}

action player()
{
set(my,SHADOW);
my.shadow = player_shadow;
}




Last edited by jane; 04/02/11 21:57.
Re: Decal shadows problem [Re: jane] #366339
04/02/11 22:26
04/02/11 22:26
Joined: Jul 2004
Posts: 785
Serbia
Iglarion Offline OP
User
Iglarion  Offline OP
User

Joined: Jul 2004
Posts: 785
Serbia
Hi Jane,
problem is i cant set stencil shadow this will >KILL< frame rate in my big levels, and this is reason why i need decal shadows.
My hull not changed after i play attack animation, only sprite scale x/y:

http://img8.imageshack.us/i/shadowproblem2.jpg/

I do not know how decal shadow take size for my player, but if i have frames like in first picture from MED, then shadow sprite get scale of this frame - distance of the player to the final point where ends flying of shild.



Re: Decal shadows problem [Re: Iglarion] #366343
04/02/11 22:53
04/02/11 22:53
Joined: Nov 2008
Posts: 216
J
jane Offline
Member
jane  Offline
Member
J

Joined: Nov 2008
Posts: 216
All models with "Shadow -Flag" must assigned a sprite, than "shadow_stencil = 4;" has no influence on the frame rate

with shadow_stencil = 0; is the same effect.

use my.shadow = player_shadow;

and the scale of decal is permanent



Last edited by jane; 04/02/11 23:35.
Re: Decal shadows problem [Re: jane] #366510
04/04/11 17:58
04/04/11 17:58
Joined: Jul 2004
Posts: 785
Serbia
Iglarion Offline OP
User
Iglarion  Offline OP
User

Joined: Jul 2004
Posts: 785
Serbia
Thank you Jane very much for your time, but this also wont work. About second solution - attach invisible model to player, this also wont work beasuse invisible models cant cast shadow.

I also try delate shild from my player model and i attach shild troungt code, to one bone, like new model but i have same problem.

Ok, my next questions is:
1. Of which things precisely depends the scale x/y of my shadow sprite?
2. How resize sprite for decal shadows on one entity?

Re: Decal shadows problem [Re: Iglarion] #366573
04/05/11 11:58
04/05/11 11:58
Joined: Nov 2008
Posts: 216
J
jane Offline
Member
jane  Offline
Member
J

Joined: Nov 2008
Posts: 216
you got a PM with a altrnative Decal-Shadows-Version while deactivated dynamic shadows ( shadow_stencil = -1; ), with lite-c works fine, i hope it work with c-script.

Re: Decal shadows problem [Re: jane] #366704
04/06/11 15:08
04/06/11 15:08
Joined: Jul 2004
Posts: 785
Serbia
Iglarion Offline OP
User
Iglarion  Offline OP
User

Joined: Jul 2004
Posts: 785
Serbia
Thank you Jane for PM!

Please can we return only to the decal shadows. I already have some other options make my own shadow code in style old Z-buffer shadows, but i only want to know did in my chase i can use decal shadow or not?


IGRAVISION Page - www.igravision.com
RPG project - The Battle For Forgol 92.75%
Re: Decal shadows problem [Re: Iglarion] #366921
04/07/11 22:40
04/07/11 22:40
Joined: Jul 2004
Posts: 785
Serbia
Iglarion Offline OP
User
Iglarion  Offline OP
User

Joined: Jul 2004
Posts: 785
Serbia
Only to say problem solved when i back on version A8.03.2. Looks like a bug in decal shadows. I only can report this in bug section.


IGRAVISION Page - www.igravision.com
RPG project - The Battle For Forgol 92.75%
Re: Decal shadows problem [Re: Iglarion] #369453
05/04/11 15:45
05/04/11 15:45
Joined: Aug 2008
Posts: 394
Germany
Benni003 Offline
Senior Member
Benni003  Offline
Senior Member

Joined: Aug 2008
Posts: 394
Germany
I have also this problem.
I need to make the decal shadows smaller. But if I use scale it's not working.
Does anyone know how it works? It's very important....

Re: Decal shadows problem [Re: Benni003] #369589
05/05/11 12:35
05/05/11 12:35
Joined: Apr 2008
Posts: 2,488
ratchet Offline
Expert
ratchet  Offline
Expert

Joined: Apr 2008
Posts: 2,488
@Iglarion :

Why not using a simple rounded blob under the player ,
with the DECAL system ?

This the way used for performance , even in some AAA Games on PC.

Re: Decal shadows problem [Re: ratchet] #369598
05/05/11 13:10
05/05/11 13:10
Joined: Aug 2008
Posts: 394
Germany
Benni003 Offline
Senior Member
Benni003  Offline
Senior Member

Joined: Aug 2008
Posts: 394
Germany
Yes, I can do it, but why we have the decal shadows when we can't use them ( scale them) ??

Re: Decal shadows problem [Re: Benni003] #369635
05/05/11 18:33
05/05/11 18:33
Joined: Jul 2004
Posts: 785
Serbia
Iglarion Offline OP
User
Iglarion  Offline OP
User

Joined: Jul 2004
Posts: 785
Serbia
@Ratchet
Benni has just answered for me laugh

Anyway, now i do not have this problem, and for every problem there is more solution, but i hate when something is so simple - become so complcated...
Like Benni say if A8 have decal shadows we want use decal shadows - without any problem in any situation.


IGRAVISION Page - www.igravision.com
RPG project - The Battle For Forgol 92.75%
Re: Decal shadows problem [Re: Iglarion] #369826
05/07/11 15:21
05/07/11 15:21
Joined: Aug 2008
Posts: 394
Germany
Benni003 Offline
Senior Member
Benni003  Offline
Senior Member

Joined: Aug 2008
Posts: 394
Germany
Please JCL,
make the decal shadows good working!

Page 1 of 2 1 2

Moderated by  HeelX, Spirit 

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