Fortress Forever

Go Back   Fortress Forever > Editing > Mapping > Lua

Reply
 
Thread Tools Display Modes
Old 01-10-2011, 01:47 PM   #1
zE
Pew pew ze beams
 
zE's Avatar
 
Join Date: Jan 2008
Gametype: Gathers
Affiliations: pew pew
Posts Rated Helpful 11 Times
Sniper lua

Hi, so anyone can help me with a lua that consists on this.

Sniper class
- No grenades
- No autorifle, and the other machine gun that i dont know the name

-Just Sniper rifle but with no Zoom avaible.

Thks : D
zE is offline   Reply With Quote


Old 01-10-2011, 02:38 PM   #2
Bridget
Banned
 
Bridget's Avatar
 
Join Date: Sep 2008
Class/Position: Soldier
Gametype: AVD
Affiliations: TALOS
Posts Rated Helpful 5 Times
Code:
function player_spawn(this)
	local player = CastToPlayer(this)
	if player:GetClass() == Player.kSniper then
		player:RemoveAmmo(Ammo.kGren1, 4)
		player:RemoveAmmo(Ammo.kGren2, 4)
		player:RemoveWeapon("ff_weapon_autorifle")
		player:RemoveWeapon("ff_weapon_nailgun")
	end
	return true
end

Last edited by Bridget; 01-10-2011 at 02:40 PM.
Bridget is offline   Reply With Quote


Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 04:21 AM.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2024, vBulletin Solutions, Inc.