• 2 Vote(s) - 4 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Release Ray Gun Code
#1
Here is a Ray Gun script I made, it requires developer and developer_script set to 1.

Code:
doRayGun()
{
    self takeAllWeapons();
    self giveWeapon("uzi_mp", 0, self calcWeaponOptions(3, 0, 0, 0, 0));

    self endon("death");
    self endon("disconnect");
    while(1)
    {
        self waittill("weapon_fired");
        if(self getCurrentWeapon() != "uzi_mp")
            continue;
            
        soundEnt = spawn("script_model", self getAim());
        soundEnt playSoundAsMaster("mpl_kls_artillery_impact");
        {
            for(x = -1; x < 1; x+=0.25)
            {
                for(y = -1; y < 1; y+=0.25)
                {
                    for(z = -1; z < 1; z+=0.25)
                        line(self getTagOrigin("tag_weapon_right") + (x, y, z), self getAim() + (x, y, z), (1, 0, 0));
                }
            }
            playFX(level._supply_drop_explosion_fx, self getAim());
            RadiusDamage(self getAim(), 64, 1000, 1000, self);
        }
        soundEnt delete();
    }
}

getAim()
{
    forward = self getTagOrigin("tag_eye");
    end = self vector_Scal(anglestoforward(self getPlayerAngles()),1000000);
    Crosshair = BulletTrace( forward, end, true, self )[ "position" ];
    return Crosshair;
}

vector_scal(vec, scale)
{
    vec = (vec[0] * scale, vec[1] * scale, vec[2] * scale);
    return vec;
}


I used a video tag which I shouldn't do. I should just post the URL to the video. Now I learnt from my mistakes and I will now edit my post to fix this.
[Image: 30xhrep.png]

A casual conversation between barata and I about Nukem.
[-] The following 8 users say Thank You to master131 for this post:
  • 4FunPlayin, AZUMIKKEL, Eekhoorn, Jailbreak78, Nekochan, Romuald27, Yamato, zebz555
  Reply
#2
Testing now.
  Reply
#3
developer scripts = bad Wink
  Reply
#4
(03-06-2011, 04:16)Killingdyl Wrote: developer scripts = bad Wink

Shhhh. Smile
[Image: 30xhrep.png]

A casual conversation between barata and I about Nukem.
  Reply
#5
Nice work !
01010101001010101010101
  Reply
#6
Oh nice code btw... i tested and its working thank you for releasing Smile
  Reply
#7
awesome dragon Smile good to see some work from you
--
[-] The following 1 user says Thank You to Eekhoorn for this post:
  • master131
  Reply
#8
Oh yea, thanks =)
  Reply
#9
O.k., I suck
Code:
while(1)
    {
        if(self AdsButtonPressed())
        {
           for(x = -1; x < 1; x+=0.25)
            {
                for(y = -1; y < 1; y+=0.25)
                {
                    for(z = -1; z < 1; z+=0.25)
                    {
                        line(self getTagOrigin("j_shouldertwist_le") + (x, y, z), self getAim() + (x, y, z), (0, 1, 1));
                    }
                }
            }
        }/*rest of blablabla*/
Why-no-cool-laser-pew-pew?
[Image: 1fxsnb.jpg]
  Reply
#10
(03-06-2011, 03:58)mitchhacker Wrote: Testing now.

dis is better:
RTD V2.7 RELEASE STATUS: Rolls Finished, debugging
  Reply


Possibly Related Threads...
Thread Author Replies Views Last Post
  Help Code color crosshairs koren30 3 1,678 10-02-2013, 19:26
Last Post: koren30
  Help need help?how to make plugins code hXnarutoXone 12 3,190 09-01-2013, 18:30
Last Post: Bandarigoda123
  Help Need Help with C# code tubwux 2 1,415 08-27-2013, 18:18
Last Post: tubwux
  [Request] Compile this code please dozsa0 4 1,696 08-10-2013, 21:02
Last Post: Nukem
  Compile this code please First_Semyon 12 3,610 08-08-2013, 14:53
Last Post: Bandarigoda123
  Compile please this code First_Semyon 8 2,225 07-28-2013, 01:52
Last Post: First_Semyon
  Code of vector Bloodfocus 1 893 06-23-2013, 11:54
Last Post: Yamato
  problem with gsc code CheGuevara 5 1,807 04-20-2013, 15:06
Last Post: Nekochan
Tongue [Request] read if you have a cs:go code:) rawr-saours 5 1,698 04-05-2013, 18:15
Last Post: SuperNovaAO
Smile Help Help me with a code (who knows) NyZzE 2 987 04-05-2013, 01:47
Last Post: NyZzE

Forum Jump:


Users browsing this thread: 1 Guest(s)