[Request]Anti Plant Bomb

InfinityScript plugins for dedicated servers.
User avatar
TheWizard11
TeknoRat
TeknoRat
Posts: 22
Joined: Fri Aug 15, 2014 1:11 pm

[Request]Anti Plant Bomb

Postby TheWizard11 » Thu Feb 11, 2016 9:52 am

hi to all.

i need Anti Plant Bomb Plugin for SnD isnipe...

pls help me!
;o
User avatar
~Seraphim
TeknoHorse
TeknoHorse
Posts: 1186
Joined: Sun Jan 12, 2014 10:36 pm

Re: [Request]Anti Plant Bomb

Postby ~Seraphim » Thu Feb 11, 2016 11:25 am

Code: Select all

p.OnNotify("weapon_changed", e => {
   if( e.GetWeapon().Equals( "iw5_" ) ){
      e.GiveWeapon( e.GetWeaponPrimary() );
      e.iprintlnbold( "You are not allowed to plant the bomb." );
   }
});


Although I can't remember the exact names for "weapon_changed" or the briefcase's name.
User avatar
~Lambder
TeknoSheep
Posts: 448
Joined: Thu Apr 11, 2013 5:40 pm
Location: Meadow.
Contact:

Re: [Request]Anti Plant Bomb

Postby ~Lambder » Thu Feb 11, 2016 3:05 pm

c4271605 wrote:

Code: Select all

p.OnNotify("weapon_changed", e => {
   if( e.GetWeapon().Equals( "iw5_" ) ){
      e.GiveWeapon( e.GetWeaponPrimary() );
      e.iprintlnbold( "You are not allowed to plant the bomb." );
   }
});


Although I can't remember the exact names for "weapon_changed" or the briefcase's name.


Or you can just as well take the bomb from him and it will automatically switch to his primary. (You aren't actually taking his bomb, the player will still be able to use it)

And for the bomb, it was something along the lines of briefcase_bomb_mp.
So we end up with something like this.

Code: Select all

p.OnNotify("weapon_change", (ent, weapon) =>
    {
        if(weapon.As<string>() == "briefcase_bomb_mp")
        {
            ent.TakeWeapon("briefcase_bomb_mp");
            ent.IPrintLnBold("You fucker, don't plant.");
        }
    }
BlackLabel
TeknoDog
TeknoDog
Posts: 37
Joined: Thu Jul 24, 2014 7:29 pm

Re: [Request]Anti Plant Bomb

Postby BlackLabel » Thu Feb 11, 2016 3:42 pm

TheWizard11 wrote:hi to all.

i need Anti Plant Bomb Plugin for SnD isnipe...

pls help me!
;o


if you don't know how to make a .dll file
here it comes ( Lambder's code)
http://www.mediafire.com/download/im4h1 ... 2.auto.rar
Last edited by BlackLabel on Mon Feb 15, 2016 8:58 pm, edited 1 time in total.
Image
rovo93
TeknoCow
TeknoCow
Posts: 65
Joined: Wed Jun 24, 2015 5:29 pm

Re: [Request]Anti Plant Bomb

Postby rovo93 » Thu Feb 11, 2016 4:09 pm

Lambder wrote:
c4271605 wrote:

Code: Select all

p.OnNotify("weapon_changed", e => {
   if( e.GetWeapon().Equals( "iw5_" ) ){
      e.GiveWeapon( e.GetWeaponPrimary() );
      e.iprintlnbold( "You are not allowed to plant the bomb." );
   }
});


Although I can't remember the exact names for "weapon_changed" or the briefcase's name.


Or you can just as well take the bomb from him and it will automatically switch to his primary. (You aren't actually taking his bomb, the player will still be able to use it)

And for the bomb, it was something along the lines of briefcase_bomb_mp.
So we end up with something like this.

Code: Select all

p.OnNotify("weapon_change", (ent, weapon) =>
    {
        if(weapon.As<string>() == "briefcase_bomb_mp")
        {
            ent.TakeWeapon("briefcase_bomb_mp");
            ent.IPrintLnBold("You fucker, don't plant.");
        }
    }



Hi man,
you know if there is a way to drop the bomb ?? I tried "Dropitem" function and it works with weapons.. but not with bomb !!!!
Or maybe i just wrong bomb name?? I tried lot of bomb name but nothing..

Thank youu :blush:
Image
User avatar
~Lambder
TeknoSheep
Posts: 448
Joined: Thu Apr 11, 2013 5:40 pm
Location: Meadow.
Contact:

Re: [Request]Anti Plant Bomb

Postby ~Lambder » Thu Feb 11, 2016 4:50 pm

rovo93 wrote:
Lambder wrote:
c4271605 wrote:

Code: Select all

p.OnNotify("weapon_changed", e => {
   if( e.GetWeapon().Equals( "iw5_" ) ){
      e.GiveWeapon( e.GetWeaponPrimary() );
      e.iprintlnbold( "You are not allowed to plant the bomb." );
   }
});


Although I can't remember the exact names for "weapon_changed" or the briefcase's name.


Or you can just as well take the bomb from him and it will automatically switch to his primary. (You aren't actually taking his bomb, the player will still be able to use it)

And for the bomb, it was something along the lines of briefcase_bomb_mp.
So we end up with something like this.

Code: Select all

p.OnNotify("weapon_change", (ent, weapon) =>
    {
        if(weapon.As<string>() == "briefcase_bomb_mp")
        {
            ent.TakeWeapon("briefcase_bomb_mp");
            ent.IPrintLnBold("You fucker, don't plant.");
        }
    }



Hi man,
you know if there is a way to drop the bomb ?? I tried "Dropitem" function and it works with weapons.. but not with bomb !!!!
Or maybe i just wrong bomb name?? I tried lot of bomb name but nothing..

Thank youu :blush:


Afaik it doesn't work in mw3.



XENZ
TeknoDog
TeknoDog
Posts: 46
Joined: Sat Jun 13, 2015 10:01 pm

Re: [Request]Anti Plant Bomb

Postby XENZ » Sat Feb 13, 2016 1:01 pm

rovo93 wrote:

Hi man,
you know if there is a way to drop the bomb ?? I tried "Dropitem" function and it works with weapons.. but not with bomb !!!!
Or maybe i just wrong bomb name?? I tried lot of bomb name but nothing..

Thank youu :blush:


to make this you need to make some changes in .gsc's (client and server) (gameobjects.gsc, sd.gsc, ... and bind a key client side to drop it)
bomb is a special weapon, its like all players have the bomb every time but only can use it if "isbombcarrier" is true. this field is true when you are in the bomb model origin area, you "take" the bomb and model dissapear.

I suppose you want this for the promod script. if you want to know what things you could make, download cod4/mw2 promod and decompile it.
Image
rovo93
TeknoCow
TeknoCow
Posts: 65
Joined: Wed Jun 24, 2015 5:29 pm

Re: [Request]Anti Plant Bomb

Postby rovo93 » Thu Feb 18, 2016 9:57 am

XENZ wrote:
rovo93 wrote:

Hi man,
you know if there is a way to drop the bomb ?? I tried "Dropitem" function and it works with weapons.. but not with bomb !!!!
Or maybe i just wrong bomb name?? I tried lot of bomb name but nothing..

Thank youu :blush:


to make this you need to make some changes in .gsc's (client and server) (gameobjects.gsc, sd.gsc, ... and bind a key client side to drop it)
bomb is a special weapon, its like all players have the bomb every time but only can use it if "isbombcarrier" is true. this field is true when you are in the bomb model origin area, you "take" the bomb and model dissapear.

I suppose you want this for the promod script. if you want to know what things you could make, download cod4/mw2 promod and decompile it.


Ok man! Only god know where you learn this things :P
gj and thank you very much!!
Image
User avatar
Boboo
TeknoDev
Posts: 145
Joined: Thu Jul 23, 2015 3:41 pm

Re: [Request]Anti Plant Bomb

Postby Boboo » Thu Feb 18, 2016 2:32 pm

rovo93 wrote:
XENZ wrote:
rovo93 wrote:

Hi man,
you know if there is a way to drop the bomb ?? I tried "Dropitem" function and it works with weapons.. but not with bomb !!!!
Or maybe i just wrong bomb name?? I tried lot of bomb name but nothing..

Thank youu :blush:


to make this you need to make some changes in .gsc's (client and server) (gameobjects.gsc, sd.gsc, ... and bind a key client side to drop it)
bomb is a special weapon, its like all players have the bomb every time but only can use it if "isbombcarrier" is true. this field is true when you are in the bomb model origin area, you "take" the bomb and model dissapear.

I suppose you want this for the promod script. if you want to know what things you could make, download cod4/mw2 promod and decompile it.


Ok man! Only god know where you learn this things :P
gj and thank you very much!!


He learns it trough trying and raging and more trying and more raging :P :-P :-P
Image
XENZ
TeknoDog
TeknoDog
Posts: 46
Joined: Sat Jun 13, 2015 10:01 pm

Re: [Request]Anti Plant Bomb

Postby XENZ » Fri Feb 19, 2016 12:51 pm

Boboo wrote:
He learns it trough trying and raging and more trying and more raging :P :-P :-P

+1 :D
Image

Return to “InfinityScript”

Who is online

Users browsing this forum: No registered users and 9 guests