(server side)I made my game 16x16 now and my server gets an error while compiling, but my client is compiling perfectly and when I run the server through VB6 there are no errors. No errors saving the map too.
I changed this:
Code:
Public Const MAX_MAPX = 49
Public Const MAX_MAPY = 28
There's and error here and I did not even touch it:
Code:
Sub ConvertOldMapsToNew()
Dim FileName As String
Dim i As Long
Dim f As Long
Dim X As Long, Y As Long
Dim OldMap As OldMapRec
Dim NewMap As MapRec
For i = 1 To MAX_MAPS
FileName = App.Path & "\maps\map" & i & ".dat"
' Get the old file
f = FreeFile
Open FileName For Binary As #f
Get #f, , OldMap
Close #f
' Delete the old file
Call Kill(FileName)
' Convert
NewMap.Name = OldMap.Name
NewMap.Revision = OldMap.Revision + 1
NewMap.Moral = OldMap.Moral
NewMap.Up = OldMap.Up
NewMap.Down = OldMap.Down
NewMap.Left = OldMap.Left
NewMap.Right = OldMap.Right
NewMap.Music = OldMap.Music
NewMap.BootMap = OldMap.BootMap
NewMap.BootX = OldMap.BootX
NewMap.BootY = OldMap.BootY
NewMap.Shop = OldMap.Shop
For Y = 0 To MAX_MAPY
For X = 0 To MAX_MAPX
NewMap.Tile(X, Y).Ground = OldMap.Tile(X, Y).Ground
NewMap.Tile(X, Y).Mask = OldMap.Tile(X, Y).Mask
NewMap.Tile(X, Y).Anim = OldMap.Tile(X, Y).Anim
NewMap.Tile(X, Y).Fringe = OldMap.Tile(X, Y).Fringe
NewMap.Tile(X, Y).Type = OldMap.Tile(X, Y).Type
NewMap.Tile(X, Y).Data1 = OldMap.Tile(X, Y).Data1
NewMap.Tile(X, Y).Data2 = OldMap.Tile(X, Y).Data2
NewMap.Tile(X, Y).Data3 = OldMap.Tile(X, Y).Data3
Next X
Next Y
For X = 1 To MAX_MAP_NPCS
NewMap.Npc(X) = OldMap.Npc(X)
Next X
' Set new values to 0 or null
NewMap.Indoors = NO
' Save the new map
f = FreeFile
Open FileName For Binary As #f
Put #f, , NewMap
Close #f
Next i
End Sub
It highlights this(I did not mess with any of these either):
Code:
Dim NewMap As MapRec
And says:
Quote:
Too many local, nonstatic variables
Anyone have the fix or have a suggestion?