Hi, i first i'm sorry for my English. I from Poland.
I'm working on my Tower Defense Mod and I need to create circle of a range of turrets.
And I'm looking for a message which create a circle...
I use this:
PHP Code:
stock msg_beamring(id, startent, endent, spriteindex, life, width, Color[3], brithgness)
{
message_begin(MSG_ONE_UNRELIABLE ,SVC_TEMPENTITY, _, id) //message begin write_byte(TE_BEAMRING)
write_short(startent)
write_short(endent)
write_short(spriteindex)
write_byte(1)
write_byte(1)
write_byte(life)
write_byte(width)
write_byte(1)
write_byte(Color[0])
write_byte(Color[1])
write_byte(Color[2])
write_byte(brithgness)
write_byte(1)
message_end() }
and this
PHP Code:
stock msg_circle(id, vec1[3], sprite, Color[3], distance)
{
message_begin(MSG_ONE, SVC_TEMPENTITY, vec1, id)
write_byte( 21 )
write_coord(vec1[0])
write_coord(vec1[1])
write_coord(vec1[2])
write_coord(vec1[0])
write_coord(vec1[1])
write_coord(vec1[2] + distance)
write_short( sprite )
write_byte( 0 ) // startframe
write_byte( 0 ) // framerate
write_byte( 11 ) // life
write_byte( 16 ) // width
write_byte( 0 ) // noise
write_byte( Color[0] ) // r
write_byte( Color[1]) // g
write_byte( Color[2] ) // b
write_byte( 255 ) //brightness
write_byte( 0 ) // speed
message_end() }
and in 1 example I must create 2 entity which a spaced of towers about
(example)
1 entity: +700 units
2 entity: -700 units
and then I use TE_BEAMRING of ID this two ents.
It's work, but are problems.
The line of range is usually in the wrong place.
=====
So my question is:
there is a message that creates a circle based on Origin?
( I'm very sorry for my english, I'm 15)