Graal Forums

Graal Forums (https://forums.graalonline.com/forums/index.php)
-   Gani Construction (https://forums.graalonline.com/forums/forumdisplay.php?f=50)
-   -   Changing players shadow image (https://forums.graalonline.com/forums/showthread.php?t=134264412)

callimuc 08-30-2011 02:19 AM

Changing players shadow image
 
Hey there. I got one quick question. First off: I wasn´t sure if I should place it here or in the Scripting Forums

How can I change the shadows image of the player?
I know there is the setspritesimage() command but what I want is something like this:
As example I want to remake the walk.gani and add a shadow of the player which got 4 directions, it should also change in the gani (so far so good, just by removing the shadow and placing my shadow images). But how can I make it when I change the players.z that the shadow image will stay down? So my new 4 images will get counted as the default shadow. Or would that need to be scripted like:

PHP Code:

findimg(index).rotation 6.25 player.dir//think 6.25 is a 360° turn. 


ffcmike 08-30-2011 02:56 AM

This isn't possible to do the simple way because only sprite index 0 will stay in position once Z is adjusted.
It would be somewhat of a hack but you could try having 4 different ganis for each direction.

callimuc 08-30-2011 03:09 AM

Ok thanks. So it should look like this:
PHP Code:

setani("ganiname_"@player.dirNULL

(thought because it would save space unlike using
PHP Code:

if (player.dir 0) {
if (
player.dir 1) {
//... 

Or what about using showimg() for each direction? What would be best?

ffcmike 08-30-2011 03:21 AM

Quote:

Originally Posted by callimuc (Post 1666167)
Ok thanks. So it should look like this:
PHP Code:

setani("ganiname_"@player.dirNULL

(thought because it would save space unlike using
PHP Code:

if (player.dir 0) {
if (
player.dir 1) {
//... 

Or what about using showimg() for each direction? What would be best?

Using showimg() would probably be more convenient, but using separate ganis would be more efficient.

callimuc 08-30-2011 03:40 AM

Ok thanks


All times are GMT +2. The time now is 02:15 PM.

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2026, vBulletin Solutions Inc.
Copyright (C) 1998-2019 Toonslab All Rights Reserved.