Graal Forums

Graal Forums (https://forums.graalonline.com/forums/index.php)
-   NPC Scripting (https://forums.graalonline.com/forums/forumdisplay.php?f=8)
-   -   Rotating GANI Sprites (https://forums.graalonline.com/forums/showthread.php?t=67158)

zokemon 07-05-2006 08:14 AM

Rotating GANI Sprites
 
Yes this is a gani question but I don't think anyone in there can anwser this...

I can do:
player.ani.sprites[index].rotation = float;

This will rotate the sprites in my gani right?
Now I want to be able to rotate the sprites directly from the gani.
What would be PERFECT would be something much like the COLOREFFECT and ZOOMEFFECT in the gani text like this:
ROTATIONEFFECT 200 <myrotationnumber>

Another option might be to simply rotate the sprites when the gani is initialized (via gani script)...I'll look into this one some more.

Anyone got any ideas?
(And if you could add the ROTATIONEFFECT thing to the next version of graal it would be wonderful)

xXziroXx 07-05-2006 12:43 PM

Quote:

Originally Posted by Stefan
For rotating images you can either:
- use the GS2 function findimg(index) and use the attribute "rotation" (see Graal Bible):
PHP Code:

with (findimg(200)) {
  
player.x;
  
player.y;
  
image "bush.png";
  
rotation pi/2;


- set sprite attributes in a gani by editing the gani with a text editor and add a line like this
NPC Code:

ROTATEEFFECT spritenumber angle



There you go.

zokemon 07-07-2006 02:39 AM

Quote:

Originally Posted by xXziroXx
There you go.

Never knew that worked...thanks
(Obviously more knowledgable then those #gscript guys e_e)


All times are GMT +2. The time now is 01:40 AM.

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