Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6602847
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 25, 20262026-05-25T18:55:37+00:00 2026-05-25T18:55:37+00:00

In our game, we have a typical tech tree, which is currently edited by

  • 0

In our game, we have a typical tech tree, which is currently edited by hand – very hard to maintain and error-prone: http://igmarauders.isotx.com/library/images/a/a3/Techtree-july26-2011-vehicles-resized.png

If at all possible, I’d like to generate this in an HTML form, but I have no idea where to start. Maybe people here have tackled similar problems and can point me in the right direction?

Some technical details:

  • Every node is an entity, with a unique ID (number)
  • Every entity has a list of prerequisites (other entities)
  • The starting tech (on the left) is an array of entities
  • Only entities that can be traced back to the starting tech show up in the map
  • The research level (the columns along the top) are a property available for each entity
  • Entities of the same types but different levels (e.g. Assault Archos LvL 1, Assault Archos LvL 2) are linked by a property from the higher level to the lower level (and the higher level always has the lower level as a prerequisite too)
  • We can distinguish between Technology (upper part) and Vehicles (lower part) by the entity type, a per-entity property.
  • The actual names are also a per-entity property, and not really important for the tree itself

Finally:

  • You can ignore the differentiation between solid lines and dotted lines (I don’t even know what the difference really is)
  • The boxes that group vehicles together that are unlocked by one research project are nice to have, but not required

Thanks in advance. I have searched on Google, but all the “complex tree” examples I found were childishly simple compared to mine 🙂

edit: Here is some sample data, in a JSON format: http://pastebin.com/Fa3JcnRw

edit 2: Also, if it matters, we use PHP on the server side, but I’m open to alternatives – we could generate the static HTML in a build script for example.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-25T18:55:37+00:00Added an answer on May 25, 2026 at 6:55 pm

    I’ve hacked together an alternative idea, you can see it at
    http://jsfiddle.net/jedidiah/sTj3E/4/embedded/result/

    The idea is to just list all of the items at each level in columns, and then when you click on one of the items it highlights the techs that are required.

    I think it would be a bit easier to get your head around than all the lines, thought it wouldn’t give you the overview at a glance, you would have to click around.

    edit: You can see the code here http://jsfiddle.net/jedidiah/sTj3E/4/ forgive the messiness, just a quick example to get the idea across.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

In error reports from some end users of our game I have quite often
One of our customers said they have a very simple script which uses fsockopen()
For our online game, we have written tons of PHP classes and functions grouped
This one game I do scripting for uses a primary dll in which our
I have the following plugin, which takes a partial game name, bounces it off
We have implemented our domain model using the accountability pattern, which we are trying
A new game server just came out which our company would like to offer
In our game (targeted at mobile) we have a few different entity types and
Currently I'm working on an Othello/Reversi game in c++. I have it finished except
We're developing a silverlight multiplayer game using TCP connections. We have all of our

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.