Jump to content
Search In
  • More options...
Find results that contain...
Find results in...

Is there any kind of Map Generator or pre linked maps?


kanechart
 Share

Recommended Posts

Is there any kind of Map Generator or pre linked maps?

I wanted to make a planet of 20x20 so 400 maps to start with.

I would say that would take me a lifetime to make that many maps but I can't find anything on here about pre linked map sets or a tool that can make it for ya.
Link to comment
Share on other sites

@Ballie:

> This could be an interesting project, and not too hard. I could write it up in Notepad, if someone could compile it.

I prob can compile it. I have not tried vb6 yet in windows 7\. I thought was odd none of the engines have this since heck so many people making 100's of maps and linking them by hand. I will be posting in my WIP soon with some info on my project I even have maps made up (world map)
Link to comment
Share on other sites

Give this a shot:

```
Type TileRec
    Ground As Long
    Mask As Long
    Anim As Long
    Mask2 As Long
    M2Anim As Long
    Fringe As Long
    FAnim As Long
    Fringe2 As Long
    F2Anim As Long
    Type As Byte
    Data1 As Long
    Data2 As Long
    Data3 As Long
    String1 As String
    String2 As String
    String3 As String
    Light As Long
    GroundSet As Byte
    MaskSet As Byte
    AnimSet As Byte
    Mask2Set As Byte
    M2AnimSet As Byte
    FringeSet As Byte
    FAnimSet As Byte
    Fringe2Set As Byte
    F2AnimSet As Byte
End Type

Type MapRec
    Name As String * 20
    Revision As Integer
    Moral As Byte
    Up As Integer
    Down As Integer
    Left As Integer
    Right As Integer
    music As String
    BootMap As Integer
    BootX As Byte
    BootY As Byte
    Shop As Integer
    Indoors As Byte
    Tile() As TileRec
    NPC(1 To 15) As Integer
    SpawnX(1 To 15) As Byte
    SpawnY(1 To 15) As Byte
    Owner As String
    Scrolling As Byte
    Weather As Integer
End Type

Public Map() as MapRec

Sub LoadMaps()
    Dim FileName As String
    Dim I As Integer
    Dim f As Integer
    ReDim Map(400)

    For I = 1 To 400
        FileName = App.Path & "\maps\map" & I & ".dat"

        f = FreeFile
        Open FileName For Binary As #f
        Get #f, , Map(I)
        Close #f

    Next I

End Sub

Sub LinkMaps()
    Dim X as Byte
    dim Y as BYte
    Dim temp as integer
    For x = 1 to 20
        For y = 0 to 19
            temp = y * 20 + x

            If x > 1 Then
                Map(temp).Left = temp - 1
            End If

            If x < 20 Then
                Map(temp).Right = temp + 1
            End If

            If y > 0 Then
                Map(temp).Up = temp - 20
            End If

            If y < 19 Then
                Map(temp).Down = temp + 20
            End If 

        Next
    Next
End Sub

Sub SaveMaps()
    Dim FileName As String
    Dim f As Long
    Dim i as Integer

    For i = 1 to 400
        FileName = App.Path & "\maps\map" & i & ".dat"
        f = FreeFile
        Open FileName For Binary As #f
        Put #f, , Map(i)
        Close #f
    Next
End Sub

Private Sub Form_Load()
    LoadMaps
    LinkMaps
    SaveMaps
    End
End Sub
```

This was slapped together pretty quickly, but I can troubleshoot any issues with it. Give it a try. It assumes that your grid will be from 1 to 20 on the first row, then 21 to 40 in the second, etc. for 20 rows. If you've already got maps, this won't account for those, sorry.

Just throw these subs into a program however you like, then compile and throw it into your server folder. The Form thing will have to be in a form, obviously, and the types have to be in a module, I believe.
Link to comment
Share on other sites

If you are saying you don't want to take the time to make the warps from one map to another, here is a nice little rig (in case you already made some maps lol)

Use a mouse recorder (i use ghostmouse 2.0 or axife but axife cost me $10 :O)
Then record yourself doing a row/column, then you can play it back on a high playback speed.  It will do one row/column of warps in like 10 secs.  :)

Although it does seem a bit unprofesional… c:
Link to comment
Share on other sites

Working so far testing in game

Okay I'm back that was like the most amazing application in the world and I'm dying in love. Its a little dark LOL but amazing work.

Now you said if I edit the map like do a simple grass fill and copy and paste map 1 400 times and rename it all it would not work? lol its easier I find to work with grass base.

Again amazing thanks so much

EDIT: I mean water base I think last time I calculated it was 167 land maps and 233 water maps
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...