41 lines
1.2 KiB
Plaintext
41 lines
1.2 KiB
Plaintext
#include "tr_items_inc"
|
|
#include "nw_i0_tool"
|
|
#include "craft_inc"
|
|
|
|
void main()
|
|
{
|
|
int nSkillTest, nItemsBits = 0;
|
|
int nSmithingSkillNumber;
|
|
object oPC = GetLastUsedBy();
|
|
|
|
if(HasItem(oPC, "Amanbraknulcopperhelm"))
|
|
nItemsBits++;
|
|
if(HasItem(oPC, "Leatherstraps"))
|
|
nItemsBits++;
|
|
if(HasItem(oPC, "Iron"))
|
|
nItemsBits++;
|
|
|
|
//////////////////////////////////////////////////////////
|
|
if(nItemsBits == 3){
|
|
DestroyObject(GetItemPossessedBy(oPC, "Leatherstraps"));
|
|
DestroyObject(GetItemPossessedBy(oPC, "Amanbraknulcopperhelm"));
|
|
DestroyObject(GetItemPossessedBy(oPC, "Iron"));
|
|
nSmithingSkillNumber = GetCampaignInt(GZ_AMON_CRAFT, "GZ_DB_SMITHING!", oPC);
|
|
AssignCommand(oPC, ActionPlayAnimation(ANIMATION_LOOPING_GET_MID, 3.0, 3.0));
|
|
|
|
if(nSkillTest = (nSmithingSkillNumber+nRoll100) >= AMA_HELM2){
|
|
FloatingTextStringOnCreature("*You create a good helmet*", oPC);
|
|
CreateItemOnObject("Amanbraknulironhelm", oPC);
|
|
|
|
}
|
|
else{
|
|
AmonCraftSmithing(oPC, nSmithingSkillNumber=nSmithingSkillNumber+nRoll2);
|
|
|
|
}
|
|
}
|
|
else
|
|
FloatingTextStringOnCreature("*You do not have Iron, leatherstraps or +1 helm*", oPC);
|
|
|
|
|
|
}
|