Bay 12 Games Forum

Please login or register.

Login with username, password and session length
Advanced search  
Pages: 1 2 [3]

Author Topic: So, I'm in completely over my head here...  (Read 4105 times)

Moghjubar

  • Bay Watcher
  • Science gets you to space.
    • View Profile
    • Demon Legend
Re: So, I'm in completely over my head here...
« Reply #30 on: January 27, 2015, 11:03:08 am »

(Keep in mind I don't use gamemaker, and I'm also extremely tired so take what I say with a grain of salt)

For loading levels into an array or whatever after generation you need to note a few things: 

First of all, if you have saving and loading in your game you will need to read/write files anyway, so you need to get used to saving/loading to file. 

Second, I'm assuming whatever "DungeonLevel" you have is itself some sort of Object or whatever that has a tilemap, monsters, objects, whatever.  Therefore it kinda boggles me about why you need to save it to an array because you should probably already have something like:

Code: [Select]
//not really code
GameObject:
   Gamestates; //all the things, like if a level has already been generated, etc//
   DungeonObjects[numberofdungeons];
   InitializeDungeons()
     {DungeonObjects[FirstLevel].loadlevel(FirstLevel); //first level is always static//
       DungeonObjects[AllOtherObjects] = NULL; //so not a function, but starts off saying the other dungeon levels arent generated//
      }
    true/false: GenerateLevel(whichlevel)
    {  if (Gamestates.whichlevel.notgenerated()) //generate level if its not loaded yet, return false if level exists //
            { GeneratelevelMethod(DungeonObjects[whichlevel], randomseed); return true;}
         else  return false;
     }
     true / false: LoadLevel(whichlevel)
     {  if (GameStates.whichlevel.generated()) // if its generated we can load it from a file, call this when you enter the level//
          { LoadLevelMethod(DungeonObjects[whichlevel]); return true;}
          else return false;
      }   
     GenerateLevelMethod(DungeonObjects[whichlevel], randomseed) //you should already have something like this I'm guessing
     {DungeonObjects[whichlevel] = generate(randomseed); }
     LoadLevelMethod(DungeonObjects[whichlevel]) //and the load function, assume theres some save function too of course
      {DungeonObjects[whichlevel] = load("filename");} //filename is whatever thingy you decide on for saving and loading of course, and can vary greatly or be static or whatever depending on how you save things.
     

If you want anything more specific than that you probably need to talk to someone that uses gamemaker, or post code you are having trouble with (and then also probably talk to someone familiar with gamemaker).
Logged
Steam ID
Making things in Unity
Current Project: Demon Legend
Also working on THIS! Farworld Pioneers
Mastodon

MaximumZero

  • Bay Watcher
  • Stare into the abyss.
    • View Profile
Re: So, I'm in completely over my head here...
« Reply #31 on: January 27, 2015, 01:49:18 pm »

I'm mostly just an idiot following tutorials, so I probably don't understand my own problem, but I will take a look at this after work. Thanks for the input, I appreciate every bit!
« Last Edit: January 27, 2015, 01:51:06 pm by MaximumZero »
Logged
  
Holy crap, why did I not start watching One Punch Man earlier? This is the best thing.
probably figured an autobiography wouldn't be interesting

MaximumZero

  • Bay Watcher
  • Stare into the abyss.
    • View Profile
Re: So, I'm in completely over my head here...
« Reply #32 on: January 30, 2015, 09:36:06 pm »

Updoot: I've been putting together a design document for exactly what I want. Been really hammering out exactly how I want to do things and exactly what I need to learn.

Next step is getting various maps going. I want you to be able to wander around your little area and have it do stuff. I want you to be able to walk out of the dungeon into a town. I want you to start with a tent, a dungeon entrance, and a lot of grass (and some water.) One of these days, I'll figure out how to get you to the point of building the buildings. I'm probably going to have to pre-set the locations of the buildings, but I'm probably putting the cart a little bit before the horse, here. I have to figure out how to make the town map with buildings, first. I wonder if you can do if, if else, else statements in GME. Probably. I'm just kind of rambling because the whole process makes me sick to my stomach with nerves. I know that what I'm doing is so far over my head as to be unreasonable, but I don't care. I need to make this game, both P&P and vidja gaem. This is my Strange Mood artifact.

I have a tutorial on inventories ready and waiting, and I'm super pumped about doing it, because I'm a sucker for large quantities of items. If you've read my P&P thread at all, you are already aware of this. I need to figure out procedural items eventually, but that's largely a pipe dream for now. I also want to visually represent all of this gear on your character, but again, pipe dream.

The best part about this all, and I could never really say this when I was programming in community college, is that I'm looking forward to learning all this stuff. It's exciting and kind of scary and nerve wracking and lots of other things I can't quantify. How the hell do people do this for a living?

Moghjubar: I've read through your not-code, and I actually think I understand it. I think. I'm going to look over my tutorial stuff and see exactly what gets generated and why, and how it works, and how to abuse it for fun and profit. Oh, how it shall be abused. Anyway, I really appreciate your help.

Thanks for all the feedback, all. I know there isn't really a question in this post, but for all of you reading, everything you say in here helps push me forward just that little bit that I need. I appreciate every single little bit of feedback, encouragement, and even doubt that I get. Thank you all.
Logged
  
Holy crap, why did I not start watching One Punch Man earlier? This is the best thing.
probably figured an autobiography wouldn't be interesting

Orange Wizard

  • Bay Watcher
  • mou ii yo
    • View Profile
    • S M U G
Re: So, I'm in completely over my head here...
« Reply #33 on: January 31, 2015, 07:22:38 pm »

Congratulations on your perseverance.
Logged
Please don't shitpost, it lowers the quality of discourse
Hard science is like a sword, and soft science is like fear. You can use both to equally powerful results, but even if your opponent disbelieve your stabs, they will still die.
Pages: 1 2 [3]