summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--npc/craft/smith.txt14
-rw-r--r--npc/guilds/alchemy.txt1
-rw-r--r--npc/guilds/forge.txt1
3 files changed, 10 insertions, 6 deletions
diff --git a/npc/craft/smith.txt b/npc/craft/smith.txt
index 87dc9d55d..fa866f7eb 100644
--- a/npc/craft/smith.txt
+++ b/npc/craft/smith.txt
@@ -17,15 +17,14 @@
// Usage: SmithSystem ({scope})
// Scopes: CRAFT_NPC, CRAFT_PLAYER, CRAFT_GUILD
-// If an invalid scope is passed, .knowledge won't be set but will be required
+// CRAFT_NPC - Unlocks all recipes
+// CRAFT_PLAYER - Normal behavior
+// CRAFT_GUILD - Items created will be Guild-bound
// Returns true on success, false on failure
function script SmithSystem {
// Set .scope, .knowledge and .success
.scope=getarg(0, CRAFT_PLAYER);
- if (.scope == CRAFT_PLAYER)
- copyarray(.knowledge,RECIPES_EQUIPMENT,getarraysize(RECIPES_EQUIPMENT));
- else if (.scope == CRAFT_GUILD)
- copyarray(.knowledge,$@RECIPES_EQUIPMENT[getcharid(2)],getarraysize($@RECIPES_EQUIPMENT[getcharid(2)]));
+ copyarray(.knowledge,RECIPES_EQUIPMENT,getarraysize(RECIPES_EQUIPMENT));
.success=false;
setskin "craft4";
@@ -49,7 +48,10 @@ function script SmithSystem {
// Mark the crafting in your score book (except dagger)
if (.@it != Dagger)
CRAFTING_SCORE+=1;
- getnameditem(.@it, strcharinfo(0));
+ if (.scope == CRAFT_GUILD)
+ getitembound(.@it, 1, 2); // Create a guild-bound item
+ else
+ getnameditem(.@it, strcharinfo(0));
if (getskilllv(TMW2_CRAFT)) {
delinventorylist(); // Needed, because we'll rely on rfind()
getinventorylist();
diff --git a/npc/guilds/alchemy.txt b/npc/guilds/alchemy.txt
index 008e2c2b6..99da224c7 100644
--- a/npc/guilds/alchemy.txt
+++ b/npc/guilds/alchemy.txt
@@ -8,6 +8,7 @@ guilds,24,35,0 script Guild Chemistry NPC_NO_SPRITE,{
do
{
mesc l("What will you brew today?");
+ mesc l("Note: Items brewed here will use a Guild Recipe instead!");
if (AlchemySystem(CRAFT_GUILD))
{
mesc l("Success!"), 3;
diff --git a/npc/guilds/forge.txt b/npc/guilds/forge.txt
index 5f3468167..6f2b3c842 100644
--- a/npc/guilds/forge.txt
+++ b/npc/guilds/forge.txt
@@ -10,6 +10,7 @@ guilds,24,27,0 script Guild Blacksmith NPC_NO_SPRITE,{
{
mesc l("What will you forge today?");
//mesc l("You might need to have a @@ equipped for some recipes!", getitemlink(Knife));
+ mesc l("Note: Items forged here will be guild-bound, but will use player recipes and bonuses!");
if (SmithSystem(CRAFT_GUILD))
{
mesc l("Success!"), 3;