hi
what do i put in the script for mp level to make it so all the players are only allowed to use the sniper only?
thanks
i want snipers only plz help me all
Moderator: Moderators
i want snipers only plz help me all
...prepare for your finest hour...
you need to replace all the weapons after they have spawned. Here's a script that gives all players a bolt action rifle, just adapt it to what you want.
There is one problem and that is that it isn't reliable on the first round of the map in spearhead, I haven't solved this porblem. It's due to the weapons selection screen
There is one problem and that is that it isn't reliable on the first round of the map in spearhead, I haven't solved this porblem. It's due to the weapons selection screen
Code: Select all
//Script that assigns players weapons after they join a team
//could change it to be randomised or something
level waittill roundstart
//First set up an array of 44 to store the players status
for (local.i = 1; local.i <= 44; local.i++)
{
level.PlayerGunsReplace[local.i] = 0
}
RepeatTest:
//Array initialised now loop
for (local.y = 1; local.y <= $player.size; local.y++)
{
if (level.PlayerGunsReplace[local.y] == 0)
{
if ( isalive($player[local.y]) && ($player[local.y].health > 0) )
{
if( $player[local.y].dmteam == axis )
{
level.PlayerGunsReplace[local.y] = 1
thread GiveAxisWeapons $player[local.y]
}
else if( $player[local.y].dmteam == allies )
{
level.PlayerGunsReplace[local.y] = 1
thread GiveAlliedWeapons $player[local.y]
}
else
{
//not added to team yet
//println (local.y + ": Found but not in team yet")
}
}
}
}
wait 1
goto RepeatTest
end
GiveAxisWeapons local.player:
wait 2
local.player takeall
local.player item models/weapons/p38.tik
local.player item models/weapons/kar98.tik
local.player item models/weapons/steilhandgranate.tik
local.player ammo grenade 1
local.player item models/weapons/nebelhandgranate.tik
local.player ammo smokegrenade 1
local.player useweaponclass "rifle"
local.player iprint "You have been given a bolt action rifle"
println "should have given player axis weapons"
end
GiveAlliedWeapons local.player:
wait 2
local.player takeall
local.player item models/weapons/Webley_Revolver.tik
local.player item models/weapons/enfield.tik
local.player item models/weapons/mills_grenade.tik
local.player ammo grenade 1
local.player item models/weapons/M18_smoke_grenade.tik
local.player ammo smokegrenade 1
//local.player weapnext
local.player useweaponclass "rifle"
local.player iprint "You have been given a bolt action rifle"
println "should have given player allied weapons"
end
[VS-UK]Capt.Parts[BnHQ]
- small_sumo
- Lieutenant General
- Posts: 953
- Joined: Mon Jul 01, 2002 4:17 pm
- Contact:
