-
Posts
839 -
Joined
-
Days Won
393 -
Feedback
100%
Content Type
Forums
Store
Third Party - Providers Directory
Feature Plan
Release Notes
Docs
Events
Posts posted by xP3NG3Rx
-
-
-
-
Hey,
As I promised that I make a fix for the wolfmans pickaxe, and fishing rod holding, I'm here with it.
1.) Open GameLib\RaceData.h and find this:
void RegisterAttachingBoneName(DWORD dwPartIndex, const char * c_szBoneName);
Paste this below:
void ChangeAttachingBoneName(DWORD dwPartIndex, const char * c_szBoneName);
2. Open GameLib\RaceData.cpp and find this function:
void CRaceData::RegisterAttachingBoneName(DWORD dwPartIndex, const char * c_szBoneName) { m_AttachingBoneNameMap.insert(TAttachingBoneNameMap::value_type(dwPartIndex, c_szBoneName)); }
Than paste this function below:
void CRaceData::ChangeAttachingBoneName(DWORD dwPartIndex, const char * c_szBoneName) { TAttachingBoneNameMap::iterator it = m_AttachingBoneNameMap.find(dwPartIndex); if (it == m_AttachingBoneNameMap.end()) return; //m_AttachingBoneNameMap[dwPartIndex] = c_szBoneName; //bad behavior possiblity it->second = c_szBoneName; }
The following modification is may different by systems like costume weapon and so on, so I give a solution for clean version, you have to make it yourself.
3.) Open GameLib\ActorInstanceAttach.cpp and find this code(or something like that with other systems):void CActorInstance::AttachWeapon(DWORD dwItemIndex,DWORD dwParentPartIndex, DWORD dwPartIndex) { //[...] __DestroyWeaponTrace(); //ľçĽŐą«±â(ŔÚ°´ Ŕ̵µ·ů) żŢĽŐ,żŔ¸ĄĽŐ ¸đµÎżˇ ŔĺÂř. if (__IsRightHandWeapon(pItemData->GetWeaponType())) AttachWeapon(dwParentPartIndex, CRaceData::PART_WEAPON, pItemData); if (__IsLeftHandWeapon(pItemData->GetWeaponType())) AttachWeapon(dwParentPartIndex, CRaceData::PART_WEAPON_LEFT, pItemData);
and replace it with this:
void CActorInstance::AttachWeapon(DWORD dwItemIndex,DWORD dwParentPartIndex, DWORD dwPartIndex) { //[...] DWORD dwWeaponType = pItemData->GetWeaponType(); #ifdef ENABLE_WOLFMAN_CHARACTER if (m_eRace == CRaceData::RACE_WOLFMAN_M) { char* szAttachingBoneName = "equip_right_weapon"; if (dwWeaponType != CItemData::WEAPON_CLAW) szAttachingBoneName = "equip_right"; m_pkCurRaceData->ChangeAttachingBoneName(CRaceData::PART_WEAPON, szAttachingBoneName); } #endif __DestroyWeaponTrace(); if (__IsRightHandWeapon(dwWeaponType)) AttachWeapon(dwParentPartIndex, CRaceData::PART_WEAPON, pItemData); if (__IsLeftHandWeapon(dwWeaponType)) AttachWeapon(dwParentPartIndex, CRaceData::PART_WEAPON_LEFT, pItemData);
Done, build and enjoy.
P3NG3R.
- 1
- 15
-
With that modification the claws will be rotated also like the rod, and the pick axe.
As you can see on the 2nd picture.
- 1
-
Oh damn I understood already, I'm an idiot.
if ( *(_DWORD *)(v7 + 1244) == 8 ) // Dog { if ( CItemData::GetType(v26) == 28 ) v16 = CItemData::GetValue(v26, v15, 3u); else v16 = CItemData::GetWeaponType(v26); v18 = v16 == 8; v19 = (int)"equip_right_weapon"; if ( !v18 ) v19 = (int)"equip_right"; sub_59C530(*(_DWORD *)(v7 + 1280), v17, 0, edi0, 1, v19);// wtf is this (v7 + 1280 : ActorInstance::m_pkCurRaceData) UPDATE: change the attaching bonename }
I will fix this shit tommorow, thank you so much.
Now I'm uploading the whole actual decrypted GayForge client
- 1
-
mobdropinfo hah?
Get custom ideas and jump into grand canyon.
-
This and this, oh and brain.exe:
#[...] import item #[...] class SafeboxWindow(ui.ScriptWindow): #[...] def GetEmptyItemPos(self, itemHeight): #DaRealFreak is freak :o ;) inventory_size = player.INVENTORY_PAGE_SIZE * player.INVENTORY_PAGE_COUNT # function to return the blocked slots based on the item size GetBlockedSlots = lambda slot, size: [slot+(round*5) for round in xrange(size)] # check if an item in on the slot and get the blocked slots, in the end chain all of our lists together blocked_slots = [element for sublist in [GetBlockedSlots(slot, item.GetItemSize(item.SelectItem(player.GetItemIndex(slot)))[1]) for slot in xrange(inventory_size) if player.isItem(slot)] for element in sublist] # check is only necessary if our item size is > 1, else bigger performance loss in list comprehension if itemHeight > 1: # add the slots where f.e. size 2 items won't fit because of the 2-page-separated inventory [[blocked_slots.append(slot) for slot in range(inventory_size/round-(itemHeight-1)*5, inventory_size/round) if not slot in blocked_slots] for round in xrange(1,3)] # check for every slot if it's not in the blocked_slots list and check also for the size the lower slots free_slots = [slot for slot in xrange(inventory_size) if not slot in blocked_slots and not True in [e in blocked_slots for e in [slot+(round*5) for round in xrange(itemHeight)]]] # if our free_slot list is empty return -1 as error code, else return the first possible slot return [free_slots, -1][len(free_slots) == 0] def UseItemSlot(self, slotIndex): if mouseModule.mouseController.isAttached(): mouseModule.mouseController.DeattachObject() item.SelectItem(safebox.GetItemID(self.__LocalPosToGlobalPos(slotIndex))) (w, h) = item.GetItemSize() emptyInvenSlots = self.GetEmptyItemPos(h) if emptyInvenSlots == -1: return net.SendSafeboxCheckoutPacket(slotIndex, emptyInvenSlots[0]) #[...]
Edit: Tested, and works.
There is a little mistake, when you log into your account, and open safebox than "checkout" some items, those items will new items, I mean the slots will be activated, because of this:void CInputMain::SafeboxCheckout(LPCHARACTER ch, const char * c_pData, bool bMall) { //[...] pkSafebox->Remove(p->bSafePos); pkItem->SetLastOwnerPID(ch->GetPlayerID()); #fixme slothighlight pkItem->AddToCharacter(ch, p->ItemPos); ITEM_MANAGER::instance().FlushDelayedSave(pkItem); //[...] }
https://www.youtube.com/watch?v=k7oYpzP2tUc
For that you can put items into safebox by clicks you have to check that safebox is opened or not, and rewrite/modify the useslot function in uiInventory.py(InventoryWindow class)
- 1
- 1
- 8
-
Hahahah, no.
-
Because it store the option what you set and keep it the last option in every client start.
So if you disable it, and close the client itt will be disabled unti you don't enable it again an so on, better and sexier -
I'm blind, really.
What's the problem?
-
Do you know what are you talking about or I do not understand you?
The chenking of the flag of the block in python now, but if you put the checking into c++ is similar and faster a little bit(s)
I mean this:
if systemSetting.IsShowMoneyText() == True:
Same with this c++ code before the binary calls the python method:
CPythonSystem::Instance().IsShowMoneyText()
- 1
-
Thanks.
I think better way if the flag is active do not call the python method in game.py
PythonNetworkStreamPhaseGame.cpp
Replace this:if (POINT_GOLD == PointChange.Type) { if (PointChange.amount > 0) { PyCallClassMemberFunc(m_apoPhaseWnd[PHASE_WINDOW_GAME], "OnPickMoney", Py_BuildValue("(i)", (int)PointChange.amount)); } }
With this:
if (POINT_GOLD == PointChange.Type) { if (PointChange.amount > 0 && CPythonSystem::Instance().IsShowMoneyText()) { PyCallClassMemberFunc(m_apoPhaseWnd[PHASE_WINDOW_GAME], "OnPickMoney", Py_BuildValue("(i)", (int)PointChange.amount)); } }
-
Watafak are you talking about, txt-sql? xD
Anyway this system is a part of the full system.
SpoilerComing soon...
- 1
-
void CHARACTER::DetermineDropMetinStone() { if (g_bDisabledStoneDrop) { m_dwDropMetinStone = 0; return; } //.... }
The g_bDisabledStoneDrop is a configurable variable via CONFIG in config.h/.cpp
-
In the first version of this system had an ugly (+) mark(from v15.2, and deleted by v15.3) icon(/item/trade.tga) on every items which are not tradeable. The actual version(I mean this grayscale) came with v15.4. Btw I planned to release it, but I don't know yet.
- 1
- 4
-
1.-2. Complicate to explain it, but with one word: Affect
3. char_item.cpp > UseItemEx > ITEM_BLEND case
4. Google > "metin2 restart time c++"
- 2
-
-
That isn't image, c++ code.
if (IS_SET(rSlot.dwState, SLOT_STATE_UNUSABLE)) { CPythonGraphic::Instance().SetDiffuseColor(1.0f, 1.0f, 1.0f, 0.3f); CPythonGraphic::Instance().RenderBar2d(m_rect.left + rSlot.ixPosition, m_rect.top + rSlot.iyPosition, m_rect.left + rSlot.ixPosition + rSlot.byxPlacedItemSize * ITEM_WIDTH, m_rect.top + rSlot.iyPosition + rSlot.byyPlacedItemSize * ITEM_HEIGHT); }
- 3
-
I do not know what is this and why need this, but the code is ugly a little. And what those commented lines are?
If you release smthg do not put inside unnecessary codes.Here is a little code which is much sexier:
import app, chat szText = "banword" fHandle = app.OpenTextFile("locale/en/block_words_python.txt") if not fHandle: return False if szText in [app.GetTextFileLine(fHandle, i).strip() for i in xrange(app.GetTextFileLineCount(fHandle))] chat.AppendChat(chat.CHAT_TYPE_INFO, "[SYSTEM] Blocked words were introduced!") return
- 1
-
Wow, it's so cool idea, thank you!
- 2
-
Seems syntax error.
But what's the problem?
If you unequip the new weapon, the effect will not removed?
-
It's nice .
-
-
And what about with the header file?
Fix Wolfman Pickaxe and Fishing Rod
in Bug Fixes
Posted
So, you are saying that:
1. If we are wolfman. &&(aaand)
2. The attaching weapon type is sword!wtf! &&(and)
3. The attaching part is weapon. &&(aaaaand!)
4. Item type is rod or pickaxe.
Am I right?
I reversed my code from official binary, so do not tell me how should be working, you! who selling @martysama0134's source.
If anyone feel that to come and share their fix about this bug, why didn't come so far...? Shame.