You are browsing as a guest. Sign up (or log in) to start making projects!

trainTracks

  • 3 Devlogs
  • 14 Total hours

A randomly generated train simulator where the goal is to reach from one side of the track to the other while navigating a complex maze and many dangers.

Open comments for this post

7h 44m 22s logged

Devlog #3

Additions

  • Fixed a bug that caused the train to sometimes fly away from the map when the game was started
  • Fixed inconsistencies in the exits that caused the train to pass over the void and through exits that didn’t exist
  • Added a three-way train station with four variants each facing up, down, left, or right that behave just like the other tracks and automatically generate.
  • Added an arrow in front of the train that spawns for each intersection infront and tells the user where the train is going and which way it was going to turn
  • Added user inputs that allow the user to decide which direction they want the train to go from available paths and exits
  • Made it so the train also rotates and faces its direction of movement rather than always facing forward
  • Other small bugs that I fixed

Planned Updates

  • Make it so when the train arrives at a station, it says game won instead of thinking it fell into the void
  • Make it so the train can’t go back to original station, like say something game lost, etc.
  • Added more train station layouts that are more realistic with curves and such
  • A lot of other things I can’t list

Other Thoughts

  • A significant portion of this update was just working on fixing any bugs that made it so the game was inconsistent when I played it and made it hard to debug, especially with the addition of three-way tracks that made the exits and movement between stations more confusing. I also added the like, probably main part of this game with the player movement, which is the basis of what the goal of this game is, which is to control the train and reach the station. I think next, along with the stuff I said in the planned updates, I also need to work on making sure the generation is better and more consistent but also more fun by adding more clauses so the generation is fun to play on each time and not just a straight line to the station. The video I attached shows the train moving along the path and spawning arrows towards the default path but being switched and changing directions based on player input before falling off the edge.
0
0
7
Open comments for this post

3h 2m 37s logged

Devlog #2

Additions

  • Added a train node and scene that moves along the preplaced track nodes
  • The train moves toward a target exit or middle node until it can no longer go straight or it falls off the edge
  • The train uses the chunk nodes as waypoints, going from exit node to middle node then whichever exit node is chosen
  • The train defaults to going straight until it cannot. Once it cannot go straight it filters all exits removing exits you came from or lead nowhere
  • If there are no available directions, it moves to the end of the last node before stopping and falling off the edge

Planned Updates

  • Adding player input so you can control which direction the train goes
  • Adding indicators that show the default path for the train without any inputs. If input is given the train and indicator should move properly
  • Adding more things that happen when trains arrive at stations
  • And a lot more stuff

What was the goal

  • My main goal was to add a train and design the default path so it automatically starts and begins progressing throughout the default track. I had a lot of the foundation set that made it so I could use the nodes and they could move through the nodes. I had to make sure that there were conditions that made sure they could check to see if the exits lead to another chunk or just the void. The hard part was if a four-way was connected to a horizontal without a direct path but the train still moves over the void to the chunk. I had to check the chunk nodes and exits for the following neighbor chunks also to make sure it was a valid chunk, which took a while to troubleshoot. I want to next try and create more junctions and the default path indicator using arrows. Right now the path is generated as the train moves but if I wanted to set the indicators, I would have to premake the default path, which would also require some more time and work.
0
0
1
Open comments for this post

2h 59m 32s logged

Devlog #1

Additions

  • Added three basic train layouts (four-way intersection, vertical intersection, and horizontal intersection)
  • Added a train end and start station
  • Created a randomly generated network of tracks comprising of the three basic layouts
  • The end and start stations’ positions are predetermined and other intersections are generated randomly with each other’s connecting ends until there are no available grid spaces to generate new tracks
  • If the end station isn’t connected with a corresponding track, the entire map is regenerated

Planned Updates

  • More track layouts, including more complex ones like t-intersections and more
  • Creating the train so it can traverse along these tracks
  • Adding styling to the tracks and other elements
  • More rules to allow better and more unique map generation
  • A lot more other stuff

What was the goal

  • The goal for this devlog was simply to start out the game and make a beginning layout of what the game and tracks would look like. I created these three basic layouts and used a grid to track which tracks had been placed where to keep generating the map. I also had to work on simply getting GoDot engine setup alongside hacktime and learning both how to use the engine and GDScript since this is the first time I’m using GoDot and the first time i’m making a game at all so it’s a learning experience trying to figure out how to use it. Next I want to focus on figuring out how I am going to get trains to work and make them follow the track layouts that will later in the future become more accessible to trains (not have sharp 90 degree turns).
0
0
1

Delete project?

Are you sure you want to permanently delete this project? This action cannot be undone.

All devlogs, followers, and associated data will be removed.

Followers

Loading…