Release Obtain weapons and perks
#1
[hide]Obtain a weapon:

Code:
self giveWeapon("weapon_mp");

Switch to Weapon:

Code:
self switchToWeapon("weapon_mp");

Set Spawn Weapon:

Code:
self setSpawnWeapon("weapon_mp");

Take Weapon:

Code:
self takeWeapon("weapon_mp");
or
Code:
self takeAllWeapons();

Set Weapon ammo:

Code:
self setWeaponAmmoStock("weapon_mp", amount of ammo);
or
Code:
self giveMaxAmmo("weapon_mp");

Set Weapon Options:

Code:
self giveWeapon("weapon_mp", 0, self calcWeaponOptions( CamoNumber, LensNumber, ReticleNumber, ClantagNumber, EmblemNumber) );

Code:
Camoes: Reticle: Lens: ClanTag: Emblem: 0 = None//////0 = Dot///////////////////////0 = Clear Lens/////////0 = No//////0 = No 1 = Dusty/////1 = Semi Circles//////////////1 = Red Lens///////////1 = Yes/////1 = Yes 2 = Ice///////2 = Lines With Dot////////////2 = Blue Lens 3 = Red///////3 = Hollow Circle/////////////3 = Green Lens 4 = Olive/////4 = Smiley Face///////////////4 = Orange Lens 5 = Nevada////5 = Arrows Vertical///////////5 = Yellow Lens 6 = Sahara////6 = Arrows Horizontal 7 = ERDL//////7 = Arrows With Dot 8 = Tiger/////8 = Bones 9 = Berlin////9 = Burst 10 = Warsaw///10 = Circle Within A Circle 11 = Siberia//11 = Circle 12 = Yuhon////12 = Circle Outline 13 = Woodland/13 = Circle Outline With Dot 14 = Flora////14 = Circle with Crosshairs 15 = Gold/////15 = Circle with Outer Lines //////////////16 = Circle With Inner Lines //////////////17 = Circle With Arrows //////////////18 = Circle with Triangles //////////////19 = Outer Crosshairs //////////////20 = Small Crosshairs //////////////21 = Large Crosshairs //////////////22 = Crosshairs //////////////23 = Crosshairs With A Dot //////////////24 = Diamond //////////////25 = Diamond Outline //////////////26 = Heart //////////////27 = Radiation //////////////28 = Skull //////////////29 = Square //////////////30 = Square Outline //////////////31 = Square with Crosshairs //////////////32 = Star //////////////33 = Three Dots //////////////34 = Treyarch //////////////35 = Triangle //////////////36 = Outer Triangles //////////////37 = X //////////////38 = X With Dot //////////////39 = Yin Yang

Example:

Quote:self giveWeapon("m16_reflex_mp", 0, self calcWeaponOptions( 15, 34, 3, 1, 1 ) );
self giveMaxAmmo("m16_reflex_mp");

Get Perk:

Code:
self setPerk("perk");

Clear Perks:

Code:
self clearPerks();

Example:

Quote:self clearPerks();
self setPerk("specialty_movefaster");

All Weapon names: (thanks to @d0h!)

.txt   All weapons names (DVAR).txt (Size: 42.42 KB / Downloads: 171)

All Perk names: (don't know who made this)

.txt   All perk names (DVAR).txt (Size: 3.92 KB / Downloads: 168)
[/hide]
Quote: (report) SuperNovaAO - 03-03 23:34 -- Your mom's cunt also belongs to her private parts, yet everyone knows it.
(report) OrangePL - 03-03 23:34 -- And if you can't understand, this is called PRIVATE message
[Image: userbars.jpg]
My MW2 mod Group: http://steamcommunity.com/groups/davesmodzz
Reply

#2
Nice.. but this aint the tutorial section
(08-10-2011, 12:58)Pozzuh Wrote:
Se7en Wrote:Stealed, from cod4 mod ...
look who's talking

[Release] Old School Mod v2.2
[Release] Scroll menu

Reply

#3
And the meat reticle in zombies?
Reply

#4
(08-30-2011, 19:07)iAegle Wrote: Nice.. but this aint the tutorial section

doesn't really look like a tutorial for me
it are just some codes Tongue
Quote: (report) SuperNovaAO - 03-03 23:34 -- Your mom's cunt also belongs to her private parts, yet everyone knows it.
(report) OrangePL - 03-03 23:34 -- And if you can't understand, this is called PRIVATE message
[Image: userbars.jpg]
My MW2 mod Group: http://steamcommunity.com/groups/davesmodzz
Reply

#5
also you forgot

set the weapon someone spawns with:
Code:
self setSpawnWeapon( "weapon_mp" );

and this is wrong:
Code:
self setWeaponAmmoStock("weapon_mp");
should be
Code:
self setWeaponAmmoStock("weapon_mp", amount of ammo );
(08-10-2011, 12:58)Pozzuh Wrote:
Se7en Wrote:Stealed, from cod4 mod ...
look who's talking

[Release] Old School Mod v2.2
[Release] Scroll menu

Reply

#6
(08-30-2011, 19:10)iAegle Wrote: also you forgot

set the weapon someone spawns with:
Code:
self setSpawnWeapon( "weapon_mp" );

and this is wrong:
Code:
self setWeaponAmmoStock("weapon_mp");
should be
Code:
self setWeaponAmmoStock("weapon_mp", amount of ammo );

shit, thanks for saying xD
Quote: (report) SuperNovaAO - 03-03 23:34 -- Your mom's cunt also belongs to her private parts, yet everyone knows it.
(report) OrangePL - 03-03 23:34 -- And if you can't understand, this is called PRIVATE message
[Image: userbars.jpg]
My MW2 mod Group: http://steamcommunity.com/groups/davesmodzz
Reply

#7
(08-30-2011, 19:08)Lemon Wrote: And the meat reticle in zombies?

Reply

#8
(08-30-2011, 19:12)Lemon Wrote:
(08-30-2011, 19:08)Lemon Wrote: And the meat reticle in zombies?

i don't think thats in multiplayer xD
Quote: (report) SuperNovaAO - 03-03 23:34 -- Your mom's cunt also belongs to her private parts, yet everyone knows it.
(report) OrangePL - 03-03 23:34 -- And if you can't understand, this is called PRIVATE message
[Image: userbars.jpg]
My MW2 mod Group: http://steamcommunity.com/groups/davesmodzz
Reply

#9
probably late to the game but I'm tweaking Cyborg's AI mod and added several new purchaseable weapons/perks. Only problem is, I can't seem to set the max ammo of the weapons.

I'm using the following snippet:

Code:
else if( response == "buy_commando") { if (self.money >= 250) { self playSoundToPlayer("zmb_cha_ching", self); self closeMenu( game[ "modmenu1" ] ); self giveWeapon("commando_dualclip_mp"); self.money -= 250; self setWeaponAmmoStock("commando_dualclip_mp",720); self.hud_score_value setValue(self.money); self thread maps\mp\gametypes\aico::ScoreHUD( -250 ); self playSoundToPlayer("zmb_cha_ching", self); self iPrintln("Commando purchased"); } else self playSoundToPlayer("zmb_no_cha_ching", self); }

it'll give me the weapon and take 250 "points" from the player, but never gives them more than the 240/120 ammo.

any ideas?
Reply

#10
(09-02-2012, 20:25)wise Wrote: probably late to the game but I'm tweaking Cyborg's AI mod and added several new purchaseable weapons/perks. Only problem is, I can't seem to set the max ammo of the weapons.

I'm using the following snippet:

Code:
else if( response == "buy_commando") { if (self.money >= 250) { self playSoundToPlayer("zmb_cha_ching", self); self closeMenu( game[ "modmenu1" ] ); self giveWeapon("commando_dualclip_mp"); self.money -= 250; self setWeaponAmmoStock("commando_dualclip_mp",720); self.hud_score_value setValue(self.money); self thread maps\mp\gametypes\aico::ScoreHUD( -250 ); self playSoundToPlayer("zmb_cha_ching", self); self iPrintln("Commando purchased"); } else self playSoundToPlayer("zmb_no_cha_ching", self); }

it'll give me the weapon and take 250 "points" from the player, but never gives them more than the 240/120 ammo.

any ideas?
It'll always give as much ammo as the max ammo. If you want to increase the max ammo you'd want to create a custom version of the commando.
Would like to make a donation? Click here
Reply



Possibly Related Threads…
Thread Author Replies Views Last Post
  [Release] [SOURCE] Random Weapons. [HARD] Tony. 1 6,152 11-08-2013, 11:11
Last Post: Nekochan
  Help source random weapons [HARD] Tony. 4 6,562 11-08-2013, 05:25
Last Post: [HARD] Tony.
  MW3 Hide WEAPONS [HARD] Tony. 7 9,603 10-09-2013, 15:16
Last Post: [HARD] Tony.
  Porting some weapons, ADS broken? DidUknowiPwn 0 3,647 09-10-2013, 01:13
Last Post: DidUknowiPwn
  [Request] Mw2 lock weapons seraph1995 1 4,713 08-18-2013, 15:31
Last Post: DidUknowiPwn
  [Release] Pack-A-Punch Weapons TheSchitt 40 40,440 08-07-2013, 04:51
Last Post: FrostLight
  Help DONATE points for weapons [HARD] Tony. 10 10,252 05-24-2013, 10:59
Last Post: Pozzuh
  [Tutorial] How to import Weapons from SP to MP in Black Ops using Mod Tools d0h! 114 98,657 05-21-2013, 16:33
Last Post: ZURA.
  [Tutorial] How to port weapons rotceh_dnih 13 19,552 04-13-2013, 23:43
Last Post: rotceh_dnih
  Help Perks do not work (( x1412 6 6,240 04-06-2013, 18:09
Last Post: x1412

Forum Jump:


Users browsing this thread:
1 Guest(s)

Forum Powered By MyBB, Theme by © 2002-2026 Melroy van den Berg.