| Mirage Source http://miragesource.net/forums/ |
|
| Variable Required issue... http://miragesource.net/forums/viewtopic.php?f=201&t=4072 |
Page 1 of 1 |
| Author: | DarkC [ Mon Jul 28, 2008 8:16 pm ] |
| Post subject: | Variable Required issue... |
Ok, well I'm trying to make it so they player's HP will be displayed above their heads in text. But I keep getting a error when I am running the client...It keeps highlighting "GetPlayerHP" in the TextX = GetPlayerX line...This is what the errors says "Variable required - can't assign to this expression". I've never gotten this error before, so I have no clue what to do. Code: Sub BltPlayerHP(ByVal Index As Long)
Dim TextX As Long Dim TextY As Long Dim Color As Long ' Set Color HP is displayed in If GetPlayerHP(Index) = 0 Then Color = QBColor(DarkGray) Else Color = QBColor(BrightGreen) End If ' Draw player HP TextX = GetPlayerX(Index) * PIC_X + sx + Player(Index).XOffset + Int(PIC_X / 3) - ((Len(GetPlayerHP(Index)) / 2) * 8) TextY = GetPlayerY(Index) * PIC_Y + sx + Player(Index).YOffset - Int(PIC_Y / 3) - (SIZE_Y - PIC_Y) Call DrawText(TexthDC, TextX - (NewPlayerX * PIC_X) - NewXOffset, TextY - (NewPlayerY * PIC_Y) - NewYOffset, GetPlayerHP(Index), Color) End Sub |
|
| Author: | Dragoons Master [ Mon Jul 28, 2008 8:24 pm ] |
| Post subject: | Re: Variable Required issue... |
What's sx ? |
|
| Author: | DarkC [ Mon Jul 28, 2008 8:26 pm ] |
| Post subject: | Re: Variable Required issue... |
A damage variable. |
|
| Page 1 of 1 | All times are UTC |
| Powered by phpBB® Forum Software © phpBB Group https://www.phpbb.com/ |
|