Initial upload
Initial upload
This commit is contained in:
34
_module/nss/aw_dimdoors.nss
Normal file
34
_module/nss/aw_dimdoors.nss
Normal file
@@ -0,0 +1,34 @@
|
||||
#include "NW_I0_GENERIC"
|
||||
#include "1_loot_inc_data"
|
||||
#include "1_loot_inc_main"
|
||||
#include "1_loot_inc_gen"
|
||||
// #include "nw_o2_coninclude"
|
||||
// Uncomment the above line if you would prefer to use the standard BioWare
|
||||
// treasure scripts. If you do so delete the line that includes "loot_inc_gen_mod"
|
||||
|
||||
void main()
|
||||
{
|
||||
object oSelf = OBJECT_SELF;
|
||||
object oItem = GetFirstItemInInventory(oSelf);
|
||||
int iChance = 25; //Percenatage of the time each item has a chance of dropping
|
||||
do{
|
||||
int iDroppable = GetDroppableFlag(oItem);
|
||||
if (iDroppable == FALSE){
|
||||
int iCopy = GetLocalInt(oItem, "copied");
|
||||
if (iCopy == 0){
|
||||
string sResref = GetResRef(oItem);
|
||||
int id100 = d100(1);
|
||||
if (id100 <= iChance){
|
||||
object oItem2 = CreateItemOnObject(sResref, oSelf, 1);
|
||||
}
|
||||
}
|
||||
}
|
||||
if (iDroppable == TRUE){} //This is so it doesn't make addittional things that are already droppable
|
||||
SetLocalInt(oItem, "copied", 1);
|
||||
}while ((oItem = GetNextItemInInventory(oSelf)) != OBJECT_INVALID);
|
||||
SetSpawnInCondition(NW_FLAG_AMBIENT_ANIMATIONS);
|
||||
SetSpawnInCondition(NW_FLAG_END_COMBAT_ROUND_EVENT);
|
||||
SetListeningPatterns();
|
||||
WalkWayPoints();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user