Exemplo n.º 1
0
    // Token: 0x0600009B RID: 155 RVA: 0x00008620 File Offset: 0x00006820
    private static void GmEnemyDefaultDefFunc(AppMain.OBS_RECT_WORK mine_rect, AppMain.OBS_RECT_WORK match_rect)
    {
        AppMain.GMS_ENEMY_COM_WORK gms_ENEMY_COM_WORK = (AppMain.GMS_ENEMY_COM_WORK)mine_rect.parent_obj;
        GMS_PLAYER_WORK            gms_PLAYER_WORK    = null;

        if (match_rect.parent_obj != null && match_rect.parent_obj.obj_type == 1)
        {
            gms_PLAYER_WORK = (GMS_PLAYER_WORK)match_rect.parent_obj;
        }

        if (gms_ENEMY_COM_WORK.vit == 0)
        {
            if ((gms_ENEMY_COM_WORK.obj_work.move_flag & 4096U) == 0U || gms_ENEMY_COM_WORK.obj_work.obj_type == 3)
            {
                gms_ENEMY_COM_WORK.enemy_flag |= 65536U;
            }

            gms_ENEMY_COM_WORK.obj_work.flag     |= 2U;
            gms_ENEMY_COM_WORK.rect_work[0].flag |= 2048U;
            gms_ENEMY_COM_WORK.rect_work[1].flag |= 2048U;
            gms_ENEMY_COM_WORK.rect_work[2].flag |= 2048U;
            if (gms_ENEMY_COM_WORK.obj_work.obj_type == 2)
            {
                GmSound.PlaySE("Enemy");
                AppMain.GmComEfctCreateHitPlayer(gms_ENEMY_COM_WORK.obj_work,
                                                 (int)((mine_rect.rect.left + mine_rect.rect.right) * 4096 / 2),
                                                 (int)((mine_rect.rect.top + mine_rect.rect.bottom) * 4096 / 2));
                AppMain.GmComEfctCreateEneDeadSmoke(gms_ENEMY_COM_WORK.obj_work,
                                                    (int)((mine_rect.rect.left + mine_rect.rect.right) * 4096 / 2),
                                                    (int)((mine_rect.rect.top + mine_rect.rect.bottom) * 4096 / 2));
                AppMain.GmGmkAnimalInit(gms_ENEMY_COM_WORK.obj_work, 0, 0, 0, 0, 0, 0);
                AppMain.GMM_PAD_VIB_SMALL();
                if (gms_PLAYER_WORK != null)
                {
                    GmPlayer.ComboScore(gms_PLAYER_WORK, gms_ENEMY_COM_WORK.obj_work.pos.x,
                                        gms_ENEMY_COM_WORK.obj_work.pos.y + -65536);
                }

                AppMain.HgTrophyIncEnemyKillCount(gms_ENEMY_COM_WORK.obj_work);
            }

            gms_ENEMY_COM_WORK.obj_work.flag |= 8U;
        }
        else
        {
            AppMain.GMS_ENEMY_COM_WORK gms_ENEMY_COM_WORK2 = gms_ENEMY_COM_WORK;
            gms_ENEMY_COM_WORK2.vit -= 1;
            byte[] byte_param = gms_ENEMY_COM_WORK.eve_rec.byte_param;
            int    num        = 1;
            byte_param[num] += 1;
            gms_ENEMY_COM_WORK.invincible_timer       = 245760;
            gms_ENEMY_COM_WORK.rect_work[1].hit_power = 0;
        }

        if (gms_PLAYER_WORK != null && gms_PLAYER_WORK.obj_work.obj_type == 1)
        {
            AppMain.GmPlySeqAtkReactionInit(gms_PLAYER_WORK);
        }
    }