AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Scripting Help (https://forums.alliedmods.net/forumdisplay.php?f=11)
-   -   Creating sprites (https://forums.alliedmods.net/showthread.php?t=223368)

mammapappa 08-12-2013 18:10

Creating sprites
 
1 Attachment(s)
Hi i have a problem with making sprites the right size could somone make me a code for this sprite

This is what i need help with to only show 1 big sprite instead of many small ones

PHP Code:

                new Float:origin1[3];
            new 
Float:origin2[3];
            
entity_get_vector(entEV_VEC_originorigin1);
            
entity_get_vector(entEV_VEC_originorigin2);
            
origin1[0] -= 32.0;
            
origin1[1] -= 32.0;
            
origin1[2] += 10.0;
            
origin2[0] += 32.0;
            
origin2[1] += 32.0;
            
origin2[2] += 10.0;
                
            
//get a random height for the flame
            //new randHeight = random_num(0, 32) + 16;
                
            //show some effects
            
message_begin(MSG_BROADCASTSVC_TEMPENTITY);
            
write_byte(TE_BUBBLES);
            
write_coord(floatround(origin1[0], floatround_floor));    //min start position
            
write_coord(floatround(origin1[1], floatround_floor));
            
write_coord(floatround(origin1[2], floatround_floor));
            
write_coord(floatround(origin2[0], floatround_floor));    //max start position
            
write_coord(floatround(origin2[1], floatround_floor));
            
write_coord(floatround(origin2[2], floatround_floor));
            
write_coord(48);                    //float height
            
write_short(gSpriteIdHeal);                //model index
            
write_byte(1);                        //count
            
write_coord(1);                        //speed
            
message_end(); 


Black Rose 08-12-2013 20:32

Re: Creating sprites
 
Try using TE_SPRITE instead of TE_BUBBLES

Code:
#define TE_SPRITE 17 // additive sprite, plays 1 cycle // coord, coord, coord (position) // short (sprite index) // byte (scale in 0.1's) // byte (brightness)

mammapappa 08-13-2013 00:23

Re: Creating sprites
 
1 Attachment(s)
Quote:

Originally Posted by Black Rose (Post 2011827)
Try using TE_SPRITE instead of TE_BUBBLES

Code:
#define TE_SPRITE 17 // additive sprite, plays 1 cycle // coord, coord, coord (position) // short (sprite index) // byte (scale in 0.1's) // byte (brightness)

that didnt work i want like this one http://youtu.be/pIf-NEqCyyI?t=24s

if someone could add that to my bm?


All times are GMT -4. The time now is 16:00.

Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.