Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // IN MoverAttack.cpp there are 2 functions to change
- int CMover::GetMagicHitPower( int nChargeLevel )
- {
- ItemProp* pItemProp = GetActiveHandItemProp(); // µé°íÀÖ´Â ¹«±âÀÇ ÇÁ·ÎÆÛƼ ²¨³¿
- CItemElem *pWeapon = GetWeaponItem(); // ¼Õ¿¡µç ¾ÆÀÌÅÛÀÇ Æ÷ÀÎÅÍ.
- int nMin, nMax;
- GetItemATKPower( &nMin, &nMax, pItemProp, pWeapon );
- int nATK = GetWeaponATK( WT_MAGIC_WAND );
- nMin += nATK;
- nMax += nATK;
- int nDamage = xRandom( nMin, nMax );
- nDamage += GetParam( DST_CHR_DMG, 0 );
- nDamage = (int)( nDamage * 1 );
- return nDamage;
- }
- // AND THIS
- int CMover::ApplyDPC( int nATK, ATTACK_INFO* pInfo )
- {
- int nDamage;
- if( pInfo->CanIgnoreDEF() )
- nDamage = nATK;
- else
- {
- int nDefense = CalcDefense( pInfo );
- nDamage = nATK - nDefense;
- }
- if( nDamage < 0 )
- nDamage = 0;
- if( nDamage >= 500000 ) // Set your desired Maximum Damage
- nDamage = 500000 ;
- // 크리티컬 처리.
- if( pInfo->pAttacker->IsCriticalAttack( this, pInfo->dwAtkFlags ) )
- {
- pInfo->dwAtkFlags |= AF_CRITICAL;
- int nChargeLevel = pInfo->GetChargeLevel(); // 완드충전량
- if( nChargeLevel > 0 )
- nChargeLevel = 0;
- if( (pInfo->pAttacker->m_pActMover->GetState() & OBJSTA_ATK4) ||
- nChargeLevel == MAX_CHARGE_LEVEL ) // 4패턴공격에 발생한 크리티컬.
- {
- nDamage = (int)(nDamage * 1.0f);
- if( CanFlyByAttack() && xRandom(100) < 90 )
- pInfo->dwAtkFlags |= AF_FLYING;
- }
- else
- {
- nDamage = (int)(nDamage * 1.0f);
- if( CanFlyByAttack() && xRandom(100) < 80 )
- pInfo->dwAtkFlags |= AF_FLYING;
- }
- float fCriticalBonus = 1 + (float)GetParam( DST_CRITICAL_BONUS, 0 ) / 100.0F;
- #ifdef __JEFF_11
- if( fCriticalBonus < 0.1F )
- fCriticalBonus = 0.1F;
- #endif // __JEFF_11
- nDamage = (int)( nDamage * fCriticalBonus );
- }
- return nDamage;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement