• Advertisement
  • entries
    732
  • comments
    1562
  • views
    493231

Amazing progress.

Sign in to follow this  

59 views

I finished my final (kind of hard [crying]) and then came home and worked on Glow. You can now make a definitions file that instantiates NPCs from a unique-definition file.

For example, you can create a new type of NPC, let's say HamSandwichVendor, and make a file named HamSandwichVendor in data/npcs/, which explains his default health, alliances and stats.

Then go, in your level definition file:
data/npcs/HamSandwichVendor 100 100


To spawn him at 10.0, 10.0. And it even works from the console. [grin] Properly designed code is the booyah. I also added in a hack to take additional arguments, should you need to create a very special type of NPC that processes some additional arguments.
Sign in to follow this  


2 Comments


Recommended Comments

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

  • Advertisement