Raised This Month: $12 Target: $400
 3% 

How to draw a circle that surround a client


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
8guawong
AlliedModders Donor
Join Date: Dec 2013
Location: BlackMarke7
Old 08-14-2015 , 00:45   How to draw a circle that surround a client
Reply With Quote #1

heres what i tried

PHP Code:
    new Float:vec[3];
    
GetClientAbsOrigin(clientvec);
        
    
vec[2] += 10;
    
TE_SetupBeamRingPoint(vec99.0100.0g_BeamSpriteg_HaloSprite0151.05.00.0, {00255255}, 100);
    
TE_SendToAll(); 
if i use 100.0 for the initial ring radius the circle won't show
with initial ring radius set to 99.0 will show
but its more like a beacon
i want a circle that does not expand or have animation
8guawong is offline
Michalplyoutube
Veteran Member
Join Date: Jan 2013
Location: Tank Carrier in Mannhatt
Old 08-14-2015 , 02:21   Re: How to draw a circle that surround a client
Reply With Quote #2

Not posible to make it be 100% a cricle it will be cubish u need many points and then connect them or many rings of beam
__________________
The plugin developer of TF2BWR Reborn
And a TF2 Player
Michalplyoutube is offline
8guawong
AlliedModders Donor
Join Date: Dec 2013
Location: BlackMarke7
Old 08-14-2015 , 05:34   Re: How to draw a circle that surround a client
Reply With Quote #3

ok how about how to use

void TE_SetupBeamRing(int StartEntity, int EndEntity, int ModelIndex, int HaloIndex, int StartFrame, int FrameRate, float Life, float Width, float Amplitude, const int Color[4], int Speed, int Flags)

not sure what to put for StartEntity and EndEntity
8guawong is offline
Michalplyoutube
Veteran Member
Join Date: Jan 2013
Location: Tank Carrier in Mannhatt
Old 08-14-2015 , 06:01   Re: How to draw a circle that surround a client
Reply With Quote #4

U need points from beam ends and starts
__________________
The plugin developer of TF2BWR Reborn
And a TF2 Player
Michalplyoutube is offline
8guawong
AlliedModders Donor
Join Date: Dec 2013
Location: BlackMarke7
Old 08-14-2015 , 06:19   Re: How to draw a circle that surround a client
Reply With Quote #5

Quote:
Originally Posted by Michalplyoutube View Post
U need points from beam ends and starts
can post an example?

cuz i tried googling and searching the forum but could not find any

https://wiki.alliedmods.net/File:Te_beamring.jpg

Last edited by 8guawong; 08-14-2015 at 07:04.
8guawong is offline
abgar
Senior Member
Join Date: Apr 2015
Old 08-14-2015 , 08:34   Re: How to draw a circle that surround a client
Reply With Quote #6

Try inverting the start and end radius?

new Float:vec[3];
GetClientAbsOrigin(client, vec);

vec[2] += 10;
TE_SetupBeamRingPoint(vec, 100.0, 99.0, g_BeamSprite, g_HaloSprite, 0, 15, 1.0, 5.0, 0.0, {0, 0, 255, 255}, 10, 0);
TE_SendToAll();

This has worked well for me in the past.
Also, depending on what HaloSprite you're using, will change the effect and the 'cleanliness' of the ring
abgar is offline
8guawong
AlliedModders Donor
Join Date: Dec 2013
Location: BlackMarke7
Old 08-14-2015 , 09:34   Re: How to draw a circle that surround a client
Reply With Quote #7

Quote:
Originally Posted by abgar View Post
Try inverting the start and end radius?

new Float:vec[3];
GetClientAbsOrigin(client, vec);

vec[2] += 10;
TE_SetupBeamRingPoint(vec, 100.0, 99.0, g_BeamSprite, g_HaloSprite, 0, 15, 1.0, 5.0, 0.0, {0, 0, 255, 255}, 10, 0);
TE_SendToAll();

This has worked well for me in the past.
Also, depending on what HaloSprite you're using, will change the effect and the 'cleanliness' of the ring
yea i was using this

PHP Code:
    g_BeamSprite PrecacheModel("materials/sprites/bomb_planted_ring.vmt");
    
g_HaloSprite PrecacheModel("materials/sprites/halo.vmt"); 
and after switching to this

PHP Code:
    g_BeamSprite PrecacheModel("materials/sprites/laserbeam.vmt");
    
g_HaloSprite PrecacheModel("materials/sprites/glow.vmt"); 
looks much better

Last edited by 8guawong; 08-14-2015 at 09:35.
8guawong is offline
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


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


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