Hello,
I was wondering how to make an "earthquake" type effect
I was thinking something like this, but please fill in the gaps, I am very new at this and suck at the whole model/sprites/effects part of pawn coding
PHP Code:
new gmsgShake = get_user_msgid ( "ScreenShake" );
new eq_Sprite = precache_model ( "sprites/shockwave.spr" );
new origin[3];
get_user_origin( enemy, origin );
// random "earth shaking" - this part doesnt work or look right
message_begin ( MSG_PVS, SVC_TEMPENTITY, origin );
write_byte ( TE_IMPLOSION );
write_coord ( origin[0] + random_num ( -100, 100 ) );
write_coord ( origin[1] + random_num ( -100, 100 ) );
write_coord ( origin[2] + random_num ( -50, 50 ) );
write_short ( eq_Sprite );
write_byte ( random_num ( 0,20 ) + 20 );
write_byte ( 12 );
write_byte ( TE_EXPLFLAG_NONE );
message_end ( );
//Then I do some code in between here
//to determine which players are near the targeted player
//and shake their screen like they were in earth quake
message_begin( MSG_ONE, gmsgShake, { 0, 0, 0 }, targetid );
write_short( 255<< 14 );
write_short( 10 << 14 );
write_short( 255<< 14 );
message_end( );
Can anyone offer any advice?