Minimap Problem

pinata14pinata14 Member Posts: 150
edited March 2012 in Working with GS (Mac)
ok, so right now i am making a game where I want to spawn actors, and have a minimap that tells us where they are. I have my game set up so that each unit, even the same types, must be their own actor. I also have modified prototypes of the minimap dots to follow each unit's coords. Because of this setup, only a limited amount of units can be spawned in the game, and once one dies, they cannot come back (unless I change the attribute system to a boolean for each unit in existence (Right now it is set to have an integer counter that goes up every time an actor of a specific type is spawned)). My question, is is there a way that I can have only 1 actor for each unit, that spawns from a different actor, and updates a list of actor count, and also spawn a dot prototype (that also updates its counter list?) on a different layer that only follows its own prototype of each actor? (otherwise the dots will follow only 1 prototype of the actor and ignore the rest I think)
Sorry for the long post but thatnks for the help.
-Ryan

Comments

  • The_Gamesalad_GuruThe_Gamesalad_Guru Member Posts: 9,922
    edited March 2012
    It depends on how you're tracking positions with GAME level attributes or SCENE level?
  • pinata14pinata14 Member Posts: 150
    i haven't used scene level attributes yet, What is the difference?
  • The_Gamesalad_GuruThe_Gamesalad_Guru Member Posts: 9,922
    edited March 2012
    So for every actor you have game level X &Y attributes tracking each one right? I would interpolate the alpha channel on the destroyed actor to 0 and it's mini counterpart and then move the main actor off screen and instead of spawn recycle it back onto scene and bring the alphas back up.
  • pinata14pinata14 Member Posts: 150
    wait, i didn't want to destroy any actors. I was wondering if I could get a minidot to spawn and follow a specific prototype of an actor when that actor spawns. And at the moment I am not using game attributes for tracking. I have minidots that are unlocked so they track straight to the prespawned actors, but each actor has to be its own actor even if it is the same unit type (in my setup)
  • pinata14pinata14 Member Posts: 150
    Is there a way I can upload my project so you can see my setup so far and better understand what I'm trying to do?
  • The_Gamesalad_GuruThe_Gamesalad_Guru Member Posts: 9,922
    edited March 2012
    OKay so you are using scene attributes as you are linking preset scene attributes and no you can't do that as scene attributes are only accessible by actors already on the scene. Which is why I recommended recycling actors.
  • pinata14pinata14 Member Posts: 150
    But I did not press the plus button on the scene attribute page. So you're saying it's impossible to make a dot follow a specific actor prototype? Is there even a way to use game attributes for this, like spawn a game attribute and set actor to change it or something?
  • The_Gamesalad_GuruThe_Gamesalad_Guru Member Posts: 9,922
    edited March 2012
    You are using preset scene attributes you linked probably using a constrained attibute in the minimap actor to the scene.layers.main actor. Those are scene attributes just premade by the software. Everything like that self.position x and such are attributes. You would have to make your own game level X & Y real attributes for every main actor you want to spawn onto the scene and depending on how many you want to track that's a lot of memory usage.
  • pinata14pinata14 Member Posts: 150
    so, in order to make minimap dots, you have to make separate actors for each different Unit is the final
    answer?
    Thanks for all the help
    i'm just going to have to make my game limited.
    -Ryan
  • The_Gamesalad_GuruThe_Gamesalad_Guru Member Posts: 9,922
    Yep. You don't have to downsize just watch tshirt's video on recycling actors.
Sign In or Register to comment.