-
Posts
270 -
Joined
-
Last visited
-
Days Won
38 -
Feedback
100%
Content Type
Forums
Store
Feature Plan
Release Notes
Docs
Events
Everything posted by Distraught
-
(In Dev) Metin2 Project - Legacy of Metin2
Distraught replied to Geoffrey's topic in Basic Tutorials / Beginners
Hm, nice job! ? -
V1.4: Texture paths are changed from D:\ymir work[...] to just simply ymir work\[...] when exporting to fbx or 3ds [Hidden Content]
- 31 replies
-
- 78
-
-
-
-
-
-
-
-
Asset Loading from Network at run-time
Distraught replied to Distraught's topic in Programming & Scripts
If you actually just copy+pasted that code then you just need to use "oimg" extension anywhere you would use images. -
Server package optimization ComputePoints
Distraught replied to CMOD's topic in Programming & Scripts
Was it ever a bottleneck anyway? -
Hey guys! We plan to open a Romanian server too so that we are looking for a community manager and translator for Land of Heroes RO. You can check out our Hungarian server at https://landofheroes.hu For the translator: We have every localization in one xls file, so it's going to be easy technically. You can apply in a private message.
-
Miley Cyrus - Angels Like You Miley Cyrus - Zombie
-
Hey guys, Most of you noticed if you have a special character like á, é, ő, etc. at the beginning or end of a string qc will not work and displays no error message. It is because it throws an error but in it's own way by pushing a string to the top of the lua stack and calling exit so you can't catch it normally. Here is a method how you can make these messages visible. Actually we only have to write a few lines. Open qc.cc and add this function void print_exception() { int top = lua_gettop(L); if (0 != top && LUA_TSTRING == lua_type(L, top)) { std::cerr << lua_tostring(L, top); } } Now go to the main function and add this line to the beginning of it: atexit(&print_exception); So it should look like this: Now you will see the exceptions like Good luck guys and hope you like it!
-
UPDATE: no need to set map size, now you just have to select the directory of the map and it will read the minimap and it's settings automatically Link is the same but here it is again: [Hidden Content] @ASIKOO can you please update the download center too?
- 26 replies
-
- 19
-
-
-
-
As it's a dotnet application, it's about a few clicks to reflect, but I have no intentions releasing it or I would of uploaded them.
-
I suggest putting the includes in Area.cpp because those classes are only used there. If you can I suggest avoiding includes in headers because that makes the compilation much slower. You only have to include a header if you want to instantiate a class there or use any of its member variables or functions (or you want to know the size of it); otherwise you can predeclare the class (eg. if you just wanna have pointers to it or references) like class ClassName;.
-
I don't know where you did that but I'm quite sure they are both defined as unsigned char so yes.
-
For me they are after other includes but as @Gurgarath and @Syreldar said it should work the way they said. What platform toolset are you using? I'm not sure about this but maybe that could possible cause this.
-
UPDATE: you can now delete by right click radius is shown around your mouse pointer Download updated, but here's the link again: [Hidden Content] @ASIKOO can you please update it in the Download Center too?
- 26 replies
-
- 21
-
-
-
-
-
In that case this would be the smallest problem. But just for the code design we can fairly afford to skip updating the effects in that frame. I edited the code.
-
Our mapper made a map with really-really a lot of effects on it. Some of our testers mentioned that the game started to lag for them on that map so much. I checked it in debug mode and actually the FPS dropped to actually 0. I started to profile the game what could be the bottleneck and so that I found the effects. When the game is dealing with effects for maps most of the time went in CMapOutdoor::RenderEffect. In this function it calls RenderEffects for each Area around you (that is 9 normally if you're not on some edge area). In the Area's render effect somewhy they did the effect update (but why?) and that took the most of time. We didn't wanna make the map less beautiful so I fixed it in the code. Now the game only updates and renders effects that are around your character and are not in the fog zone. With this we brought back our FPS to normal and we can have maps with a lot of effects too. First, open EffectLib/EffectInstance.h and add this to CEffectInstance class: const D3DXMATRIX& GetGlobalMatrix() const { return m_matGlobal; }; Now go to GameLib/Area.cpp and add these to the includes #include "../UserInterface/StdAfx.h" #include "../UserInterface/PythonCharacterManager.h" #include "../UserInterface/PythonBackground.h" Now modify CArea::__UpdateEffectList function to look like this void CArea::__UpdateEffectList() { int peNum; float pfStart, pfEnd, pfFarClip; D3DXVECTOR3 chrPos; CPythonBackground::instance().GetDistanceSetInfo(&peNum, &pfStart, &pfEnd, &pfFarClip); CInstanceBase* pInst = CPythonCharacterManager::instance().GetMainInstancePtr(); if (!pInst) return; chrPos = pInst->GetGraphicThingInstanceRef().GetPosition(); CEffectManager& rkEftMgr=CEffectManager::Instance(); TEffectInstanceIterator i; for (i = m_EffectInstanceMap.begin(); i != m_EffectInstanceMap.end();) { CEffectInstance * pEffectInstance = i->second; const D3DMATRIX& gMatrix = pEffectInstance->GetGlobalMatrix(); if (pfStart < GetPixelPositionDistance(chrPos, TPixelPosition(gMatrix._41, gMatrix._42, gMatrix._43))) { pEffectInstance->Hide(); ++i; continue; } pEffectInstance->Show(); pEffectInstance->Update(); if (!pEffectInstance->isAlive()) { i = m_EffectInstanceMap.erase(i); rkEftMgr.DestroyUnsafeEffectInstance(pEffectInstance); } else { ++i; } } } Hope you guys like it and will be useful! ?
- 20 replies
-
- 48
-
-
-
-
-
How can i talk to a NPC via Python?
Distraught replied to OnlyGood's topic in Community Support - Questions & Answers
CPythonCharacterManager has functions like CharacterInstanceBegin and CharacterInstanceEnd so you can iterate over the characters nearby like: TPixelPosition myPos; CPythonPlayer::instance().NEW_GetMainActorPosition(&myPos); CPythonCharacterManager& chrMgr = CPythonCharacterManager::instance(); for (auto it = chrMgr.CharacterInstanceBegin(); it != chrMgr.CharacterInstanceEnd(); ++it) { if (CInstanceBase* ch = *it) { TPixelPosition otherPos; ch->NEW_GetPixelPosition(&otherPos); if(GetPixelPositionDistance(myPos, otherPos) <= SOME DISTANCE && some other thing to identify your npc) { CPythonNetworkStream::Instance().SendOnClickPacket(ch->GetVirtualID()); } } }- 1 reply
-
- 1
-
-
Compile your game with -g flag for debug smybols and with -O0 flag for disabling optimizations so that you can properly debug your core dump. We can only help after that.
-
There's a bug in the game if you have like an NPC and you set its opacity to less then 1.0 and attach effects to it and the effects are inside the model. The effect will not be rendered because the effect rendering is after character rendering so when it's stenciling it, it won't know what should be seen behind the model. To fix this we just have to pre-render the effects in this case. To achieve this add this code to the beginning of CActorInstance::OnRender if (GetAlphaValue() < 1.0f) { for (auto it = m_AttachingEffectList.begin(); it != m_AttachingEffectList.end(); ++it) { CEffectManager::Instance().SelectEffectInstance(it->dwEffectIndex); CEffectManager::Instance().RenderEffect(); } } and add a new method to CEffectManager in EffectLib/EffectManager.h: void RenderEffect(); and for sure define it in EffectManager.cpp void CEffectManager::RenderEffect() { if (!m_pSelectedEffectInstance) return; m_pSelectedEffectInstance->Render(); } Now you can create eg. mounts with effects like this: Hope you like it and will be useful!
-
@LastSamurai23 help me a lot and recreated the model for me. Here's the result of our work The idea is from this video:
-
in that case does anyone have this mount?
-
I tried Skype but he aint responded.
-
Hey guys, Someone knows any contact to Keyto? I would like to buy from his webshop but cannot reach on the contacts specified on the site.
-
Because it was so long ago I recreated this program for using at my server but I share it here too. It has some more options that I looked up from the server sources, you can zoom in or out and it distinguishes different mobs/groups/etc with different colors + you can load existing regen files and edit them too. Link and image updated in the original post.
