Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
[Feature] Y-based sprite rendering!
#21
Rian Wrote:Ask all the stupid questions you want.


Well now you've just opened the door for me Wink

Hmmm Okay So tell me where I've gone wrong because I definitely have

Replaced this
Code:
' Blit out players
        For i = 1 To PlayersOnMapHighIndex
            Call BltPlayer(PlayersOnMap(i))
        Next
                
        ' Blit out the npcs
        For i = 1 To MAX_MAP_NPCS
            Call BltNpc(i)
        Next

With This
Code:
' Blit out players and NPCs
            For Y = 0 To MAX_MAPY
                For i = 1 To PlayersOnMapHighIndex
                    If Player(i).Y = Y Then
                        Call BltPlayer(PlayersOnMap(i))
                    End If
                Next
                For i = 1 To High_Npc_Index
                    If MapNpc(i).Y = Y Then
                        Call BltNpc(i)
                    End If
                Next
            Next

Now Starting the game It Highlights
Code:
High_Npc_Index
and says

Compile Error
Variable Not Defined


Any Ideas ^.^
Sorry I'm just starting out with VB
Reply


Messages In This Thread

Forum Jump:


Users browsing this thread: 1 Guest(s)