LittleStain's Forum Posts

  • It's exactly the same as above..

    instead of comparing the y you just use

    on touched object - player - 8 direction - simulate control - up

    on other touched object - player - 8 direction - simulate control - down

  • You've completely lost me here..

    If you are going to "push" the colors into the array, why not use the array as reference to create the visuals?

    I have no idea what string chaining is and why you would need it, it sounds like what you want to do is relatively easy.

    You should probably use the function object to create the action, for all actions are almost the same, only the variables change, so if you put these in the correct spot in the function it will all go as planned..

    Instead of creating at imagepoint 0 of the slotx object, why not create like this

    variable SlotX = 0

    variable SlotY = 0

    on black pin object pushed call function ColorPicked with parameter 0 is black

    On function ColorPicked

    • Array set at xy : x=SlotX - Y=SlotY value = function.parameter(0)

    --subevent

    -- If variable SlotX < 5

    --- set SlotX : SlotX+1

    -- If variable SlotX =5

    ---set SlotX : 0

    ---set SlotY : SlotY+1

    • call function Draw

    on function draw

    • destroy all sprites

    -array compare value at xy: 0,0 = black

    • create object blacksprite at x=100+100*array.CurX - y=100+100*array.Cury..

    bladiblah..

    Something like this should work..

    By the way instead of making a lot of different sprites (black, blue,red,whatever) wich have everything incommen exept for there color, I would choose to use animations or animationframes of 1 sprite.. that way you only have to set the frame or animation to the color desired and all that has to be created is the same sprite over and over..

    Youi get the drift..

    -- create

  • How do you want the touch to work?

    you could try something like:

    touch.y > player.y - player simulate pressing down

    touch.y< player.y

    touch.y is not 0 - player simulate pressing up

  • Wouldn't it be easier to pin the fire to the enemyboxes, instead of trying to set them ever tick?

    that way you can avoid that picking issue..

  • You could use blendmodes for masking certain parts of a layer..

    There's an example shipped with C2

  • Could it be your game is so small that it takes no time at all to load, so before you can see the preloader it's already completely in memory and running?

  • You don't have to change anything if six bullets a second is what you are aiming for..

    But I'd replace the every tick action with something like

    is touching button

    every 0.2 seconds - spawn bullet

    or something like that..

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Correct me if I'm wrong..

    Every tick 10 is added to the bullet delay..

    If the game is 60fps the bullets will fire every ten ticks, so thats 6 bullets per second..

    i guess the audiosample is longer than 1/6th of a second..

  • Are you sure you are not spawning your bullets on the background layer?

  • kbtbc

  • You are trying to create a game playable for touchscreen, but you don't understand how..

    I could do it fior you, but for me also it would consist of a lot of trying, albeit with a little more background information..

    You are going to have to read up on touchID, for without it multitouch is impossible to implement..

    you could add conditions if touch.x=0 and touch.y=0 and tell the character at what angle to hold the gun.

    you could also add a condition if touch.y> a certain value to not point the gun there..

    But the more difficult part will be the multitouch and working with the touchID..

    It's been a while since I did that and I must say I've forgotten most..

    I used it in my Thumbstick example:

    Maybe looking how I did it there could help you..

  • Because it's not exactly clear to me what it is exactly what you want, I can't give any further advice, I'm sorry..

    Could be some issues in the way you implement the touchID, but I can't be sure..

    Multitouch is always tricky, I once made a onscreen joystick with fire-button and it took me a while to get the actions concerning the touchID right..

  • It;s very unclear to me what exactly it is you are asking..

    I guess what you'd like to do is add the color clicked to the array..

    so I guess you would have to know which row you are using

    for the first six colours set them to array =at(0,0) till arrayat(0,6)

    add one to a variable

    and the next will set to arrayat(variable,0) untill Arrayat(variable,6) and so on?

    Could probably all be done within one function.

  • You could use subfolders..