Convidado Convidado
| Assunto: Copiar Sprite Dom 06 Nov 2011, 10:04 | |
| Client~Side
Na frmEditor_Spel crie um chekbox com as configurações:
- Citação :
- Name: chkCSprite
Caption: Copiar Sprite
E adicione isso dentro dele:
- Código:
-
If chkCSprite.Value = 0 Then Spell(EditorIndex).CSprite = False Else Spell(EditorIndex).CSprite = True End If
Em Type Spellrec adicione no final:
- Código:
-
CSprite as Boolean
Procure por:
- Código:
-
If Spell(EditorIndex).IsAoE Then .chkAOE.Value = 1 Else .chkAOE.Value = 0 End If
E abaixo adicione:
- Código:
-
If Spell(EditorIndex).CSprite Then .chkCSprite.Value = 1 Else .chkCSprite.Value = 0 End If
Serve~side
Em Type Spellrec adicione no final:
- Código:
-
CSprite as Boolean
Procure por:
- Código:
-
Public Sub CastSpell(ByVal Index As Long, ByVal spellslot As Long, ByVal target As Long, ByVal targetType As Byte)
Abaixo de:
- Código:
-
Dim SpellCastType As Long
Adicione:
- Código:
-
Dim NpcTarget As String, PlayerTarget As String
Procure por:
- Código:
-
' find out what kind of spell it is! self cast, target or AOE
Acima adicione:
- Código:
-
' Copiar Sprite If Spell(spellnum).CSprite = True Then If targetType = TARGET_TYPE_PLAYER Then Call SetPlayerSprite(Index, Player(TempPlayer(Index).target).Sprite) Call PlayerWarp(Index, GetPlayerMap(Index), GetPlayerX(Index), GetPlayerY(Index)) Exit Sub ElseIf targetType = TARGET_TYPE_NPC Then Call SetPlayerSprite(Index, NPC(TempPlayer(Index).target).Sprite) Call PlayerWarp(Index, GetPlayerMap(Index), GetPlayerX(Index), GetPlayerY(Index)) Exit Sub End If End If
Creditos:
Ricardo |
|