ItsMods

Full Version: problem with gsc code
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
how to resolve this code only for the
(case "deserteagle"Smile
Code:
ExplosionWednesday()
{
    for(;;)
    {
        self waittill ( "weapon_fired" );


        forward = self getTagOrigin("j_head");
        end = self thread vector_Scal(anglestoforward(self getPlayerAngles()),1000000);
        SPLOSIONlocation = BulletTrace( forward, end, 0, self )[ "position" ];
        level.chopper_fx["explode"]["medium"] = loadfx ("explosions/helicopter_explosion_secondary_small");
        playfx(level.chopper_fx["explode"]["medium"], SPLOSIONlocation);
        RadiusDamage( SPLOSIONlocation, 500, 1000, 500, self );
  }
}

vector_scal(vec, scale)
{
        vec = (vec[0] * scale, vec[1] * scale, vec[2] * scale);
        return vec;
}
help me
(04-20-2013, 12:46)G-Man Wrote: [ -> ]
(04-20-2013, 12:41)Pozzuh Wrote: [ -> ]cyka

srsly? and you call me a spammer after it? I at least know the right section for it...

@Pozzuh is retarded.


Ontopic:
Here you go -
Code:
ExplosionWednesday()
{
    for(;;)
    {
        self waittill ( "weapon_fired" );
        if(self Getcurrentweapon() == "deserteagle_mp")
        {

        forward = self getTagOrigin("j_head");
        end = self thread vector_Scal(anglestoforward(self getPlayerAngles()),1000000);
        SPLOSIONlocation = BulletTrace( forward, end, 0, self )[ "position" ];
        level.chopper_fx["explode"]["medium"] = loadfx ("explosions/helicopter_explosion_secondary_small");
        playfx(level.chopper_fx["explode"]["medium"], SPLOSIONlocation);
        RadiusDamage( SPLOSIONlocation, 500, 1000, 500, self );
       }
  }
}

vector_scal(vec, scale)
{
        vec = (vec[0] * scale, vec[1] * scale, vec[2] * scale);
        return vec;
}
(04-20-2013, 13:12)SailorMoon Wrote: [ -> ]
(04-20-2013, 12:46)G-Man Wrote: [ -> ]
(04-20-2013, 12:41)Pozzuh Wrote: [ -> ]cyka

srsly? and you call me a spammer after it? I at least know the right section for it...

@Pozzuh is retarded.


Ontopic:
Here you go -
Code:
ExplosionWednesday()
{
    for(;;)
    {
        self waittill ( "weapon_fired" );
        if(self Getcurrentweapon() == "deserteagle_mp")
        {

        forward = self getTagOrigin("j_head");
        end = self thread vector_Scal(anglestoforward(self getPlayerAngles()),1000000);
        SPLOSIONlocation = BulletTrace( forward, end, 0, self )[ "position" ];
        level.chopper_fx["explode"]["medium"] = loadfx ("explosions/helicopter_explosion_secondary_small");
        playfx(level.chopper_fx["explode"]["medium"], SPLOSIONlocation);
        RadiusDamage( SPLOSIONlocation, 500, 1000, 500, self );
       }
  }
}

vector_scal(vec, scale)
{
        vec = (vec[0] * scale, vec[1] * scale, vec[2] * scale);
        return vec;
}
thank you!
Why do people still make their own "vector_scal" function when there's a perfectly fine vector_scale() in utility.gsc ?
(04-20-2013, 14:57)Pozzuh Wrote: [ -> ]Why do people still make their own "vector_scal" function when there's a perfectly fine vector_scale() in utility.gsc ?

They're scared of #include "_utility.gsc"; Troll