AllanR I don't think your version is working correctly. If you touched any of the ControlsFamily squares first, you can't rotate the ship with the second touch. If you started rotating the ship, you can't move it..
I'm guessing this is how it's supposed to work (open in Chrome):
doptrix.com/C2/ahmtd
Depends on what you want this movement to look like.
If you just need constant speed, you can do this without any behaviors:
On every tick Character X<15 : Character move N*dt pixels
You can use lerp (very fast start, slows down as it gets closer to position):
Character set X to lerp(self.x, 15, dt)
Or try the new Tween behavior in C3 runtime, with it you can make different cool effects - acceleration, deceleration, bounce, etc.
dropbox.com/s/rsjjrysqt3vc9v5/InfiniteParallaxBG.capx
See the last two events. Your background should be at least 2 times wider than window size.
Maybe you should lose the attitude and stop being an a-hole to people who are trying to help. You can create perfectly working multi-touch controls in C2/C3, good luck figuring this out on your own.
See this demo (sorting array by "HP" in column 1):
dropbox.com/s/88wse8qyrr3ysgs/arraySort.capx
Did you set animation speed to 0?? It works for me. Normal mode - light blue shadow, hard mode - dark blue.
Instead of ranting for 2 pages you should've clearly explained what exactly are you trying to make. It's impossible to understand what's going on in your project.
You want to move the ship with those blue and green squares (right hand), and aim by touching anywhere on the screen (left hand), correct? Why don't you use a "virtual joystick" or thumbstick? There are plenty of examples on this forum, I made one just yesterday:
construct.net/en/forum/construct-2/how-do-i-18/how-do-i-multi-control-for-and-139160
Should be easy enough.
For "y" from 0 to array.height-1 if array.At(X, loopindex("y"))="" ---> Array set value at (X, loopindex("y")) to new_value ---> system Stop loop
That's actually what multidimensional arrays are for. Set array Height=3 and you will be able to store three values per each X element. (on Y axis)
For example:
WeaponsArray set value at (X=0, Y=0) to damage WeaponsArray set value at (X=0, Y=1) to ammo WeaponsArray set value at (X=0, Y=2) to maximum_ammo To get ammo of weapon 0: WeaponsArray.At(0,1)
If you have 2D array, use Depth=3 and store values at axis Z.
If you are already using 3D array, then you can store multiple values in comma-separated strings, as mOOnpunk recommended.
What exactly doesn't work? You might need to add a deadzone. See this example:
dropbox.com/s/fpfpwv7io4v6rf1/GamepadTopViewShooter.capx
I don't understand, what shadow? PlayerGhost sprite? Maybe that's because you didn't stop its animation (set animation speed to 0).
Develop games in your browser. Powerful, performant & highly capable.
In event #2 you reset all global variables to default (including "Hardmode" variable). After that in event #25 you check if Hardmode is false, which it is now.. There are many ways to fix this, the easiest is set Hardmode=true again in event #2.
Member since 26 May, 2016