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

[INC] Temp Entity Util


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Xvil
BANNED
Join Date: Feb 2012
Old 03-29-2012 , 09:02   [INC] Temp Entity Util
Reply With Quote #1

Description:
This include Can Simplify Your Work Only.

Stocks:
Code:
stock temp_entity_beampoints(msg , svc, start[3],  end[3], sprite, starting_frame, frame_rate, life, line, noise, red, green, blue, brightness, scroll_speed) stock temp_entity_beampoint(msg, svc, start_entity,  end[3], sprite, starting_frame, frame_rate, life, line, noise, red, green, blue, brightness, scroll_speed) stock temp_entity_gunshot(msg,svc, start[3]) stock temp_entity_explosion(msg, svc, start[3], sprite, scale, framerate, flags) stock temp_entity_tarexplosion(msg, start[3]) stock temp_entity_smoke(msg, svc, start[3], sprite, scale, framerate) stock temp_entity_tracer(msg, svc, start[3], end[3]) stock temp_entity_lightning(msg, svc, start[3], end[3], life, width, amplitude, sprite) stock temp_entity_beaments(msg, svc, start_entity, end_entity, sprite, starting_frame, frame_rate, life, line, noise, red, green, blue, brightness, scroll_speed) stock temp_entity_sparks(msg, svc, position[3]) stock temp_entity_lavasplach(msg, svc, start[3]) stock temp_entity_teleport(msg, svc, start[3]) stock temp_entity_explosion2(msg, svc, start[3], stating_color, num_color) stock temp_entity_bspdecal(msg, svc, x, y, z, texture_index, entity_index) stock temp_entity_implosion(msg, svc, start[3], radius, count, life) stock temp_entity_spritetrail(msg, svc, start[3], end[3], sprite, count, life, scale, velocity, randomness) stock temp_entity_sprite(msg, svc, start[3], sprite, scale, brightness) stock temp_entity_beamsprite(msg, svc, start[3], end[3], beam_sprite, end_sprite) stock temp_entity_beamtrous(msg, svc, centre_position[3], axis_radius[3], sprite, starting_frame, frame_rate, life, line, noise, red, green, blue, brightness, scroll_speed) stock temp_entity_beamdisk(msg, svc, centre_position[3], axis_radius[3], sprite, starting_frame, frame_rate, life, line, noise, red, green, blue, brightness, scroll_speed) stock temp_entity_beamcylinder(msg, svc, centre_position[3], axis_radius[3], sprite, starting_frame, frame_rate, life, line, noise, red, green, blue, brightness, scroll_speed) stock temp_entity_beamfollow(msg, svc, entity, sprite, life, line, red, green, blue, brightness) stock temp_entity_glowsprite(msg, svc, position[3], sprite,life, scale, brightness) stock temp_entity_beamring(msg, svc, start_entity, end_entity, sprite, starting_frame, frame_rate, life, line, noise, red, green, blue, brightness, scroll_speed) stock temp_entity_streak_splash(msg, svc, start[3], direction_vector[3], color, count, base_speed, volocity) stock temp_entity_dynamic_light(msg, svc, position[3], radius, red, green, blue, life, decay_rate) stock temp_entity_entity_light(msg, svc, entity ,initial_position[3], radius, red, green, blue, life, decay_rate) stock temp_entity_killbeam(msg, svc, entity) stock temp_entity_bloodstream(msg, svc, start[3], spray_vector[3], color, speed) stock temp_entity_showline(msg, svc, start[3], end[3]) stock temp_entity_blood(msg, svc, start[3], spray_vector[3], color, speed) stock temp_entity_decal(msg, svc, x, y, z, texture, entity) stock temp_entity_fizz(msg, svc, entity, sprite, density) stock temp_entity_model(msg, svc, position[3], velocity[3], initial_yaw, model_index, bounce_sound_type, life) stock temp_entity_explode_model(msg, svc, origin[3], velocity, model_index, count, life) stock temp_entity_break_model(msg, svc, position[3], size[3], velocity[3], random_velocity, sprite, count, life, flags) stock temp_entity_gunshot_decal(msg, svc, position[3], entity, decal) stock temp_entity_sprite_spray(msg, svc, position[3], velocity[3], sprite, count, speed, noise) stock temp_entity_armor_ricochet(msg, svc, posistion[3], scale) stock temp_entity_player_decal(msg, svc, playerindex, position[3], entity, decal_number, model_index) stock temp_entity_bubbles(msg, svc, min_start[3], max_start[3], float_height, model_index, count, speed)     stock temp_entity_bubbles_trail(msg, svc, min_start[3], max_start[3], float_height, model_index, count, speed) stock temp_entity_blood_sprite(msg, svc, position[3], sprite1, sprite2, color, scale)     stock temp_entity_world_decal(msg, svc, x, y, z, texture)     stock temp_entity_world_decal_light(msg, svc, x, y, z, texture)     stock temp_entity_decal_light(msg, svc, x, y, z, texture, entity)     stock temp_entity_projectile(msg, svc, position[3], velocity[3], model, life, owner)     stock temp_entity_spray(msg, svc, position[3], direction[3], model, count, speed, noise, rendermode)     stock temp_entity_player_sprites(msg, svc, player_num, sprite, count, variance) stock temp_entity_particleburst(msg, svc, origin[3], radius, color, duration) stock temp_entity_firefiled(msg, svc, origin[3], radius, model, count, flags, duration)     stock temp_entity_playerattachment(msg, svc, entity, vertical, model, life) stock temp_entity_kill_playerattachments(msg, svc, entity) stock temp_entity_multigunshot(msg, svc, origin[3], direction[3], x_noise, y_noise, count, bullethole)     stock temp_entity_user_tracer(msg, svc, origin[3], velocity[3], life, color, length)
Attached Files
File Type: inc temp_entity_util.inc (27.8 KB, 150 views)

Last edited by Xvil; 03-29-2012 at 10:48.
Xvil is offline
Xvil
BANNED
Join Date: Feb 2012
Old 03-29-2012 , 09:32   Re: [INC] Trace Util
Reply With Quote #2

Example:
PHP Code:
#include <amxmodx>
#include <amxmisc>
#include <temp_entity_util>

#define PLUGIN "trace_Test"
#define VERSION "1.0"
#define AUTHOR "Xvil"


public plugin_init() {
    
register_plugin(PLUGINVERSIONAUTHOR);
    
register_clcmd("+test""TraceUtilTest");
    
register_clcmd("test""Test")
}



public 
Test(id)
{
    new 
origin[3]
    
get_user_origin(idorigin)
    
message_begin(MSG_ALLSVC_TEMPENTITY_id)
    
write_byte(TE_IMPLOSION)
    
write_coord(origin[0]) 
    
write_coord(origin[1]) 
    
write_coord(origin[2] + 10
    
write_byte(200
    
write_byte(500
    
write_byte(50
    
message_end()
}

public 
TraceUtilTest(id)
{
    new 
origin[3]
    
get_user_origin(idorigin)
    
temp_entity_implosion(MSG_ALLSVC_TEMPENTITYidorigin20050050)
    
// temp_entity_implosion(MSG_ONE, SVC_TEMPENTITY, id, origin, 200, 500, 50)


Last edited by Xvil; 03-29-2012 at 10:32.
Xvil is offline
Exolent[jNr]
Veteran Member
Join Date: Feb 2007
Location: Tennessee
Old 03-29-2012 , 09:43   Re: [INC] Trace Util
Reply With Quote #3

1. Why is this called "trace" util?
2. Don't redefine all of those constants since they are already made with AMXX (see message_const.inc).
3. You don't have a parameter for player id's, so individual messages (MSG_ONE, MSG_ONE_UNRELIABLE) will just give errors.
4. Support for floating vectors would be nice.
Exolent[jNr] is offline
Xvil
BANNED
Join Date: Feb 2012
Old 03-29-2012 , 09:49   Re: [INC] Trace Util
Reply With Quote #4

Quote:
Originally Posted by Exolent[jNr] View Post
1. Why is this called "trace" util?
2. Don't redefine all of those constants since they are already made with AMXX (see message_const.inc).
3. You don't have a parameter for player id's, so individual messages (MSG_ONE, MSG_ONE_UNRELIABLE) will just give errors.
4. Support for floating vectors would be nice.
It's Called TracE From TE_*
Updated Thanks.

4. Support for floating vectors would be nice.
Wait it's a Hard Work

But I Must Set Float only vector O.o
And The velocity No ??

Last edited by Xvil; 03-29-2012 at 10:13.
Xvil is offline
Exolent[jNr]
Veteran Member
Join Date: Feb 2007
Location: Tennessee
Old 03-29-2012 , 10:09   Re: [INC] Trace Util
Reply With Quote #5

I'm not saying they should use those messages.
I'm saying that your include doesn't support them.
Individual messages require a player id, but your include doesn't have player id parameters in any function.
Therefore, individual messages aren't supported.

Also, MSG_PVS and MSG_PAS aren't supported by your include because they need a separate origin parameter to be passed.

EDIT:

Quote:
Originally Posted by Xvil View Post
It's Called TracE From TE_*
Oh yeah? Because in the include it says:
Code:
/* Temp entity message types for message_begin() */ #define TE_BEAMPOINTS               0        // Beam effect between two points
TE = Temp Entity
I mean, you are even using SVC_TEMPENTITY in every function.

And by floating vector support, I mean the actual vector and not rounding it when it's passed to the message.

Last edited by Exolent[jNr]; 03-29-2012 at 10:13.
Exolent[jNr] is offline
Xvil
BANNED
Join Date: Feb 2012
Old 03-29-2012 , 10:14   Re: [INC] Trace Util
Reply With Quote #6

Quote:
Originally Posted by Exolent[jNr] View Post
I'm not saying they should use those messages.
I'm saying that your include doesn't support them.
Individual messages require a player id, but your include doesn't have player id parameters in any function.
Therefore, individual messages aren't supported.

Also, MSG_PVS and MSG_PAS aren't supported by your include because they need a separate origin parameter to be passed.

EDIT:



Oh yeah? Because in the include it says:
Code:
/* Temp entity message types for message_begin() */ #define TE_BEAMPOINTS               0        // Beam effect between two points
TE = Temp Entity
I mean, you are even using SVC_TEMPENTITY in every function.

And by floating vector support, I mean the actual vector and not rounding it when it's passed to the message.
ok ;)
Xvil is offline
Exolent[jNr]
Veteran Member
Join Date: Feb 2007
Location: Tennessee
Old 03-29-2012 , 10:15   Re: [INC] Temp Entity Util
Reply With Quote #7

Almost forgot. You didn't delete all of the redundant defines. You apparently didn't look through message_const.inc for very long.
Exolent[jNr] is offline
Xvil
BANNED
Join Date: Feb 2012
Old 03-29-2012 , 10:26   Re: [INC] Temp Entity Util
Reply With Quote #8

Quote:
Originally Posted by Exolent[jNr] View Post
Almost forgot. You didn't delete all of the redundant defines. You apparently didn't look through message_const.inc for very long.
SVC added

All The Errors Fixed Only The Floating Vectors... Can You Help Me To Fix it because I'm Tired.
And Thanks!

Last edited by Xvil; 03-29-2012 at 10:49.
Xvil is offline
Arkshine
AMX Mod X Plugin Approver
Join Date: Oct 2005
Old 03-29-2012 , 10:56   Re: [INC] Temp Entity Util
Reply With Quote #9

Is that hard to wait having a decent knowledge before proposing things ? Wanted to help is welcomed but right now you don't know what you're doing... You should be able to see yourself now.

MSG_PVS/MSG_PAS still not fixed, nor floating vectors.
For the first Exolent told you what to do, for the second, see EngFunc_ constants, it supports float.
About how to organize things, it's up to you, I don't have suggestions.
__________________
Arkshine is offline
Exolent[jNr]
Veteran Member
Join Date: Feb 2007
Location: Tennessee
Old 03-29-2012 , 12:42   Re: [INC] Temp Entity Util
Reply With Quote #10

The fact that you changed the SVC_TEMPENTITY to be a parameter (as if it's going to be any other value besides SVC_TEMPENTITY) shows you don't even understand these messages and are just trying to make shorter code for it.
Before you try to make utilities for something, you should completely understand it first.
If you did understand it completely, then you wouldn't have made the mistakes that I've been pointing out (except for floating vectors since that's more of a feature).
Exolent[jNr] 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 14:31.


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