jobel's Forum Posts

  • You can then set their Y coordinates to whatever you want (random, or on the floor/ceiling, etc...).

    thanks for the reply

    the only problem with this is my player rotates, so both player coordinates have to be modified.

  • yes, the range is static. (200 let's say)

    but my layout is 800x800 and if the Target happens to be at pos 780,780 then I can't say Create Object (Turret, Target.x+300, Target.y+300) because it will spawn off screen.

    I need it to calculate going back to zero after the position goes past the layout.x and layout.y

  • still working on this.. thanks for the info! you should make a tutorial!

  • hi,

    anyone have a good idea how to randomly spawn a sprite with turret behavior..but make sure when it spawns it's not in range of the target?

    since the target is moving I assume you need to do some sort of calculation based on target.x and target.y

    I also have wrap behavior for both turret sprite and the target which both move...

  • honestly, it's no big deal.. I only brought it up as I thought was kind of funny and just wondered if it happened to other people. Like a previous person said I've gotten used to it and after I write a post I always select-all and copy it, refresh my browser and paste - it skips a step of being denied..

    I'm sure you have bigger fish to fry...

  • I'd show you the screenshot if I could figure out how to post an image to the forum...

  • i got this...

    X Error

    Only members with sufficient permission can access this page.

    A security error has occurred with with authentication.

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • well, let me write this response and see..

    if I get up and go in the other room....then come back.... it should expire..

    let's see...hitting 'post reply' now..

    yup, still happening..

    great work, can't wait to see it.. I'm a fan!

  • oh I didn't think it was a bug... I just thought it was a different kind of setup..

    (I paused while typing this and my session expired)

  • would love to see the gameplay.. do you have a youtube link or some other promo for it?

  • I do the same with my sound

    can you explain this more? what do you do with your sounds? and why..

  • If you want a pattern, your best bet will be to load the file names into an array .

    ahh nice idea using arrays... so if I were to make it a Function I could pass the array bounds.

    say I had a 7 pattern of: 1 1 2 1 2 1 2

    CallFunction("PlaySoundPattern",PlayerShoot_arrraysounds, 7, PlayerShootCounter)

    CallFunction("PlaySoundPatter",BadGuy_arraysounds,3, BadyGuyShootCounter)

    although should probably make array bounds a constant so you can change it easy.

    C7, you must do this for footsteps on different materials..grass, woodfloor, cement floor etc...?

  • You can't create patterns with choose() or random() though.

    yeah, that's why I used your --- Set counter to counter % 3 + 1 idea

    although I changed it to 6 which makes more sense in my case... since I have bullet firing sounds, then every 6th event it changes the sound slightly.

    for patterns maybe a better idea would be to make a Function and somehow make it dynamic so that you could use it for multiple things.   Make sure all sound files are named the same except for the number.

    so pass the function: filename (minus the number), the number of sounds, then the pattern to play and the counter which tells us where we are in the pattern.

    i.e.

    Call Function ("PlaySoundPattern","gun", 2, "6:1", PlayerShootcounter)

    I'm new to Functions in C2 can anyone help here? how would you send a pattern information to a function so that it understands how to play them? patterns like 6:1 or 3:2 or 1:2:1 if there are 3 sounds etc..? how to make it dynamic?

  • thanks, good to know... I will look into using families since I may expand to different ships as well.