Kód: #include <amxmodx> #include <wtf> #include <engine>
new Weapon:weapon_scigun public weapons_init() { weapon_scigun = register_weapon(weapontype_automatic) weapon_config(weapon_scigun,"weaponname","weapon_scigun") weapon_config(weapon_scigun,"rateoffire","0.5") weapon_config(weapon_scigun,"deploydelay","0.5") weapon_config(weapon_scigun,"attackforward","scigun_attack") weapon_config(weapon_scigun,"drawanim","6") weapon_config(weapon_scigun,"attackanim","1") weapon_config(weapon_scigun,"viewmodel","models/v_shotgun.mdl") weapon_config(weapon_scigun,"playermodel","models/p_shotgun.mdl") } public plugin_precache() { precache_model("models/v_shotgun.mdl") precache_model("models/p_shotgun.mdl") precache_model("models/scientistt.mdl") precache_model("models/scientist.mdl") precache_sound("scientist/scream01.wav") precache_sound("scientist/scream02.wav") precache_sound("scientist/scream07.wav") precache_sound("scientist/scream04.wav") precache_sound("scientist/scream05.wav") precache_model("models/scientist.mdl") precache_sound("weapons/sbarrel1.wav") } public scigun_attack(id) { emit_sound(id,CHAN_ITEM,"weapons/sbarrel1.wav",VOL_NORM,ATTN_NORM,0,PITCH_NORM) new proj = projectile_create(id) projectile_config(proj,"explodeforward","explode") projectile_config(proj,"model","models/scientist.mdl") projectile_config(proj,"fly","0") projectile_config(proj,"solid","0") projectile_config(proj,"contact","1") projectile_config(proj,"force","1250.0") projectile_config(proj,"size","4") projectile_config(proj,"stopsound","1") switch(random_num(0,4)) { case 0: projectile_config(proj,"launchsound","scientist/scream01.wav") case 1: projectile_config(proj,"launchsound","scientist/scream02.wav") case 2: projectile_config(proj,"launchsound","scientist/scream07.wav") case 3: projectile_config(proj,"launchsound","scientist/scream04.wav") case 4: projectile_config(proj,"launchsound","scientist/scream05.wav") } new szBlah[5] format(szBlah,4,"%d",random_num(90,115)) projectile_config(proj,"pitch",szBlah) projectile_launch(proj) entity_set_byte(proj,EV_BYTE_controller1,0) entity_set_byte(proj,EV_BYTE_controller2,0) entity_set_byte(proj,EV_BYTE_controller3,0) entity_set_byte(proj,EV_BYTE_controller4,0) new Float:angles[3] entity_get_vector(proj,EV_VEC_angles,angles) angles[0]-=90.0 entity_set_vector(proj,EV_VEC_angles,angles) entity_set_int(proj,EV_INT_sequence,4) entity_set_int(proj,EV_INT_gaitsequence,4) entity_set_float(proj,EV_FL_framerate,1.0) entity_set_float(proj,EV_FL_frame,0.0) return PLUGIN_CONTINUE } public plugin_init() { register_clcmd("weapon_scigun","drawSciGun") } public drawSciGun(id) { weapon_draw(id,weapon_scigun) return PLUGIN_HANDLED }
public explode(id,idTouch,Float:origin[3]) { new itsasplode=explosion_create(origin); explosion_config(itsasplode,"intensity","300"); explosion_config(itsasplode,"alwaysbubble","1"); explosion_config(itsasplode,"neversmoke","1"); explosion_config(itsasplode,"explosion","0"); explosion_config(itsasplode,"spartks","0"); explosion_config(itsasplode,"bubbleheight","400"); explosion_config(itsasplode,"bubbleoriginsize","500"); explosion_explode(itsasplode) //radial_damage(id,"flying scientist",500.0,500.0) }
Asszem ez az szükséges hozzá WTF modul is:) Amúgy rengetek mód van rá, elég beírni googleba hogy amxx flamethower és ott megnézed hogy csinálta meg, persze elég macerás, de meglehet oldani!
|