View Single Post
Author Message
drekes
Veteran Member
Join Date: Jul 2009
Location: Vault 11
Old 12-30-2011 , 07:47   Lightning beam to aiming point
Reply With Quote #1

I've been trying to create a lightning beam to the point id is aiming.
This is part of a FM_CmdStart hook & is called when id presses IN_USE.

I've tried all the commented ways of message_begin() but i can't get it working.
I'm sure the message is called because the lower part of that code block does work.


I'm also not really understanding when to use the origin & id parameters of message_begin().
Can someone explain that ?

PHP Code:
                        new iOrigin[3], iAimOrigin[3];
                        
get_user_origin(idiOrigin1);
                        
get_user_origin(idiAimOrigin3);
                        
                        
// message_begin(MSG_BROADCAST, SVC_TEMPENTITY, iOrigin, id)
                        // message_begin(MSG_BROADCAST, SVC_TEMPENTITY, iOrigin)
                        // message_begin(MSG_BROADCAST, SVC_TEMPENTITY);
                        // message_begin(MSG_ALL, SVC_TEMPENTITY, iOrigin, id)
                        // message_begin(MSG_ALL, SVC_TEMPENTITY, iOrigin)
                        // message_begin(MSG_ALL, SVC_TEMPENTITY)
                        
write_byte(TE_LIGHTNING);
                        
write_coord(iOrigin[0]);
                        
write_coord(iOrigin[1]);
                        
write_coord(iOrigin[2]);
                        
write_coord(iAimOrigin[0]);
                        
write_coord(iAimOrigin[1]);
                        
write_coord(iAimOrigin[2]);
                        
write_byte(15);
                        
write_byte(50);
                        
write_byte(100);
                        
write_short(g_iSprLightning);
                        
message_end(); 
__________________

Quote:
Originally Posted by nikhilgupta345 View Post
You're retarded.
drekes is offline
Send a message via MSN to drekes