-
Posts
64 -
Joined
-
Last visited
-
Feedback
0%
Content Type
Forums
Store
Third Party - Providers Directory
Feature Plan
Release Notes
Docs
Events
Posts posted by m2Ciaran
-
-
Still looking around, the problem is flying manager - shooting invisible instance
-
Hello. Im looking for someone who can code ninja with bow shooting 3 targets at once. (obv paid) PM
-
-
-
Look for bAnotherWindow in pythonapplication
-
-
4 hours ago, MysteriousDev said:
I got interested in this topic so I tried it myself. What I've found you can pretty easily enable antialiasing on dx9.
Search for:
int CGraphicDevice::Create
Now scroll down where the parameters of ms_d3dPresentParameter are set.
Add those two lines
ms_d3dPresentParameter.MultiSampleType = D3DMULTISAMPLE_8_SAMPLES; ms_d3dPresentParameter.MultiSampleQuality = 0;
And now that's a riddle. I haven't got too much time for a research, but ms_lpd3d->CheckDeviceMultiSampleType tells that multiSampling is indeed available, and it sets the quality to 1. But I can't get it working with it, so I left the quality set to 0, it still looks good enough, IDK what would be the difference.
Also there's one more thing to set in the parameters, and I don't know the long term effects of this change, but it looks like it works just fine, like I said I don't have too much time for doing research atm.
You'll be having a "D3DERR_INVALIDCALL" error if ms_d3dPresentParameter.Flags are set to D3DPRESENTFLAG_LOCKABLE_BACKBUFFER, and I don't know the answer for now, maybe I'm missing something, but setting the flag to 0 does the job.
After the device is created with success you must write last line to make it work:
ms_lpd3dDevice->SetRenderState(D3DRS_MULTISAMPLEANTIALIAS, TRUE);
And now you can enjoy those SMOOTH EDGES:
You just don't use the backbuffer with anti aliasing. With that said, the old screenshot method will not work, but this one might work:
bool CPythonGraphic::SaveScreenShot(const char * c_pszFileName) { LPDIRECT3DSURFACE9 lpSurface; D3DSURFACE_DESC stSurfaceDesc; uint32_t uWidth = stSurfaceDesc.Width; uint32_t uHeight = stSurfaceDesc.Height; ms_lpd3dDevice->CreateOffscreenPlainSurface(uWidth, uHeight, D3DFMT_A8R8G8B8, D3DPOOL_SYSTEMMEM, &lpSurface, NULL); if(SUCCEEDED(ms_lpd3dDevice->GetBackBuffer(0, 0, D3DBACKBUFFER_TYPE_MONO, &lpSurface))) { D3DXSaveSurfaceToFile(c_pszFileName, D3DXIFF_JPG, lpSurface, NULL, NULL); } if(lpSurface) { lpSurface->Release(); lpSurface = nullptr; } return true; }
If I remember correctly there is also problem with transparency in e.g. tooltip but i dont go deep into it. Its cool for us, but players dont give a fuck about edges so... i just don't work on it
-
1
-
-
On 11/22/2023 at 7:10 AM, Fenczu said:
Everything works after adding but when I change the character it resets the skils what could I have done wrong?
Change to array size might be required if you use any additional system related with skill table or 64bit files or or or...
db src-> static char text[4096 + 1]
-
Really sad to hear you have such a problem guys. Recently, I have installed the code in 40250 base by @ TMP4 and everything is fine. My bet is that you use some additional system, which require modification
If its possible you can show me the edited files in PM I'll take a look.
-
18 minutes ago, FrozenShower said:
1118 23:12:26178 ::
game.py(line:260) Open
game.py(line:771) StartGame
game.py(line:929) RefreshCharacter
interfaceModule.py(line:830) RefreshCharacter
uiCharacter.py(line:1235) RefreshCharacter
uiCharacter.py(line:1282) __SetSkillSlotData
uiCharacter.py(line:983) RefreshSkill
uiCharacter.py(line:959) __RefreshSkillPageGameWindow.Open - <type 'exceptions.RuntimeError'>:skill.GetSkillType - Failed to find skill by 119
1118 23:12:26179 :: ============================================================================================================
1118 23:12:26179 :: Abort!!!!
119 skill?I assume the error you posted is not related with this qol code (I work on clean files I don't know what code you have)
-
9 minutes ago, Filachilla said:
I dont know if I do something wrong, but it works only for M1-M9 (M10 and more doesnt show anything)
Edit: So its only for books? If yes, it would by nice when M10 to G1 is too showed and not only M1-M9Yes only for books and that is right, I forget about the "master" level.. crazy things. Dl is updated once again
Just move the uitooltip if like that to make it work with m10 (master):
if skillLevel > 0: if self.HasSkillLevelDescription(skillIndex, skillLevel): self.AppendSpace(5) if skillGrade == skill.SKILL_GRADE_COUNT: pass elif skillLevel == skillMaxLevelEnd: self.AppendTextLine(localeInfo.TOOLTIP_SKILL_LEVEL_MASTER % (skillLevel), self.NORMAL_COLOR) else: self.AppendTextLine(localeInfo.TOOLTIP_SKILL_LEVEL % (skillLevel), self.NORMAL_COLOR) if app.ENABLE_SKILL_DESCRIPTION_RENEWAL: if skillGrade == 1: if self.HasSkillLevelDescription(skillIndex, skillLevel): self.AppendTextLine(localeInfo.TOOLTIP_SKILL_BOOKS % (player.GetRemainingBooks(slotIndex), need_bookcount), 0xff375cd4) self.AppendSkillLevelDescriptionNew(skillIndex, skillCurrentPercentage, self.ENABLE_COLOR)
-
1
-
-
2 hours ago, SCOOB said:
There is a problem. if you level up a skill from m3 -> m4 for example, the needed books don't reset to 0, only after teleport or reading another book.
https://metin2.download/video/nrUlvyuL2Z5D3VZr3gSp2wA20z0hUjQg/.mp4
How to fix?
I have updated the file, you should change char_skill.cpp
First search
pPC->SetFlag(flag, 0);
And remove
SkillLevelUp(dwSkillVnum, SKILL_UP_BY_BOOK);
Now change this This
#ifdef ENABLE_SKILL_DESCRIPTION_RENEWAL m_pSkillLevels[dwSkillVnum].bBooks = 0; #else pPC->SetFlag(flag, 0); #endif
To this:
#ifdef ENABLE_SKILL_DESCRIPTION_RENEWAL m_pSkillLevels[dwSkillVnum].bBooks = 0; SkillLevelUp(dwSkillVnum, SKILL_UP_BY_BOOK); #else SkillLevelUp(dwSkillVnum, SKILL_UP_BY_BOOK); pPC->SetFlag(flag, 0); #endif
-
-
You don't have chrmgr module. Probably name of the module has changed in binary src (yy mm you should know)
-
1
-
-
20 hours ago, BadRomani said:
Rar password?
-
1
-
-
Looks nice and neat, good work
-
26 minutes ago, Nicely2 said:
up help me please.
hmmm
On 12/19/2019 at 3:05 PM, Syreldar said:Did you seriously just bump a 5 years old topic for this? Holy cow.
It doesn't find the column text inside the string table. Add it. That's all.
-
Search for python module via pkg search mysql and install it
-
Build game with -static-libstdc++ flag
-
Looks like I got similar results. Kinda nice, also look good on weapons for example
before
after
Spoiler
-
27 minutes ago, mihnea said:
and how is the killer decided?
Last hit is the killer, but the item drop is divided by damage dealt
You can see it in char_battle.cpp Reward functionint iItemIdx = s_vec_item.size() - 1; std::priority_queue<std::pair<int, LPCHARACTER> > pq; int total_dam = 0; for (TDamageMap::iterator it = m_map_kDamage.begin(); it != m_map_kDamage.end(); ++it) { int iDamage = it->second.iTotalDamage; if (iDamage > 0) { LPCHARACTER ch = CHARACTER_MANAGER::instance().Find(it->first); if (ch) { pq.push(std::make_pair(iDamage, ch)); total_dam += iDamage; } } } std::vector<LPCHARACTER> v; while (!pq.empty() && pq.top().first * 10 >= total_dam) { v.push_back(pq.top().second); pq.pop(); } if (v.empty()) { // 데미지를 특별히 많이 준 사람이 없으니 소유권 없음 while (iItemIdx >= 0) { item = s_vec_item[iItemIdx--]; if (!item) { sys_err("item null in vector idx %d", iItemIdx + 1); continue; } item->AddToGround(GetMapIndex(), pos); // 10% 이하 데미지 준 사람끼리는 소유권없음 //item->SetOwnership(pkAttacker); item->StartDestroyEvent(); pos.x = number(-7, 7) * 20; pos.y = number(-7, 7) * 20; pos.x += GetX(); pos.y += GetY(); sys_log(0, "DROP_ITEM: %s %d %d by %s", item->GetName(), pos.x, pos.y, GetName()); } } else { // 데미지 많이 준 사람들 끼리만 소유권 나눠가짐 std::vector<LPCHARACTER>::iterator it = v.begin(); while (iItemIdx >= 0) { item = s_vec_item[iItemIdx--]; if (!item) { sys_err("item null in vector idx %d", iItemIdx + 1); continue; } item->AddToGround(GetMapIndex(), pos); LPCHARACTER ch = *it; if (ch->GetParty()) ch = ch->GetParty()->GetNextOwnership(ch, GetX(), GetY()); ++it; if (it == v.end()) it = v.begin(); if (CBattleArena::instance().IsBattleArenaMap(ch->GetMapIndex()) == false) { item->SetOwnership(ch); } item->StartDestroyEvent(); pos.x = number(-7, 7) * 20; pos.y = number(-7, 7) * 20; pos.x += GetX(); pos.y += GetY(); sys_log(0, "DROP_ITEM: %s %d %d by %s", item->GetName(), pos.x, pos.y, GetName()); }
As you can see in this function SetOwnership is used when dealt at least 10% damage but this does not apply to gold reward the gold is reward for the killer. Worth to note that the chance for item drop is calculated for killer only:
if (ITEM_MANAGER::Instance().CreateDropItem(this, pkAttacker, s_vec_item))
This means that only killer thief gloves are counted
Im not sure this is the official clean code because I took it from random github but looks like. Have a nice day
-
1
-
-
Yes it does not work in party. Only killer is counted
-
In solution explorer on your right click right mouse button on your solution->Properties->Startup Project->Single startup project and choose UserInterface
-
14 hours ago, SCOOB said:
it causes bugs with Switchbot System. You can't place items in switchbot from inventory.
if (Cell.cell == DestCell.cell && SWITCHBOT != Cell.window_type && SWITCHBOT != DestCell.window_type) return false;
-
2
-
Official Abort Traceback Update [REVERSED]
in Programming & Scripts
Posted
But the whole code is available in topic