Advertisement
artemx32

SVG_003

Dec 19th, 2015
105
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 20.65 KB | None | 0 0
  1. @name SVG_03
  2. @inputs
  3. @outputs
  4. @persist [C1 C2 PlCol DirV]:vector CLC KY CC SUB SoundID Smax Temper Tmax TAddPerShoot TCheck Mode ToCENT CVAR ToMV Tya Tpi SMDn SMCanFire SModeCH SPRT MDLID HoloCID
  5. @persist [Blt BULLET]:entity PLSpeed [BullArr BullSpeedData BullRData]:array SR:ranger SMPwr SMRand PowAdditive PowMax AmmoCF AmmoCS ShellSPD
  6. @trigger none
  7.  
  8.     O = owner()
  9.  
  10.     KY = O:keyAttack2()
  11.    
  12.     if(first())
  13.     {
  14.  
  15.         E               = entity()      
  16.         C1              = vec(0)
  17.         C2              = vec(0,77,77)
  18.         PlCol           = vec(255,0,255)
  19.         Tmax            = 1000
  20.         PowMax          = 500
  21.         Smax            = 399
  22.         PLSpeed         = 200
  23.         PowAdditive     = 3
  24.         TAddPerShoot    = 3
  25.         CC              = 1
  26.         TCheck          = 1
  27.         Mode            = 1
  28.         SModeCH         = 1
  29.         SPRT            = 1
  30.         ToMV            = 0
  31.         SMCanFire       = 0
  32.         SoundID         = 0
  33.         MDLID           = 5e3
  34.        
  35.         AmmoCF          = 9999
  36.         AmmoCS          = 99
  37.                
  38.         holoCreate(1000), holoPos(1000,O:attachmentPos("anim_attachment_RH") ), holoAlpha(1000,0), holoAng(1000,O:attachmentAng("anim_attachment_RH")), holoParentAttachment(1000, O, "anim_attachment_RH")
  39.         holoCreate(0), holoPos(0,holoEntity(1000):toWorld(vec(14,-3,5)) ), holoAlpha(0,0), holoAng(0,holoEntity(1000):toWorld(ang(-3.5,-15,25))), holoParent(0,1000)
  40.         holoCreate(1, holoEntity(0):toWorld(vec()),vec(0.5,0.5,1.25), holoEntity(0):toWorld(ang(90,0,0))), holoParent(1, 0), holoModel(1,"models/holograms/octagon.mdl"), holoMaterial(1,"phoenix_storms/grey_chrome"), holoColor(1,C1)  
  41.         holoCreate(2, holoEntity(0):toWorld(vec()),vec(0.5,0.5,1.25), holoEntity(0):toWorld(ang(90,0,0))), holoParent(2, 0), holoModel(2,"models/holograms/octagon.mdl"), holoMaterial(2,"phoenix_storms/grey_chrome"), holoColor(2,C2)    
  42.         holoCreate(3, holoEntity(0):toWorld(vec(8.1,0,0)),vec(0.5,0.5,0.1), holoEntity(0):toWorld(ang(90,0,0))), holoParent(3, 0), holoModel(3,"models/holograms/hq_rcylinder_thin.mdl"), holoMaterial(3,"phoenix_storms/grey_chrome"), holoColor(3,C1)    
  43.         holoCreate(4, holoEntity(0):toWorld(vec(8.1,0,0)),vec(0.5,0.5,0.1), holoEntity(0):toWorld(ang(90,0,0))), holoParent(4, 0), holoModel(4,"models/holograms/hq_rcylinder_thin.mdl"), holoMaterial(4,"phoenix_storms/grey_chrome"), holoColor(4,C1)    
  44.         holoCreate(5, holoEntity(0):toWorld(vec(9.2,0,0)),vec(0.2,0.2,0.15), holoEntity(0):toWorld(ang(90,0,0))), holoParent(5, 0), holoModel(5,"models/holograms/hq_tube_thin.mdl"), holoMaterial(5,"phoenix_storms/grey_chrome"), holoColor(5,C2*0.9)
  45.         holoCreate(6, holoEntity(0):toWorld(vec(9.2,0,0)),vec(0.175,0.175,0.14), holoEntity(0):toWorld(ang(90,0,0))), holoParent(6, 0), holoModel(6,"models/holograms/hq_tube_thin.mdl"), holoMaterial(6,"phoenix_storms/grey_chrome"), holoColor(6,C2*0.7)
  46.         holoCreate(7, holoEntity(0):toWorld(vec(9.2,0,0)),vec(0.15,0.15,0.13), holoEntity(0):toWorld(ang(90,0,0))), holoParent(7, 0), holoModel(7,"models/holograms/hq_tube_thin.mdl"), holoMaterial(7,"phoenix_storms/grey_chrome"), holoColor(7,C2*0.5)
  47.         holoCreate(45, holoEntity(0):toWorld(vec(8.3,0,0)),vec(0.4365,0.4365,0.1), holoEntity(0):toWorld(ang(90,0,0))), holoParent(45, 0), holoModel(45,"models/holograms/hq_tube_thin.mdl"), holoMaterial(45,"phoenix_storms/grey_chrome"), holoColor(45,vec(55))
  48.         holoCreate(46, holoEntity(0):toWorld(vec(8.3,0,0)),vec(0.3,0.3,0.1), holoEntity(0):toWorld(ang(90,0,0))), holoParent(46, 0), holoModel(46,"models/holograms/rcylinder_thin.mdl"), holoMaterial(46,"phoenix_storms/grey_chrome"), holoColor(46,vec(77))
  49.         holoCreate(47, holoEntity(0):toWorld(vec(-14.3,0,-1.3)),vec(1), holoEntity(0):toWorld(ang(0,0,0))), holoParent(47, 0), holoModel(47,"models/weapons/w_physics.mdl")
  50.         holoCreate(48, holoEntity(0):toWorld(vec(8.9,0,0)),vec(0.125,0.125,0.05), holoEntity(0):toWorld(ang(90,0,0))), holoParent(48, 0), holoModel(48,"models/holograms/hq_tube.mdl"), holoMaterial(48,"lights/white")
  51.         holoCreate(49, holoEntity(0):toWorld(vec(8.9,0,0)),vec(0.09,0.09,0.05), holoEntity(0):toWorld(ang(90,0,0))), holoParent(49, 0), holoModel(49,"models/holograms/hq_rcylinder_thin.mdl"), holoMaterial(49,"lights/white")
  52.         holoCreate(50, holoEntity(0):toWorld(vec(8.9,0,0)),vec(0.09,0.09,0.05), holoEntity(0):toWorld(ang(90,0,0))), holoParent(50, 0), holoModel(50,"models/holograms/hq_rcylinder_thin.mdl"), holoMaterial(50,"lights/white")    
  53.         holoCreate(51, holoEntity(0):toWorld(vec(-1,-2.5,1)),vec(0.1), holoEntity(0):toWorld(ang(0,180,25))), holoModel(51,"models/sprops/misc/alphanum/alphanum_0.mdl"), holoParent(51,0), holoBodygroup(51,0,3), holoMaterial(51,"lights/white"),holoColor(51,C1)
  54.         holoCreate(52, holoEntity(0):toWorld(vec(0,-2.5,1)),vec(0.1), holoEntity(0):toWorld(ang(0,180,25))), holoModel(52,"models/sprops/misc/alphanum/alphanum_0.mdl"), holoParent(52,0), holoBodygroup(52,0,3), holoMaterial(52,"lights/white"),holoColor(52,C1)
  55.         holoCreate(53, holoEntity(0):toWorld(vec(1,-2.5,1)),vec(0.1), holoEntity(0):toWorld(ang(0,180,25))), holoModel(53,"models/sprops/misc/alphanum/alphanum_0.mdl"), holoParent(53,0), holoBodygroup(53,0,3), holoMaterial(53,"lights/white"),holoColor(53,C1)
  56.         holoCreate(54, holoEntity(0):toWorld(vec(2,-2.5,1)),vec(0.1), holoEntity(0):toWorld(ang(0,180,25))), holoModel(54,"models/sprops/misc/alphanum/alphanum_0.mdl"), holoParent(54,0), holoBodygroup(54,0,3), holoMaterial(54,"lights/white"),holoColor(54,C1)
  57.         holoCreate(55, holoEntity(0):toWorld(vec(3,-2.5,1)),vec(0.1), holoEntity(0):toWorld(ang(0,180,25))), holoModel(55,"models/sprops/misc/alphanum/alphanum_div.mdl"), holoParent(55,0), holoBodygroup(55,0,3), holoMaterial(55,"lights/white"),holoColor(55,C1)
  58.         holoCreate(56, holoEntity(0):toWorld(vec(4,-2.5,1)),vec(0.1), holoEntity(0):toWorld(ang(0,180,25))), holoModel(56,"models/sprops/misc/alphanum/alphanum_0.mdl"), holoParent(56,0), holoBodygroup(56,0,3), holoMaterial(56,"lights/white"),holoColor(56,C1)
  59.         holoCreate(57, holoEntity(0):toWorld(vec(5,-2.5,1)),vec(0.1), holoEntity(0):toWorld(ang(0,180,25))), holoModel(57,"models/sprops/misc/alphanum/alphanum_0.mdl"), holoParent(57,0), holoBodygroup(57,0,3), holoMaterial(57,"lights/white"),holoColor(57,C1)
  60.         holoCreate(58, holoEntity(0):toWorld(vec()),vec(0.5,0.5,1.25), holoEntity(0):toWorld(ang(90,0,0))), holoParent(58, 0), holoModel(58,"models/holograms/octagon.mdl"), holoMaterial(58,"phoenix_storms/grey_chrome"), holoColor(58,C1)    
  61.         holoCreate(59, holoEntity(0):toWorld(vec()),vec(0.5,0.5,1.25), holoEntity(0):toWorld(ang(90,0,0))), holoParent(59, 0), holoModel(59,"models/holograms/octagon.mdl"), holoMaterial(59,"phoenix_storms/grey_chrome"), holoColor(59,C2)
  62.         holoCreate(60, holoEntity(0):toWorld(vec(6.5,0,0)),vec(0.5,0.5,0.075), holoEntity(0):toWorld(ang(90,0,0))), holoParent(60, 0), holoModel(60,"models/holograms/octagon.mdl"), holoMaterial(60,"lights/white"), holoColor(60,PlCol)
  63.         holoCreate(61, holoEntity(0):toWorld(vec(0,2.5,1)),vec(0.1), holoEntity(0):toWorld(ang(0,0,25))), holoModel(61,"models/sprops/misc/alphanum/alphanum_3.mdl"), holoParent(61,0), holoBodygroup(61,0,3), holoMaterial(61,"lights/white"),holoColor(61,C2)
  64.         holoCreate(62, holoEntity(0):toWorld(vec(1,2.5,1)),vec(0.1), holoEntity(0):toWorld(ang(0,0,25))), holoModel(62,"models/sprops/misc/alphanum/alphanum_0.mdl"), holoParent(62,0), holoBodygroup(62,0,3), holoMaterial(62,"lights/white"),holoColor(62,C2)
  65.         holoCreate(63, holoEntity(0):toWorld(vec(2,2.5,1)),vec(0.1), holoEntity(0):toWorld(ang(0,0,25))), holoModel(63,"models/sprops/misc/alphanum/alphanum_min.mdl"), holoParent(63,0), holoBodygroup(63,0,3), holoMaterial(63,"lights/white"),holoColor(63,C2)
  66.         holoCreate(64, holoEntity(0):toWorld(vec(3,2.5,1)),vec(0.1), holoEntity(0):toWorld(ang(0,0,25))), holoModel(64,"models/sprops/misc/alphanum/alphanum_g.mdl"), holoParent(64,0), holoBodygroup(64,0,3), holoMaterial(64,"lights/white"),holoColor(64,C2)
  67.         holoCreate(65, holoEntity(0):toWorld(vec(4,2.5,1)),vec(0.1), holoEntity(0):toWorld(ang(0,0,25))), holoModel(65,"models/sprops/misc/alphanum/alphanum_v.mdl"), holoParent(65,0), holoBodygroup(65,0,3), holoMaterial(65,"lights/white"),holoColor(65,C2)
  68.         holoCreate(66, holoEntity(0):toWorld(vec(5,2.5,1)),vec(0.1), holoEntity(0):toWorld(ang(0,0,25))), holoModel(66,"models/sprops/misc/alphanum/alphanum_s.mdl"), holoParent(66,0), holoBodygroup(66,0,3), holoMaterial(66,"lights/white"),holoColor(66,C2)
  69.    
  70.         for(L = 8,44)
  71.         {
  72.          
  73.             holoCreate(L, holoEntity(0):toWorld(vec(8.8,sin(L*10)*2.5,cos(L*10)*2.5)), vec(0.03,0.03,0.5), holoEntity(0):toWorld(ang(90,0,0))), holoModel(L,"models/holograms/hq_torus.mdl"), holoColor(L,hsv2rgb(L*10,1,0.8)), holoMaterial(L,"phoenix_storms/grey_chrome"),holoParent(L,0)
  74.            
  75.         }
  76.  
  77.         holoEntity(0):soundPlay(200,0,"acf_extra/vehiclefx/boost/tcl_turbo.wav")
  78.         holoEntity(0):soundPlay(240,0,"ambient/machines/spin_loop.wav"),soundVolume(240,0.4)
  79.         holoEntity(0):soundPlay(244,0,"acf_extra/airfx/redsstukaangriff.wav"), soundVolume(244,0)
  80.  
  81.         function number wtype()
  82.         {
  83.          
  84.             return O:weapon():type() == "weapon_physgun"
  85.            
  86.         }
  87.  
  88.         function clip(Z:number)
  89.         {
  90.          
  91.             holoClip(1,1,vec(),vec(0,1,0),0)
  92.             holoClipEnabled(1,1,Z)
  93.             holoClip(1,2,vec(0,0,6),vec(0,0,-1),0)
  94.             holoClipEnabled(1,2,Z)
  95.             holoClip(2,1,vec(),vec(0,-1,0),0)
  96.             holoClipEnabled(2,1,Z)
  97.             holoClip(2,2,vec(0,0,6),vec(0,0,-1),0)
  98.             holoClipEnabled(2,2,Z)
  99.             holoClip(3,vec(),vec(0,-1,0),0)
  100.             holoClipEnabled(3,Z)
  101.             holoClip(4,vec(),vec(0,1,0),0)
  102.             holoClipEnabled(4,Z)
  103.             holoClip(47,vec(12,0,0),vec(-1,0,0),0)
  104.             holoClipEnabled(47,Z)
  105.             holoClip(49,vec(0,0,0),vec(0,1,0), 0)
  106.             holoClipEnabled(49,Z)
  107.             holoClip(50,vec(0,0,0),vec(0,-1,0),0)
  108.             holoClipEnabled(50,Z)
  109.             holoClip(58,1,vec(),vec(0,1,0), 0)
  110.             holoClipEnabled(58,1,Z)
  111.             holoClip(58,2,vec(0,0,7),vec(0,0,1),0)
  112.             holoClipEnabled(58,2,Z)
  113.             holoClip(59,1,vec(),vec(0,-1,0), 0)
  114.             holoClipEnabled(59,1,Z)
  115.             holoClip(59,2,vec(0,0,7),vec(0,0,1),0)
  116.             holoClipEnabled(59,2,Z)
  117.  
  118.         }
  119.    
  120.         function cold()
  121.         {
  122.          
  123.             if(wtype() & Mode & Temper> Tmax/4)
  124.             {
  125.              
  126.                 Tpi = O:eyeAngles()[1]
  127.                 Tya = O:eyeAngles()[2]
  128.                
  129.                 if(changed(Tpi) | changed(Tya))
  130.                 {
  131.                  
  132.                     Temper -= abs($Tpi+$Tya)/10
  133.                    
  134.                 }
  135.                        
  136.             }
  137.            
  138.         }
  139.        
  140.         function entity:shootmode01()
  141.         {
  142.            
  143.             if(AmmoCF>0){
  144.            
  145.             for(N = 1, 3 + (Temper/Tmax)*10){
  146.              
  147.                 holoEntity(8+CLC):shootTo( This:pos(),(O:aimPos() - holoEntity(0):pos()):normalized()*2000,0.001+ N + Temper/2, 900,2+Temper/100 + 250*Temper>(Tmax*0.75),"AR2Tracer")
  148.                
  149.             }
  150.  
  151.             holoEntity(1):effectSpawn("ShellEject", holoEntity(1):pos(),holoEntity(1):forward(),holoEntity(1):angles(),1)
  152.             This:effectSpawn("ChopperMuzzleFlash", This:pos() + This:up(),1)
  153.             This:effectSpawn("MuzzleEffect", This:toWorld(vec(3,-5,0)),vec(),This:toWorld(ang(-90,0,0)),0.4)
  154.             This:soundPlay(int(Temper/Tmax)*15,2,"weapons/shotgun/shotgun_dbl_fire.wav"), soundPitch(int(Temper/Tmax)*15,211)
  155.             AmmoCF--
  156.            
  157.             }else{
  158.            
  159.                  O:soundPlay(228,1,"weapons/shotgun/shotgun_empty.wav")          
  160.            
  161.             }
  162.  
  163.         }
  164.    
  165.         function shootmode02()
  166.         {
  167.          
  168.             if(AmmoCS>0)
  169.             {
  170.  
  171.             HoloCID++
  172.  
  173.             Blt = holoCreate(10000+HoloCID, holoEntity(0):pos()), holoScale(10000+HoloCID, vec(0.5)), holoModel(10000+HoloCID, "models/effects/combineball.mdl") #drawSprite("models/effects/comball_glow1", holoEntity(0):pos(), PlCol, 200, 15,15)
  174.             BullArr:pushEntity(Blt)
  175.             Blt:setAng((O:aimPos() - holoEntity(0):pos()):toAngle() )
  176.             Blt:setdLight(PlCol,4,400)
  177.             Blt:setTrails(10,5, 0.2, "trails/smoke", vec(255,169,120),200)
  178.             Blt:setSubMaterial(0,"models/spawn_effect")
  179.             Blt:setSubMaterial(3,"models/alyx/emptool_glow")
  180.             Blt:setSubMaterial(1,"models/props_c17/fisheyelens")
  181.             Blt:setAlpha(150)
  182.            
  183.             holoEntity(0):soundPlay(260,3,"weapons/airboat/airboat_gun_energy2.wav")
  184.             holoEntity(0):soundPlay(261,3,"weapons/gauss/fire1.wav"), soundPitch(261,150)
  185.            
  186.             AmmoCS--
  187.             SoundID++
  188.            
  189.                 O:soundPlay(228,2,"NPC_CombineBall.Launch")
  190.            
  191.             }else{
  192.            
  193.                 O:soundPlay(228,1,"weapons/ar2/ar2_empty.wav")
  194.            
  195.             }
  196.        
  197.         }
  198.        
  199.         function shootPWRmode02()
  200.         {
  201.          
  202.             if(!Mode&SMCanFire&wtype() & O:keyAttack2()&SModeCH&AmmoCS>0)
  203.             {
  204.              
  205.                 SMPwr = clamp( SMPwr + PowAdditive, 0, PowMax )
  206.                 soundVolume(244,0.58)
  207.                
  208.             }
  209.        
  210.         }
  211.    
  212.         function holo_clr()
  213.         {
  214.          
  215.             holoColor(3,vec(255 ,C1[2] - (Temper/255)*55,C1[3] - (Temper/255)*55))
  216.             holoColor(4,vec(255 ,C1[2] - (Temper/255)*55,C1[3] - (Temper/255)*55))
  217.             holoColor(48,vec((Temper/255)*55 ,255 - (Temper/255)*55 ,0 )-CVAR*220)
  218.             holoColor(49,vec( (SMCanFire*255) , abs( CVAR*220 - SMPwr/2.25 ) , abs( CVAR*220 - SMPwr/2.25) ) )
  219.             holoColor(50,vec(0, (abs(sin(curtime()*100 + SMPwr*5 )*255 ))*CVAR, (abs(sin(curtime()*100 + SMPwr*5 )*255 ))*CVAR ))
  220.             holoColor(60,vec(Temper/4 + 255*!Mode + SMPwr/2,255-SMPwr/2 - Temper/4,255 - SMPwr/2 - Mode*255 ))
  221.        
  222.         }
  223.    
  224.         function hit_effect()
  225.         {
  226.        
  227.             BULLET:setAlpha(0)
  228.             BULLET:dLightRemove()
  229.             BULLET:remove(6)
  230.             BULLET:explosion(50000,245)
  231.             BULLET:soundPlay(246,3,"NPC_CombineBall.Explosion")      
  232.             BULLET:setTrails(25,100,1,"sprites/tp_beam001",PlCol,200)
  233.             soundStop(2000)
  234.            
  235.         }
  236.        
  237.         function ammo1_visualize()
  238.         {
  239.            
  240.             local Exp = AmmoCF:toString():explode("")
  241.  
  242.             holoModel(51,"models/sprops/misc/alphanum/alphanum_" + Exp[1, string] + ".mdl")
  243.             holoModel(52,"models/sprops/misc/alphanum/alphanum_" + Exp[2, string] + ".mdl")
  244.             holoModel(53,"models/sprops/misc/alphanum/alphanum_" + Exp[3, string] + ".mdl")
  245.             holoModel(54,"models/sprops/misc/alphanum/alphanum_" + Exp[4, string] + ".mdl")
  246.          
  247.         }
  248.        
  249.         function ammo2_visualize()
  250.         {
  251.            
  252.             local Exp = AmmoCS:toString():explode("")
  253.  
  254.             holoModel(56,"models/sprops/misc/alphanum/alphanum_" + Exp[1, string] + ".mdl")
  255.             holoModel(57,"models/sprops/misc/alphanum/alphanum_" + Exp[2, string] + ".mdl")
  256.          
  257.         }
  258.    
  259.         E:setMass(200)
  260.         clip(1)
  261.  
  262.     }
  263.  
  264. interval(25)
  265.  
  266.     SUB    = clamp(SUB,0,Smax)
  267.     Temper = clamp(Temper,0,Tmax)
  268.    
  269.     if(changed(O:keyPressed("MOUSE_4"))&O:keyPressed("MOUSE_4")){Mode = !Mode}
  270.     if(changed(O:keyPressed("MOUSE_5"))&O:keyPressed("MOUSE_5")&!Mode){SMCanFire = !SMCanFire}
  271.     if(changed(Mode)&!Mode){ToCENT = 1,ToMV = 1}
  272.     if(changed(Mode)&Mode){ToCENT = 0,ToMV = 1,SMCanFire = 0}
  273.     if(changed(SMCanFire)){ if(SMCanFire){holoEntity(0):soundPlay(241,3,"buttons/button9.wav")}else{holoEntity(0):soundPlay(241,3,"buttons/button6.wav")} }  
  274.     if(changed(O:keyAttack2())&!O:keyAttack2()&!Mode&SMCanFire&wtype()&SModeCH)
  275.     {
  276.  
  277.         BullSpeedData:pushNumber(SMPwr)
  278.  
  279.         SModeCH   = 0
  280.         SMRand    = SMPwr
  281.         SMPwr     = 0
  282.    
  283.         shootmode02()
  284.         soundVolume(244,0)
  285.         timer("KD",2250)
  286.  
  287.     }
  288.        
  289.     if(!Mode&SMCanFire&SModeCH)
  290.     {
  291.      
  292.         soundPitch(244, SMPwr/2)
  293.        
  294.     }
  295.    
  296.     CVAR = CVAR + clamp( angnorm( ToCENT - CVAR ), -0.05,0.05 )/2
  297.     SMDn = SMDn + clamp( angnorm( Mode - SMDn ), -0.0,0.04 )/2
  298.  
  299.     if(changed(CVAR)){soundPitch(240,abs($CVAR*1500))}
  300.     if(changed(AmmoCF)){ammo1_visualize(), if(AmmoCF == 0){ KY      = 0 }}
  301.     if(changed(AmmoCS)){ammo2_visualize(), if(AmmoCS == 0){ SModeCH = 0 }}
  302.     if(changed(CVAR)&(CVAR != 0 | CVAR != 1))
  303.     {
  304.    
  305.         for(L = 8,44)
  306.         {
  307.             holoPos(L,holoEntity(0):toWorld(vec(8.8,sin(L*10+CVAR*55)*(2.5-CVAR),cos(L*10+CVAR*55)*(2.5-CVAR))))
  308.         }  
  309.            
  310.     }  
  311.  
  312.     if(BullArr:count()>0)
  313.     {
  314.      
  315.         for(Z = 0, BullArr:count())
  316.         {
  317.          
  318.             ShellSPD       = BullSpeedData[Z, number]
  319.             BULLET         = BullArr[Z, entity]
  320.             SR             = rangerOffset(ShellSPD, BULLET:pos(), BULLET:forward()+randvec(-SMRand/7000,SMRand/7000))
  321.  
  322.             holoAnim(holoIndex(BULLET),"idle", ( (curtime()/1000) % 1) )
  323.  
  324.             if(clk("SPRT")){ SPRT = 1 }
  325.  
  326.             BULLET:setPos(SR:pos())
  327.        
  328.             if(SR:hit())
  329.             {
  330.                
  331.                 local HitAng = acos(SR:hitNormal():dot(-BULLET:forward()))            
  332.                 # >30 & < 70
  333.                 if(HitAng > 30 & HitAng < 90 & !SR:entity():isPlayer() & BullRData[Z, number] <3 & BullRData[Z, number] != 3){
  334.                    
  335.                     local BV = BULLET:forward() - 2 * (SR:hitNormal():dot(BULLET:forward()) * SR:hitNormal())
  336.                    
  337.                     BULLET:setAng(BV:toAngle())
  338.                     BULLET:soundPlay(int(curtime()), 1.5, "HEGrenade.Bounce")
  339.                     BULLET:effectSpawn("cball_bounce", BULLET:pos(), SR:hitNormal())
  340.                    
  341.                     BULLET:soundPlay(2,2,"NPC_CombineBall.WhizFlyby")
  342.                    
  343.                     BullRData[Z, number] = BullRData[Z, number] + 1
  344.                    
  345.                 }
  346.                
  347.                 if(HitAng < 30 | HitAng > 90 | BullRData[Z, number] >= 3){
  348.  
  349.                 BullRData[Z, number] = 0
  350.  
  351.                 BULLET:effectSpawn("AR2Impact", BULLET:pos(), SR:hitNormal())
  352.                 BULLET:effectSpawn("GunshipImpact", BULLET:pos(), SR:hitNormal())
  353.  
  354.                 BULLET:setPos( SR:pos() )
  355.                 BullArr:remove(Z)
  356.                 BullSpeedData:remove(Z)
  357.                
  358.                 hit_effect()
  359.  
  360.                 }
  361.  
  362.             }
  363.        
  364.         }
  365.        
  366.     }
  367.  
  368.     if(wtype() & KY & CC & TCheck & Mode )
  369.     {
  370.         CLC++,
  371.         CC      = 0,
  372.         Temper += TAddPerShoot,
  373.         timer("CLO", 400-SUB)
  374.     }
  375.    
  376.     if(wtype() & KY & TCheck & Mode)
  377.     {
  378.      
  379.         SUB    += (Smax - SUB)/250
  380.        
  381.     }
  382.    
  383.     if(clk("CLO"))
  384.     {
  385.         CC = 1
  386.     }
  387.     if(CLC>=36)
  388.     {
  389.         CLC = 1
  390.     }
  391.     if((!KY|!TCheck|!Mode))
  392.     {
  393.         SUB    -=(SUB/100)
  394.         Temper -= (TAddPerShoot/2)*Temper>0
  395.     }
  396.  
  397.     if(changed(CLC)&KY&Mode)
  398.     {
  399.          
  400.         local Or = holoEntity(8+CLC)
  401.         Or:shootmode01()
  402.        
  403.     }
  404.  
  405.     soundPitch(200, SUB*0.6)
  406.  
  407.     if(changed(O:weapon( ):type( ))&wtype())
  408.     {
  409.      
  410.         for(X = 1, 66){holoAlpha(X,255)}
  411.         O:weapon():setAlpha(0)
  412.    
  413.     }elseif(changed(O:weapon():type())&!wtype())
  414.     {
  415.        
  416.         for(X = 1, 66){holoAlpha(X,0)}
  417.         O:weapon():setAlpha(255)
  418.        
  419.     }
  420.  
  421.     if(changed(Temper)&Temper>(Tmax-Tmax/20)&CC&TCheck)
  422.     {
  423.         CC = 0,TCheck = 0
  424.         timer("TEMPERATURE",10000)
  425.         holoEntity(0):soundPlay(250,4,"NPC_CeilingTurret.Die")
  426.        
  427.     }
  428.    
  429.     if(clk()&perf())
  430.     {
  431.      
  432.         cold()
  433.         shootPWRmode02()
  434.         holo_clr()
  435.        
  436.     }
  437.    
  438.     if(clk("TEMPERATURE")){CC = 1,TCheck = 1, holoEntity(0):soundPlay(250,4,"NPC_FloorTurret.Deploy")}
  439.     if(clk("KD")){SModeCH = 1}
  440.  
  441.     O:sendLua("
  442.    
  443.    surface.CreateFont('CFNTSS', {
  444.        
  445.      font='impact';  
  446.      size=12;
  447.      bold=true
  448.        
  449.    })
  450.    
  451.    hook.Add('HUDPaint','2323SSS', function()
  452.    
  453.        surface.CreateFont('LocalFont111', {
  454.        
  455.        font='Impact';
  456.        size=20;
  457.        weight=2000;    
  458.            
  459.        })
  460.    
  461.        draw.SimpleText('"+AmmoCF+" ; "+AmmoCS+" ' , 'LocalFont111', ScrW()/3, ScrH()/2, Color(255,0,0))
  462.  
  463.    end )
  464.    
  465.    ")
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement