Jump to content

Recommended Posts

  • 2 weeks later...

Someone tried it ? Any problems ?

Considering he's just commenting a line, I can't see how that would not work, so yeah, no problems. While you are at it, you can also delete the line that goes afterwards, you don't need to SetCount to the same count you already had.

Edited by Think
Link to comment
https://metin2.dev/topic/7579-infinite-arrows/#findComment-48549
Share on other sites

Someone tried it ? Any problems ?

Considering he's just commenting a line, I can't see how that would not work, so yeah, no problems. While you are at it, you can also delete the line that goes afterwards, you don't need to SetCount to the same count you already had.

Can you give full code block ? I dont understand c++,  most likely l'll make mistakes and this will make me crazy. Thank you Think

Link to comment
https://metin2.dev/topic/7579-infinite-arrows/#findComment-48659
Share on other sites

  • Former Staff

open "char_battle.cpp" from game folder in server source and search for

void CHARACTER::UseArrow(LPITEM pkArrow, DWORD dwArrowCount)

it'll be like this

void CHARACTER::UseArrow(LPITEM pkArrow, DWORD dwArrowCount)
{
    int iCount = pkArrow->GetCount();
    DWORD dwVnum = pkArrow->GetVnum();
    iCount = iCount - MIN(iCount, dwArrowCount);
    pkArrow->SetCount(iCount);

    if (iCount == 0)
    {
        LPITEM pkNewArrow = FindSpecifyItem(dwVnum);

        sys_log(0, "UseArrow : FindSpecifyItem %u %p", dwVnum, get_pointer(pkNewArrow));

        if (pkNewArrow)
            EquipItem(pkNewArrow);
    }
}

make it look like this

void CHARACTER::UseArrow(LPITEM pkArrow, DWORD dwArrowCount)
{
    int iCount = pkArrow->GetCount();
    DWORD dwVnum = pkArrow->GetVnum();
    if (iCount == 0)
    {
        LPITEM pkNewArrow = FindSpecifyItem(dwVnum);

        sys_log(0, "UseArrow : FindSpecifyItem %u %p", dwVnum, get_pointer(pkNewArrow));

        if (pkNewArrow)
            EquipItem(pkNewArrow);
    }
}

 

  • Love 1
Link to comment
https://metin2.dev/topic/7579-infinite-arrows/#findComment-48685
Share on other sites

Hello,

 

what problème? no time

 

4825620721142548.jpg

Tu ne l'as pas mit dans les protos.

You don't add any time in the protos

I have this problem too and in proto i have this:

 

79503    quiver_15_days    ITEM_WEAPON    WEAPON_ARROW    1    ANTI_MUSA | ANTI_SURA | ANTI_MUDANG | ANTI_STACK    NONE    WEAR_ARROW    NONE    0    0    0    0    0    REAL_TIME    1296000    LIMIT_NONE    0    APPLY_NONE    0    APPLY_NONE    0    APPLY_NONE    0    0    4    0    25    0    0    0    0    0

 

Edited by Metin2 Dev
Core X - External 2 Internal
Link to comment
https://metin2.dev/topic/7579-infinite-arrows/#findComment-49065
Share on other sites

my proto

 

79503    quiver_15_days    ITEM_WEAPON    WEAPON_ARROW    1    ANTI_MUSA | ANTI_SURA | ANTI_MUDANG | ANTI_STACK    NONE    WEAR_ARROW    NONE    0    0    0    0    0    REAL_TIME    1296000    LIMIT_NONE    0    APPLY_NONE    0    APPLY_NONE    0    APPLY_NONE    0    0    4    0    25    0    0    0    0    0

 

Link to comment
https://metin2.dev/topic/7579-infinite-arrows/#findComment-49069
Share on other sites

uitooltip

 

""""""
#1) Search: if item.ITEM_TYPE_WEAPON == itemType:
#2) Delete their declaration and paste:
        if item.ITEM_TYPE_WEAPON == itemType:
            self.__AppendLimitInformation()
            self.AppendSpace(5)
            if item.WEAPON_FAN == itemSubType:
                self.__AppendMagicAttackInfo()
                self.__AppendAttackPowerInfo()
            else:
                self.__AppendAttackPowerInfo()
                self.__AppendMagicAttackInfo()
            
            self.__AppendAffectInformation()
            self.__AppendAttributeInformation(attrSlot)
            
            self.AppendWearableInformation()
            if itemSubType != item.WEAPON_UNLIMITED_ARROW:
                self.__AppendMetinSlotInfo(metinSlot)
            else:
                bHasRealtimeFlag = 0
                for i in xrange(item.LIMIT_MAX_NUM):
                    (limitType, limitValue) = item.GetLimit(i)
                    if item.LIMIT_REAL_TIME == limitType:
                        bHasRealtimeFlag = 1
                
                if bHasRealtimeFlag == 1:
                    self.AppendMallItemLastTime(metinSlot[0])
""""""

Link to comment
https://metin2.dev/topic/7579-infinite-arrows/#findComment-49164
Share on other sites

open "char_battle.cpp" from game folder in server source and search for

void CHARACTER::UseArrow(LPITEM pkArrow, DWORD dwArrowCount)

it'll be like this

void CHARACTER::UseArrow(LPITEM pkArrow, DWORD dwArrowCount)
{
    int iCount = pkArrow->GetCount();
    DWORD dwVnum = pkArrow->GetVnum();
    iCount = iCount - MIN(iCount, dwArrowCount);
    pkArrow->SetCount(iCount);

    if (iCount == 0)
    {
        LPITEM pkNewArrow = FindSpecifyItem(dwVnum);

        sys_log(0, "UseArrow : FindSpecifyItem %u %p", dwVnum, get_pointer(pkNewArrow));

        if (pkNewArrow)
            EquipItem(pkNewArrow);
    }
}

make it look like this

void CHARACTER::UseArrow(LPITEM pkArrow, DWORD dwArrowCount)
{
    int iCount = pkArrow->GetCount();
    DWORD dwVnum = pkArrow->GetVnum();
    if (iCount == 0)
    {
        LPITEM pkNewArrow = FindSpecifyItem(dwVnum);

        sys_log(0, "UseArrow : FindSpecifyItem %u %p", dwVnum, get_pointer(pkNewArrow));

        if (pkNewArrow)
            EquipItem(pkNewArrow);
    }
}

 

btw this :

    if (iCount == 0)
    {
        LPITEM pkNewArrow = FindSpecifyItem(dwVnum);

        sys_log(0, "UseArrow : FindSpecifyItem %u %p", dwVnum, get_pointer(pkNewArrow));

        if (pkNewArrow)
            EquipItem(pkNewArrow);
    }

is basicly mmmmmmm useless

Link to comment
https://metin2.dev/topic/7579-infinite-arrows/#findComment-49186
Share on other sites

btw this :

    if (iCount == 0)
    {
        LPITEM pkNewArrow = FindSpecifyItem(dwVnum);

        sys_log(0, "UseArrow : FindSpecifyItem %u %p", dwVnum, get_pointer(pkNewArrow));

        if (pkNewArrow)
            EquipItem(pkNewArrow);
    }

is basicly mmmmmmm useless

Is this part useless ? Can you explain pls

Link to comment
https://metin2.dev/topic/7579-infinite-arrows/#findComment-49190
Share on other sites

  • Former Staff

open "char_battle.cpp" from game folder in server source and search for

void CHARACTER::UseArrow(LPITEM pkArrow, DWORD dwArrowCount)

it'll be like this

void CHARACTER::UseArrow(LPITEM pkArrow, DWORD dwArrowCount)
{
    int iCount = pkArrow->GetCount();
    DWORD dwVnum = pkArrow->GetVnum();
    iCount = iCount - MIN(iCount, dwArrowCount);
    pkArrow->SetCount(iCount);

    if (iCount == 0)
    {
        LPITEM pkNewArrow = FindSpecifyItem(dwVnum);

        sys_log(0, "UseArrow : FindSpecifyItem %u %p", dwVnum, get_pointer(pkNewArrow));

        if (pkNewArrow)
            EquipItem(pkNewArrow);
    }
}

make it look like this

void CHARACTER::UseArrow(LPITEM pkArrow, DWORD dwArrowCount)
{
    int iCount = pkArrow->GetCount();
    DWORD dwVnum = pkArrow->GetVnum();
    if (iCount == 0)
    {
        LPITEM pkNewArrow = FindSpecifyItem(dwVnum);

        sys_log(0, "UseArrow : FindSpecifyItem %u %p", dwVnum, get_pointer(pkNewArrow));

        if (pkNewArrow)
            EquipItem(pkNewArrow);
    }
}

 

btw this :

    if (iCount == 0)
    {
        LPITEM pkNewArrow = FindSpecifyItem(dwVnum);

        sys_log(0, "UseArrow : FindSpecifyItem %u %p", dwVnum, get_pointer(pkNewArrow));

        if (pkNewArrow)
            EquipItem(pkNewArrow);
    }

is basicly mmmmmmm useless

yeah it/s useless but this is not useless

if (pkNewArrow)
            EquipItem(pkNewArrow);

it'll attach new group of arrows when the first count to 0 :) so it can be written like this

void CHARACTER::UseArrow(LPITEM pkArrow, DWORD dwArrowCount)
{
    int iCount = pkArrow->GetCount();
    DWORD dwVnum = pkArrow->GetVnum();
    LPITEM pkNewArrow = FindSpecifyItem(dwVnum);
    if (iCount == 0)
        if (pkNewArrow)
            EquipItem(pkNewArrow);
}

 

Link to comment
https://metin2.dev/topic/7579-infinite-arrows/#findComment-49197
Share on other sites

open "char_battle.cpp" from game folder in server source and search for

void CHARACTER::UseArrow(LPITEM pkArrow, DWORD dwArrowCount)

it'll be like this

void CHARACTER::UseArrow(LPITEM pkArrow, DWORD dwArrowCount)
{
    int iCount = pkArrow->GetCount();
    DWORD dwVnum = pkArrow->GetVnum();
    iCount = iCount - MIN(iCount, dwArrowCount);
    pkArrow->SetCount(iCount);

    if (iCount == 0)
    {
        LPITEM pkNewArrow = FindSpecifyItem(dwVnum);

        sys_log(0, "UseArrow : FindSpecifyItem %u %p", dwVnum, get_pointer(pkNewArrow));

        if (pkNewArrow)
            EquipItem(pkNewArrow);
    }
}

make it look like this

void CHARACTER::UseArrow(LPITEM pkArrow, DWORD dwArrowCount)
{
    int iCount = pkArrow->GetCount();
    DWORD dwVnum = pkArrow->GetVnum();
    if (iCount == 0)
    {
        LPITEM pkNewArrow = FindSpecifyItem(dwVnum);

        sys_log(0, "UseArrow : FindSpecifyItem %u %p", dwVnum, get_pointer(pkNewArrow));

        if (pkNewArrow)
            EquipItem(pkNewArrow);
    }
}

 

btw this :

    if (iCount == 0)
    {
        LPITEM pkNewArrow = FindSpecifyItem(dwVnum);

        sys_log(0, "UseArrow : FindSpecifyItem %u %p", dwVnum, get_pointer(pkNewArrow));

        if (pkNewArrow)
            EquipItem(pkNewArrow);
    }

is basicly mmmmmmm useless

yeah it/s useless but this is not useless

if (pkNewArrow)
            EquipItem(pkNewArrow);

it'll attach new group of arrows when the first count to 0 :) so it can be written like this

void CHARACTER::UseArrow(LPITEM pkArrow, DWORD dwArrowCount)
{
    int iCount = pkArrow->GetCount();
    DWORD dwVnum = pkArrow->GetVnum();
    LPITEM pkNewArrow = FindSpecifyItem(dwVnum);
    if (iCount == 0)
        if (pkNewArrow)
            EquipItem(pkNewArrow);
}

 

It is useless if you have a infinite arrow it will never end therefore you won't need EquipItem(pkNewArrow) because you will always have one.

Link to comment
https://metin2.dev/topic/7579-infinite-arrows/#findComment-49199
Share on other sites

  • Former Staff

OMG i'm soo stupid ... i forgot that this topic i about infinity arrows i just saw night's comment

so it can be written like this

void CHARACTER::UseArrow(LPITEM pkArrow, DWORD dwArrowCount)
{
	DWORD dwVnum = pkArrow->GetVnum();
}

 

Edited by flygun
Link to comment
https://metin2.dev/topic/7579-infinite-arrows/#findComment-49200
Share on other sites

void CHARACTER::UseArrow(LPITEM pkArrow, DWORD dwArrowCount)
{
    iCount = iCount - MIN(iCount, dwArrowCount);
  if (pkArrow->GetVnum() != 88005)
    pkArrow->SetCount(iCount);
  
    DWORD dwVnum = pkArrow->GetVnum();

int iCount = pkArrow->GetCount();

    if (iCount == 0)
    {
        LPITEM pkNewArrow = FindSpecifyItem(dwVnum);

        sys_log(0, "UseArrow : FindSpecifyItem %u %p", dwVnum, get_pointer(pkNewArrow));

        if (pkNewArrow)
            EquipItem(pkNewArrow);
    }
}

 

Edited by Rideas
Link to comment
https://metin2.dev/topic/7579-infinite-arrows/#findComment-49548
Share on other sites

Don't use any images from : imgur, turkmmop, freakgamers, inforge, hizliresim... Or your content will be deleted without notice...
Use : https://metin2.download/media/add/

Please use https://metin2.download/ when uploading files smaller than 100MB, otherwise the approval will take longer due to manual upload.

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
×
×
  • 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.