綁定帳號登入

Android 台灣中文網

打印 上一主題 下一主題

[修改] 不死改檔

[複製連結] 查看: 5280|回覆: 33|好評: 3
跳轉到指定樓層
樓主
y0800243 | 收聽TA | 只看該作者 回帖獎勵 |倒序瀏覽 |閱讀模式
發表於 2014-4-4 17:50

馬上加入Android 台灣中文網,立即免費下載應用遊戲。

您需要 登錄 才可以下載或查看,沒有帳號?註冊

x
本帖最後由 y0800243 於 2014-4-4 17:55 編輯

Public Sub ApplyEffectToPlayer(ByVal magnitude As Single, ByVal Optional forceHeal As Boolean = False)




        If (PlayerData.mCurrentHP > 0!) Then
            Dim flag As Boolean = True        
            SkillInstance.AlterPlayerHPEvent(magnitude, forceHeal)
            If (magnitude >= 0!) Then
                If (magnitude < RestoreGameplay.minRecoverHP) Then
                    RestoreGameplay.minRecoverHP = magnitude
                End If
                If (magnitude > RestoreGameplay.maxRecoverHP) Then
                    RestoreGameplay.maxRecoverHP = magnitude
                End If
                RestoreGameplay.totalRecoverHP = (RestoreGameplay.totalRecoverHP + magnitude)
                If ((PlayerData.mCurrentHP < PlayerData.mMaxHP) AndAlso (magnitude > 0!)) Then
                    Me.recoverDisplayTime += 1
                    Me.HpERcoverEffectPlay
                    AudioController.sfx.Play(Sound1.instance.hpRecover)
                End If
            ElseIf (magnitude < 0!) Then
                If (((Labyrinth.protectedData.currentBattleZoneIndex = Labyrinth.protectedData.totalBattleZone) AndAlso (PlayerData.mCurrentHP > (PlayerData.mMaxHP * 0.5!))) AndAlso ((PlayerData.mCurrentHP + magnitude) < (PlayerData.mMaxHP * 0.1!))) Then
                    LabyrinthCamera.parent.animation.Play
                End If
                Dim num As Integer = CInt(-magnitude)
                RestoreGameplay.totalDamageTaken = (RestoreGameplay.totalDamageTaken + num)
                If (num > RestoreGameplay.maxDamageTaken) Then
                    RestoreGameplay.maxDamageTaken = num
                End If
                If (num < RestoreGameplay.minDamageTaken) Then
                    RestoreGameplay.minDamageTaken = num
                End If
                If (num > RestoreGameplay.maxDamageTakenPerWave(RestoreGameplay.protectedData.currentWaveIndex1)) Then
                    RestoreGameplay.maxDamageTakenPerWave(RestoreGameplay.protectedData.currentWaveIndex1) = num
                End If
                AudioController.sfx.Play(Sound1.instance.skill_retribute)
            End If
            PlayerData.mCurrentHP = (PlayerData.mCurrentHP + magnitude)
            If (PlayerData.mCurrentHP > PlayerData.mMaxHP) Then
                PlayerData.mCurrentHP = PlayerData.mMaxHP
            End If
            If (PlayerData.mCurrentHP <= 0!) Then
                If flag Then
                    PlayerData.mCurrentHP = 1!
                Else
                    PlayerData.mCurrentHP = 0!
                    CoroutineControl.instance.StartCoroutine(Me.GameOver)
                    MyBase.enabled = False
                End If
            ElseIf (PlayerData.mCurrentHP <= 1!) Then
                PlayerData.mCurrentHP = 1!
            End If
            If (PlayerData.mCurrentHP < RestoreGameplay.minHP) Then
                RestoreGameplay.minHP = PlayerData.mCurrentHP
            End If
            If (PlayerData.mCurrentHP < RestoreGameplay.minPlayerHPPerWave(RestoreGameplay.protectedData.currentWaveIndex1)) Then
                RestoreGameplay.minPlayerHPPerWave(RestoreGameplay.protectedData.currentWaveIndex1) = PlayerData.mCurrentHP
            End If
            If (PlayerData.mCurrentHP > 0!) Then
                Labyrinth.newHPBar.ChangeTo(If(((PlayerData.mCurrentHP / PlayerData.mMaxHP) >= 0.01!), (PlayerData.mCurrentHP / PlayerData.mMaxHP), 0.01!), 0.4!)
            Else
                Labyrinth.newHPBar.ChangeTo(0!, 0.4!)
            End If
            If (Not Labyrinth.playerHP_JText Is Nothing) Then
                Labyrinth.playerHP_JText.text = (CInt(PlayerData.mCurrentHP) & "/" & CInt(PlayerData.mMaxHP))
            End If
            If (PlayerData.mCurrentHP > (PlayerData.mMaxHP * 0.2!)) Then
                Labyrinth.playerHP_JText_Ani.endBehaviour
                Labyrinth.playerHP_JText.myR.material.color = New Color(1!, 1!, 1!, 1!)
            Else
                Dim colors As Color() = New Color() { New Color(1!, 1!, 1!, 1!), New Color(1!, 0.3!, 0.3!, 1!), New Color(1!, 1!, 1!, 1!) }
                Labyrinth.playerHP_JText_Ani.init(colors, 0.5!, CurveMode.linear, -1!, AniEndAction.disableScript, Nothing, 0)
            End If
            Labyrinth.CalculateDisplayKiller
        End If
    End Sub
「用Android 就來APK.TW」,快來加入粉絲吧!
Android 台灣中文網(APK.TW)

評分

參與人數 5碎鑽 +3 幫助 +4 收起 理由
seadog007 + 1 有個東西較flag
原住明 + 1 其實根本不用改這邊
moon1996 + 1 官方又要改版了= =
thilendy + 1 + 1 非常讚
68520dodo + 1 + 1 非常讚

查看全部評分

收藏收藏6 分享分享 分享專題
用Android 就來Android 台灣中文網(https://apk.tw)
回覆

使用道具 舉報

沙發
skywingyick | 收聽TA | 只看該作者
發表於 2014-4-4 17:51
此帖僅作者可見
用Android 就來Android 台灣中文網(https://apk.tw)

使用道具 舉報

板凳
wsx26985 | 收聽TA | 只看該作者
發表於 2014-4-4 17:52
此帖僅作者可見
用Android 就來Android 台灣中文網(https://apk.tw)

使用道具 舉報

地板
playboy0936 | 收聽TA | 只看該作者
發表於 2014-4-4 18:02
此帖僅作者可見
用Android 就來Android 台灣中文網(https://apk.tw)

使用道具 舉報

5
fan198947 | 收聽TA | 只看該作者
發表於 2014-4-4 18:04
此帖僅作者可見
用Android 就來Android 台灣中文網(https://apk.tw)

使用道具 舉報

6
devilhow67 | 收聽TA | 只看該作者
發表於 2014-4-4 18:05
此帖僅作者可見
用Android 就來Android 台灣中文網(https://apk.tw)

使用道具 舉報

7
bnmdsa123 | 收聽TA | 只看該作者
發表於 2014-4-4 18:12
此帖僅作者可見
用Android 就來Android 台灣中文網(https://apk.tw)

使用道具 舉報

8
s6310818 | 收聽TA | 只看該作者
發表於 2014-4-4 18:15
此帖僅作者可見
用Android 就來Android 台灣中文網(https://apk.tw)

使用道具 舉報

9
loki2121 | 收聽TA | 只看該作者
發表於 2014-4-4 18:50
此帖僅作者可見
用Android 就來Android 台灣中文網(https://apk.tw)

使用道具 舉報

10
pikachu532 | 收聽TA | 只看該作者
發表於 2014-4-4 18:52
此帖僅作者可見
用Android 就來Android 台灣中文網(https://apk.tw)

使用道具 舉報

您需要登錄後才可以回帖 登錄 | 註冊

本版積分規則