• A Sub é essa
Public Sub DrawPlayerName(ByVal Index As Long)
Dim TextX As Long
Dim TextY As Long
Dim color As Long
Dim Name As String
' If debug mode, handle error then exit out
If Options.Debug = 1 Then On Error GoTo errorhandler
' Check access level
If GetPlayerPK(Index) = NO Then
Select Case GetPlayerAccess(Index)
Case 0
color = QBColor(White)
Case 1
color = QBColor(BrightCyan)
Case 2
color = QBColor(BrightCyan)
Case 3
color = QBColor(BrightCyan)
Case 4
color = QBColor(Yellow)
End Select
End If
Name = Trim$(Player(Index).Name)
' calc pos
TextX = ConvertMapX(GetPlayerX(Index) * PIC_X) + Player(Index).XOffset + (PIC_X \ 2) - getWidth(TexthDC, (Trim$(Name)))
If GetPlayerSprite(Index) < 1 Or GetPlayerSprite(Index) > NumCharacters Then
TextY = ConvertMapY(GetPlayerY(Index) * PIC_Y) + Player(Index).YOffset - 16
Else
' Determine location for text
TextY = ConvertMapY(GetPlayerY(Index) * PIC_Y) + Player(Index).YOffset - (DDSD_Character(GetPlayerSprite(Index)).lHeight / 4) + 16
End If
' Draw name
Call DrawText(TexthDC, TextX, TextY, GetPlayerName(Index) & " Lv: " & GetPlayerLevel(Index), color)
' Error handler
Exit Sub
errorhandler:
HandleError "DrawPlayerName", "modText", Err.Number, Err.Description, Err.Source, Err.HelpContext
Err.Clear
Exit Sub
End Sub
_________________________________________________________________________
No caso, meu level ao lado do nome tá bugado!
fica da seguinte forma ....
Vila da folha [Rank-A]
Hokage
Juan-kael (Lv.5000)
queria saber se poderia linevar (Igualar)
pra ficar da seguinte forma....
Vila da folha [Rank-A]
Hokage
Juan-kael (Lv.5000)
Créditos eu dou! Relaxem