Aschbourne_PRC8/_module/nss/_open_cook.nss
Jaysyn904 5d27edafba Major update
Fixed CCOH, Fixed starting GP, Fixed DMFI languages, Fix cep weapon appearances, Fixed new player start up system.  Added PC deleter.  Added ACP 4.1.  Full compile.  Updated release archive.
2024-09-16 23:40:48 -04:00

132 lines
6.5 KiB
Plaintext

void main()
{
object oPC = GetLastOpenedBy();
object oSelf = OBJECT_SELF;
string sTagSelf = GetTag(oSelf);
int iCookType = StringToInt(GetStringRight(sTagSelf,3));
int iCookSkill = GetCampaignInt("UOACraft","iCookSkill",oPC);
int iCookChance = iCookSkill;
if (GetItemPossessedBy(oPC,"NoDrop_SkillLogBook")==OBJECT_INVALID)
{
CreateItemOnObject("skilllogbook",oPC,1);
}
if (iCookChance<350)
{
iCookChance = GetAbilityScore(oPC,ABILITY_WISDOM)*5;
iCookChance = iCookChance+(GetAbilityScore(oPC,ABILITY_DEXTERITY)*3);
iCookChance = iCookChance+(GetAbilityScore(oPC,ABILITY_CHARISMA)*2);
iCookChance = iCookChance*3;
if (iCookChance>350)iCookChance=350;
if (iCookSkill > iCookChance) iCookChance=iCookSkill;
}
switch (iCookType)
{
case 1:
{ //Bakers Oven
if (iCookChance>500)CreateItemOnObject("recipe001",oSelf,1); //BBQ Ancient Dire Bear
CreateItemOnObject("recipe002",oSelf,1); //BBQ Badger Meat
CreateItemOnObject("recipe003",oSelf,1); //BBQ Bat Meat
if (iCookChance>350)CreateItemOnObject("recipe004",oSelf,1); //BBQ Black Bear
if (iCookChance>400)CreateItemOnObject("recipe005",oSelf,1); //BBQ Brown Bear
if (iCookChance>350)CreateItemOnObject("recipe006",oSelf,1); //BBQ Cougar
CreateItemOnObject("recipe007",oSelf,1); //BBQ Cow
if (iCookChance>350)CreateItemOnObject("recipe008",oSelf,1); //BBQ Crag Cat
CreateItemOnObject("recipe009",oSelf,1); //BBQ Deer
CreateItemOnObject("recipe010",oSelf,1); //BBQ Dire Badger
if (iCookChance>450)CreateItemOnObject("recipe011",oSelf,1); //BBQ Dire Bear
CreateItemOnObject("recipe012",oSelf,1); //BBQ Dire Rat
if (iCookChance>450)CreateItemOnObject("recipe013",oSelf,1); //BBQ Dire Tiger
if (iCookChance>375)CreateItemOnObject("recipe014",oSelf,1); //BBQ Dire Wolf
CreateItemOnObject("recipe015",oSelf,1); //BBQ Dog
if (iCookChance>425)CreateItemOnObject("recipe016",oSelf,1); //BBQ Grizzly Bear
if (iCookChance>350)CreateItemOnObject("recipe017",oSelf,1); //BBQ Jaguar
if (iCookChance>375)CreateItemOnObject("recipe018",oSelf,1); //BBQ Leopard
if (iCookChance>400)CreateItemOnObject("recipe019",oSelf,1); //BBQ Lion
if (iCookChance>475)CreateItemOnObject("recipe020",oSelf,1); //BBQ Malar Panther
CreateItemOnObject("recipe021",oSelf,1); //BBQ Ox
if (iCookChance>300)CreateItemOnObject("recipe022",oSelf,1); //BBQ Panther
if (iCookChance>450)CreateItemOnObject("recipe023",oSelf,1); //BBQ Polar Bear
CreateItemOnObject("recipe024",oSelf,1); //BBQ Rat
CreateItemOnObject("recipe025",oSelf,1); //BBQ White Stag
if (iCookChance>400)CreateItemOnObject("recipe026",oSelf,1); //BBQ Winter Wolf
CreateItemOnObject("recipe027",oSelf,1); //BBQ Wolf
if (iCookChance>350)CreateItemOnObject("recipe028",oSelf,1); //BBQ Worg
CreateItemOnObject("recipe029",oSelf,1); //Cooked Fishsteak
CreateItemOnObject("recipe030",oSelf,1); //BBQ Wooly Razorback Meat
return;
}
case 2:
{ //Perma-Campfire
CreateItemOnObject("recipe002",oSelf,1); //BBQ Badger Meat
CreateItemOnObject("recipe003",oSelf,1); //BBQ Bat Meat
CreateItemOnObject("recipe010",oSelf,1); //BBQ Dire Badger
CreateItemOnObject("recipe012",oSelf,1); //BBQ Dire Rat
CreateItemOnObject("recipe015",oSelf,1); //BBQ Dog
CreateItemOnObject("recipe024",oSelf,1); //BBQ Rat
CreateItemOnObject("recipe027",oSelf,1); //BBQ Wolf
if (iCookChance>350)CreateItemOnObject("recipe028",oSelf,1); //BBQ Worg
CreateItemOnObject("recipe029",oSelf,1); //Cooked Fishsteak
CreateItemOnObject("recipe030",oSelf,1); //BBQ Wooly Razorback Meat
return;
}
case 3:
{ //Campfire with spit
if (iCookChance>500)CreateItemOnObject("recipe001",oSelf,1); //BBQ Ancient Dire Bear
CreateItemOnObject("recipe002",oSelf,1); //BBQ Badger Meat
CreateItemOnObject("recipe003",oSelf,1); //BBQ Bat Meat
if (iCookChance>350)CreateItemOnObject("recipe004",oSelf,1); //BBQ Black Bear
if (iCookChance>400)CreateItemOnObject("recipe005",oSelf,1); //BBQ Brown Bear
if (iCookChance>350)CreateItemOnObject("recipe006",oSelf,1); //BBQ Cougar
CreateItemOnObject("recipe007",oSelf,1); //BBQ Cow
if (iCookChance>350)CreateItemOnObject("recipe008",oSelf,1); //BBQ Crag Cat
CreateItemOnObject("recipe009",oSelf,1); //BBQ Deer
CreateItemOnObject("recipe010",oSelf,1); //BBQ Dire Badger
if (iCookChance>450)CreateItemOnObject("recipe011",oSelf,1); //BBQ Dire Bear
CreateItemOnObject("recipe012",oSelf,1); //BBQ Dire Rat
if (iCookChance>450)CreateItemOnObject("recipe013",oSelf,1); //BBQ Dire Tiger
if (iCookChance>375)CreateItemOnObject("recipe014",oSelf,1); //BBQ Dire Wolf
CreateItemOnObject("recipe015",oSelf,1); //BBQ Dog
if (iCookChance>425)CreateItemOnObject("recipe016",oSelf,1); //BBQ Grizzly Bear
if (iCookChance>350)CreateItemOnObject("recipe017",oSelf,1); //BBQ Jaguar
if (iCookChance>375)CreateItemOnObject("recipe018",oSelf,1); //BBQ Leopard
if (iCookChance>400)CreateItemOnObject("recipe019",oSelf,1); //BBQ Lion
if (iCookChance>475)CreateItemOnObject("recipe020",oSelf,1); //BBQ Malar Panther
CreateItemOnObject("recipe021",oSelf,1); //BBQ Ox
if (iCookChance>300)CreateItemOnObject("recipe022",oSelf,1); //BBQ Panther
if (iCookChance>450)CreateItemOnObject("recipe023",oSelf,1); //BBQ Polar Bear
CreateItemOnObject("recipe024",oSelf,1); //BBQ Rat
CreateItemOnObject("recipe025",oSelf,1); //BBQ White Stag
if (iCookChance>400)CreateItemOnObject("recipe026",oSelf,1); //BBQ Winter Wolf
CreateItemOnObject("recipe027",oSelf,1); //BBQ Wolf
if (iCookChance>350)CreateItemOnObject("recipe028",oSelf,1); //BBQ Worg
CreateItemOnObject("recipe029",oSelf,1); //Cooked Fishsteak
CreateItemOnObject("recipe030",oSelf,1); //BBQ Wooly Razorback Meat
return;
}
case 4:
{ //Campfire with cauldron
break;
}
default:
{ //Tinderbox Campfire
CreateItemOnObject("recipe002",oSelf,1); //BBQ Badger Meat
CreateItemOnObject("recipe003",oSelf,1); //BBQ Bat Meat
CreateItemOnObject("recipe012",oSelf,1); //BBQ Dire Rat
CreateItemOnObject("recipe015",oSelf,1); //BBQ Dog
CreateItemOnObject("recipe024",oSelf,1); //BBQ Rat
CreateItemOnObject("recipe027",oSelf,1); //BBQ Wolf
CreateItemOnObject("recipe029",oSelf,1); //Cooked Fishsteak
CreateItemOnObject("recipe030",oSelf,1); //BBQ Wooly Razorback Meat
return;
}
}
}