spawning actors

first weak here i would love some help
I made 4 actors and i want to spawn only 3 of them using a timer.

Comments

  • tatiangtatiang Member, Sous Chef, PRO, Senior Sous-Chef Posts: 11,949
    You'll need to explain more than that. Are you wanting to randomly choose three of the hour? How often do you want them to spawn? Where do you want them to spawn?

    New to GameSalad? (FAQs)   |   Tutorials   |   Templates   |   Greenleaf Games   |   Educator & Certified GameSalad User

  • papitopapito Member Posts: 8
    i want to make 4 actors and only make 3 of them spawn ramdomly every 3 seconds . i want to give each actor a selected spawn potition
  • gyroscopegyroscope I am here.Member, Sous Chef, PRO Posts: 6,598

    You do realise that if you're giving a spawned actor a certain position, that if the position is not changed for repeated spawns, you'll just get a very neat pile of actors exactly on top of one another, looking like just one actor.

    ""You are in a maze of twisty passages, all alike." - Zork        temp domain http://spidergriffin.wix.com/alphaghostapps

  • papitopapito Member Posts: 8
    Im tryng to make 4 spawn points and i want only 3 of them to spawn after 2 seconds. how can i make it hapen?
  • tatiangtatiang Member, Sous Chef, PRO, Senior Sous-Chef Posts: 11,949
    first weak here i would love some help
    I made 4 actors and i want to spawn only 3 of them using a timer.
    i want to make 4 actors and only make 3 of them spawn ramdomly every 3 seconds . i want to give each actor a selected spawn potition
    Im tryng to make 4 spawn points and i want only 3 of them to spawn after 2 seconds. how can i make it hapen?
    With all due respect, this kind of information is really not helpful. I can think of five different ways to do what you're describing but I suspect you have a single way in mind. I can't tell which it is because you keep repeating the same thing over and over.

    Try being more verbose. Explain the context and give an example from another game that is similar to what you want. I started to make you a demo and stopped because I couldn't figure out what you meant.

    New to GameSalad? (FAQs)   |   Tutorials   |   Templates   |   Greenleaf Games   |   Educator & Certified GameSalad User

  • papitopapito Member Posts: 8
    im using acelerate on the actor thats going to be spawn to drop down so i want to create this 4 spawn points (40,490) (120,490) (200,490) (280,490) .now every 3 seconds i want to ramdomly only spawn 3 of them so i get the efect of obstacles
  • tatiangtatiang Member, Sous Chef, PRO, Senior Sous-Chef Posts: 11,949
    Here's a demo.

    New to GameSalad? (FAQs)   |   Tutorials   |   Templates   |   Greenleaf Games   |   Educator & Certified GameSalad User

  • papitopapito Member Posts: 8
    sorry but im working on windows do you have a demo for windows please
  • tatiangtatiang Member, Sous Chef, PRO, Senior Sous-Chef Posts: 11,949
    edited February 2014
    I don't use Windows Creator but hopefully this video of the file will help. I know videos like this are a little awkward to use but at least it contains all of the necessary actors, rules, attributes, and tables. If you view it on YouTube, you can increase the quality (HD) and size.

    New to GameSalad? (FAQs)   |   Tutorials   |   Templates   |   Greenleaf Games   |   Educator & Certified GameSalad User

  • papitopapito Member Posts: 8
    Thank you so much.
  • papitopapito Member Posts: 8
    how can you make them come faster with time ?
  • tatiangtatiang Member, Sous Chef, PRO, Senior Sous-Chef Posts: 11,949
    Do you want the spawn rate to increase as time increases?

    New to GameSalad? (FAQs)   |   Tutorials   |   Templates   |   Greenleaf Games   |   Educator & Certified GameSalad User

  • papitopapito Member Posts: 8
    i want to make it so every 20 seconds the blocks come down faster
  • tatiangtatiang Member, Sous Chef, PRO, Senior Sous-Chef Posts: 11,949
    This post and the demo below it aren't exactly what you want but with a little tweaking it should work:

    http://forums.gamesalad.com/discussion/comment/449790/#Comment_449790

    New to GameSalad? (FAQs)   |   Tutorials   |   Templates   |   Greenleaf Games   |   Educator & Certified GameSalad User

  • papitopapito Member Posts: 8
    ok so you create 2 new atributes 1.game stamp(real) and 2.counter duration(real) .
    Then you make a constarin atribute in the moving actor game.counter duration to 10/self.motion.linearVelocity.y then in spawner if game.time=>game.counter+game.stamp change atribute gma.counter to game.counter+1 and another change atribute game.timestamp to game.time
    is this correct becouse nothing is hapening
    and also i can get the divided by symbol or / this is the same
  • tatiangtatiang Member, Sous Chef, PRO, Senior Sous-Chef Posts: 11,949
    Yes, the "/" symbol is used for division. So you have this?

    Constrain attribute game.counterDuration to 10/self.motion.Linear Velocity.Y
    If attribute game.Time ≥ game.counter + game.timeStamp
         Change attribute game.counter to game.counter + 1
         Change attribute game.timeStamp to game.Time

    You're constraining game.counterDuration but then not using it at all in the rule. It has to be part of the rule condition. I also think you're going to need a larger multiple than 10 because 10/100=0.1 and 10/200=.05, so you'd be repeating this loop every 0.1 or 0.05 seconds if your velocities are that high.

    But more importantly, I thought you wanted the increase in speed to be dependent on time, not on speed...?

    New to GameSalad? (FAQs)   |   Tutorials   |   Templates   |   Greenleaf Games   |   Educator & Certified GameSalad User

Sign In or Register to comment.