- scriptified ammo.
- moved inventory stuff into its own directory.
This commit is contained in:
parent
d91023ba0b
commit
a597979738
13 changed files with 157 additions and 135 deletions
|
|
@ -2623,7 +2623,7 @@ void FParser::SF_MaxPlayerAmmo()
|
|||
}
|
||||
else if(t_argc >= 3)
|
||||
{
|
||||
AAmmo * iammo = (AAmmo*)players[playernum].mo->FindInventory(ammotype);
|
||||
auto iammo = players[playernum].mo->FindInventory(ammotype);
|
||||
amount = intvalue(t_argv[2]);
|
||||
if(amount < 0) amount = 0;
|
||||
if (!iammo)
|
||||
|
|
@ -2644,7 +2644,7 @@ void FParser::SF_MaxPlayerAmmo()
|
|||
break;
|
||||
}
|
||||
}
|
||||
iammo->BackpackMaxAmount=amount;
|
||||
((AAmmo*)iammo)->BackpackMaxAmount=amount;
|
||||
}
|
||||
|
||||
t_return.type = svt_int;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue