// Variables in this section define what happens during item pickup.
// Player can get health, armor and/or ammo on top of or instead of an item.
// The format of the value is:
-// "<add|override> [health] [armor] [shells] [bullets] [rockets] [cells]"
+// "<add|override> [health] [armor] [shells] [bullets] [rockets] [cells] [plasma] [fuel]"
// For example "add 50" will give 50 health and the original item.
// "override 0 0 5" will give 5 shells instead of the item.
set g_player_template_example_pickup_health_small "default" "What items does player get when they pickup small health"
{
case 1:
{
- GivePlayerHealth(player, stof(argv(i)));
+ GiveResource(player, RESOURCE_HEALTH, stof(argv(i)));
break;
}
case 2:
{
- GivePlayerArmor(player, stof(argv(i)));
+ GiveResource(player, RESOURCE_ARMOR, stof(argv(i)));
break;
}
case 3:
{
- GivePlayerResource(player, RESOURCE_SHELLS, stof(argv(i)));
+ GiveResource(player, RESOURCE_SHELLS, stof(argv(i)));
break;
}
case 4:
{
- GivePlayerResource(player, RESOURCE_BULLETS, stof(argv(i)));
+ GiveResource(player, RESOURCE_BULLETS, stof(argv(i)));
break;
}
case 5:
{
- GivePlayerResource(player, RESOURCE_ROCKETS, stof(argv(i)));
+ GiveResource(player, RESOURCE_ROCKETS, stof(argv(i)));
break;
}
case 6:
{
- GivePlayerResource(player, RESOURCE_CELLS, stof(argv(i)));
+ GiveResource(player, RESOURCE_CELLS, stof(argv(i)));
+ break;
+ }
+ case 7:
+ {
+ GiveResource(player, RESOURCE_PLASMA, stof(argv(i)));
+ break;
+ }
+ case 8:
+ {
+ GiveResource(player, RESOURCE_FUEL, stof(argv(i)));
break;
}
}
}
if (!warmup_stage)
{
- GivePlayerRandomWeapons(player,
- PlayerTemplate_GetFloatValue(template,
+ GiveRandomWeapons(player, PlayerTemplate_GetFloatValue(template,
"random_start_weapons_count"),
PlayerTemplate_GetStringValue(template, "random_start_weapons"),
PlayerTemplate_GetFloatValue(template, "random_start_shells"),