Jump to content

blacksmith on the demon tower


Recommended Posts

  • Active Member

It's not hard but there's a lot of code, it's a mess, takes some time to find the correct part but you can start by searching the vnum 20074(as I remmember)

Link to comment
Share on other sites

  • Premium

char_item.cpp

Inside:

void CHARACTER::ReceiveItem (LPCHARACTER from, LPITEM item)

 

Look for:

	case DEVILTOWER_BLACKSMITH_WEAPON_MOB:
        case DEVILTOWER_BLACKSMITH_ARMOR_MOB:
        case DEVILTOWER_BLACKSMITH_ACCESSORY_MOB:
            if (item->GetRefinedVnum() != 0 && item->GetRefineSet() != 0 && item->GetRefineSet() < 500) {
                from->SetRefineNPC (this);
                from->RefineInformation (item->GetCell(), REFINE_TYPE_MONEY_ONLY);
            }
            else {
                from->ChatPacket (CHAT_TYPE_INFO, LC_TEXT ("ÀÌ ¾ÆÀÌÅÛÀº °³·®ÇÒ ¼ö ¾ø½À´Ï´Ù."));
            }
            break;

 

 

change REFINE_TYPE_MONEY_ONLY  into REFINE_TYPE_MUSIN 

I dont remember if it was musin, i cant test it now. Check item_lenght.h for all types or:

    REFINE_TYPE_NORMAL
    REFINE_TYPE_SCROLL
    REFINE_TYPE_HYUNIRON
    REFINE_TYPE_MONEY_ONLY
    REFINE_TYPE_MUSIN
    REFINE_TYPE_BDRAGON

  • Love 2
Link to comment
Share on other sites

  • Premium
13 hours ago, tierrilopes said:

Read above post.

Recompile source.

Upload game.

Test if works.

I think the best solution is to modify the DoRefine linked to that because musin uses DoRefineWithScrolls

    else
    {
        // 실패! 모든 아이템이 사라짐.
        DBManager::instance().SendMoneyLog(MONEY_LOG_REFINE, item->GetVnum(), -cost);
        NotifyRefineFail(this, item, IsRefineThroughGuild() ? "GUILD" : "POWER");
        item->AttrLog();
        ITEM_MANAGER::instance().RemoveItem(item, "REMOVE (REFINE FAIL)");

        //PointChange(POINT_GOLD, -cost);
        PayRefineFee(cost);
    }

    return true;
}

 

Here is the part you will need to add a check, like

if mapindex = deviltower

then

 {
        DBManager::instance().SendMoneyLog(MONEY_LOG_REFINE, item->GetVnum(), -cost);
        NotifyRefineFail(this, item, IsRefineThroughGuild() ? "GUILD" : "POWER");
        item->AttrLog();
        PayRefineFee(cost);
    }

    else
    {
        // 실패! 모든 아이템이 사라짐.
        DBManager::instance().SendMoneyLog(MONEY_LOG_REFINE, item->GetVnum(), -cost);
        NotifyRefineFail(this, item, IsRefineThroughGuild() ? "GUILD" : "POWER");
        item->AttrLog();
        ITEM_MANAGER::instance().RemoveItem(item, "REMOVE (REFINE FAIL)");

        //PointChange(POINT_GOLD, -cost);
        PayRefineFee(cost);
    }

 

This is not tested, try on your own

If im wrong let me understand it :)

Link to comment
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now

Announcements



  • Similar Content

  • Activity

    1. 11

      Metin2 Closed Beta Content (2003-2004)

    2. 11

      Metin2 Closed Beta Content (2003-2004)

    3. 0

      Football Ground

    4. 11

      Metin2 Closed Beta Content (2003-2004)

    5. 0

      Error compile binary Zentoria2

    6. 11

      Metin2 Closed Beta Content (2003-2004)

  • Recently Browsing

    • No registered users viewing this page.
×
×
  • Create New...

Important Information

Terms of Use / Privacy Policy / Guidelines / We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.