Code: Select all
#include "zcommon.acs"
str WpnType[16] = { "ClipBox", "9mm", "Shotgun", "SuperShotgun", "Chaingun", "HMachineGun", "RocketLauncher", "SnubCannon", "PlasmaRifle", "TriLaser", "ParticleBlaster", "Tesla", "BFG9000", "Freeze", "Flamer", "Grenade" };
str WpnActor[16] = { "ClipBox", "GoldWand", "Shell", "Shell", "ClipBox", "Blaster", "RocketAmmo", "PhoenixRod", "Cell", "Crossbow", "SkullRod", "CWeapFlame", "Cell", "MWeapFrost", "Mace", "ArtiPoisonBag3" };
str WpnAmmo[16] = { "ClipBox", "GoldWandAmmo", "Shell", "Shell", "ClipBox", "BlasterAmmo", "RocketAmmo", "PhoenixRodAmmo", "Cell", "CrossbowAmmo", "SkullRodAmmo", "Mana2", "Cell", "Mana1", "MaceAmmo", "ArtiPoisonBag3" };
int numOfWep = 1;
/*
ClipBox, ClipBox, ClipBox
9mm, GoldWand, GoldWandAmmo
HMachineGun, Blaster, BlasterAmmo
SnubCannon, PhoenixRod, PhoenixRodAmmo
TriLaser, Crossbow, CrossbowAmmo
ParticleBlaster, SkullRod, SkullRodAmmo
Tesla, CWeapFlame, Mana2
Freeze, MWeapFrost, Mana1
Flamer, Mace, MaceAmmo
Grenade, ArtiPoisonBag3
Machette, CWeapMace
Kick, Staff
StunRod, Gauntlets
LaserPistol, MWeapWand
*/
script 1 OPEN
{
int i;
GiveInventory ("CWeapMace", 1);
GiveInventory ("Staff", 1);
GiveInventory ("Gauntlets", 1);
GiveInventory ("MWeapWand" ,1);
print (s:"Check the bottoms of the Controls Menu\nfor the Grenade key.");
For(i=1,i<=numOfWep,++i)
{
SpawnSpot(WpnType[i],i+300,i+300,0);
SetThingSpecial(i+300,ACS_ExecuteAlways,2,0,i);
}
}
script 2 (int Wpn)
{
GiveInventory (WpnActor[Wpn - 1], 1);
SetWeapon (WpnActor[Wpn - 1]);
GiveInventory (WpnAmmo[Wpn - 1], 999);
}
Code: Select all
For(i=1,i<=numOfWep,++i)
{
SpawnSpot(WpnType[i],i+300,i+300,0);
SetThingSpecial(i,ACS_ExecuteAlways,2,0,i+300);
}
[EDIT]I changed the code 'cuz i saw a problem, but it wasn't responsible for the compilation errors[/EDIT]