Register for your free account! | Forgot your password?

You last visited: Today at 21:44

  • Please register to post and access all features, it's quick, easy and FREE!

Advertisement



__PMA_GW

Discussion on __PMA_GW within the Flyff Private Server forum part of the Flyff category.

Reply
 
Old   #1
 
elite*gold: 0
Join Date: May 2019
Posts: 74
Received Thanks: 5
__PMA_GW

I have added this system and, I did everything I can with my mid knowledge in c++ but I cannot get the thing to work how I want it..

Currently the TID_GAME_GUILDCOMBAT_START30 spams whenever the condition it is in is true. I have tried different ways to try and make it only get in that condition once but my knowledge is still incapable.. I want to ask some help from you guys thank you so much.. I will just write down the original piece as to how it was written when released as my edits doesn't work.

Code:
CTime ctime = CTime::GetCurrentTime();

#ifdef __PMA_GW
		for (DWORD i = 0; i < __AutoOpen.size(); i++)
		{
			if (__AutoOpen[i].nDay == ctime.GetDayOfWeek() - 1 && __AutoOpen[i].bUseing)
			{
				CTimeSpan ts(0, __AutoOpen[i].nHour - ctime.GetHour(), __AutoOpen[i].nMinute - ctime.GetMinute(), 0);

				if (ts.GetTotalSeconds() == GW_TIME_ANNOUNCE * 60) 
					g_DPCoreClient.SendSystem(prj.GetText(TID_GAME_GUILDCOMBAT_START30)); // This is being spammed in the game 30 minutes before GS will start.

				if (__AutoOpen[i].nHour == ctime.GetHour() &&
					__AutoOpen[i].nMinute == ctime.GetMinute() && m_bMutex == FALSE)
#else
		if (__AutoOpen[ctime.GetDayOfWeek() - 1].bUseing)
		{
			// ½ºÅµ µÉ ¼ö ÀÖÀ¸¹Ç·Î ¼öÁ¤À» ÇÊ¿ä·Î ÇÔ
			if (__AutoOpen[ctime.GetDayOfWeek() - 1].nHour == ctime.GetHour() &&
				__AutoOpen[ctime.GetDayOfWeek() - 1].nMinute == ctime.GetMinute() && m_bMutex == FALSE)
#endif
				{
#ifdef __S_BUG_GC
					if( (int)( m_vecGuildCombatMem.size() ) >= m_nMinGuild )
#else // __S_BUG_GC
				if( m_GuildCombatMem.size() > 1 )
#endif // __S_BUG_GC
					{				
						GuildCombatOpen();
					}
					else
					{
						m_ctrMutexOut.Set( SEC(60) );
						m_bMutexMsg = TRUE;
						g_DPCoreClient.SendSystem( prj.GetText( TID_GAME_GUILDCOMBAT_NEXT_COMBAT ) );	
						g_DPCoreClient.SendSystem( prj.GetText( TID_GAME_GUILDCOMBAT_ENJOY ) );	
					}

					m_bMutex = TRUE;				
				}

				if( m_bMutexMsg && m_ctrMutexOut.IsTimeOut() )
				{
					m_bMutexMsg = FALSE;
					m_bMutex    = FALSE;
				}
			}
		}
#ifdef __PMA_GW
	}
#endif
#endif //__WORLDSERVER
Fatcode is offline  
Old 06/08/2019, 20:06   #2
 
Rhyder`'s Avatar
 
elite*gold: 115
Join Date: Jan 2012
Posts: 1,156
Received Thanks: 894


never tried but i think this will work!
Rhyder` is offline  
Thanks
1 User
Old 06/10/2019, 12:33   #3
 
elite*gold: 0
Join Date: May 2019
Posts: 74
Received Thanks: 5
Quote:
Originally Posted by Rhyder` View Post


never tried but i think this will work!
Hey! Thank you so much for this. I will definitely try this out. Thank you so much!
Fatcode is offline  
Old 06/12/2019, 00:15   #4
 
elite*gold: 0
Join Date: May 2019
Posts: 74
Received Thanks: 5
--
So here is an update.. the thing did not work with seconds as the loop was really fast and the seconds was not. What I did is made it milliseconds to make sure it is really not same when doing conditions. Thanks!
Fatcode is offline  
Reply




All times are GMT +1. The time now is 21:44.


Powered by vBulletin®
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
SEO by vBSEO ©2011, Crawlability, Inc.
This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

Support | Contact Us | FAQ | Advertising | Privacy Policy | Terms of Service | Abuse
Copyright ©2024 elitepvpers All Rights Reserved.