generated from Jaysyn/ModuleTemplate
Initial upload
Initial upload
This commit is contained in:
19
_mod/_module/nss/uc_t_notok2.nss
Normal file
19
_mod/_module/nss/uc_t_notok2.nss
Normal file
@@ -0,0 +1,19 @@
|
||||
// uc_t_notok2 - Unit Creation V2 - not okay to build
|
||||
// By Deva Bryson Winblood. 04/10/2005
|
||||
#include "uc_h"
|
||||
|
||||
int StartingConditional()
|
||||
{
|
||||
object oPC=GetPCSpeaker();
|
||||
int nBase=GetLocalInt(oPC,"nUCBase");
|
||||
string sID=GetLocalString(oPC,"sTeamID");
|
||||
int nMax=GetLocalInt(GetModule(),sID+"_UNITS");
|
||||
int nUnit=2;
|
||||
int nNumber=nBase+nUnit;
|
||||
string sDescription;
|
||||
if (nNumber+1>nMax) return FALSE;
|
||||
if (HasSufficientResources(oPC,nNumber,1)) return FALSE;
|
||||
sDescription=GetUnitDescription(sID,nNumber);
|
||||
SetCustomToken(1001+nUnit,sDescription);
|
||||
return TRUE;
|
||||
}
|
||||
Reference in New Issue
Block a user