I agree that in 99.9% of cases adding dt every tick to a counter will give you an accurate time - but , if I understand it correctly, if your fps drops below 10 fps then dt will not work any more as dt is not allowed to go above 0.1 so your timer will start to slow. I don't think very low fps affects the time/wallclock ?
I would set a variable at the start of the loop to wallClock and then ever x seconds (or tenths of a second) compare the "now time" against this stored time. This way you should get a very accurate time.
Could you not just set a boolean (false if no wall true if wall - set at an appropriate time) and use this to decide on the attack action?
I only go by "Founder" at the lodge on Thursday nights, one trouser leg stuck into my sock, oh wait did you mean Ashley? How embarrassing...
Seriously I go for quite descriptive names but 70 letters...
One way,I guess, would be to just reduce the collision polygon ? Not tested and not sure if relevant to you particular setup.
Worth reading through the thread that 7Soul posted ...
Without the capx or screen grabs we will only be guessing - but if you are doing what I think you are doing it will be something like
pick up health potion
add to health the value of the health potion
set width of health sprite to health
close ?
in which case you just need to check if health is now bigger than maximum health and if so make health equal maximum health
look at "clamp"
https://www.scirra.com/manual/126/system-expressions
so you don't want overlapping at offset you just want overlapping ?
Develop games in your browser. Powerful, performant & highly capable.
try to just offset on the x not on the y (i.e. you are only interested in x (left and right) not in the y (up and down))
to reset see
https://www.scirra.com/manual/61/preferences
winsonzhong - Surely if you are using "while the mouse button is down" to set up an animation then it will constantly set that animation until you release the mouse and therefore can not play the animation as is is constantly restarting it ? I am not familiar with spriter - I do own it but have been putting off learning it - so this is just an educated guess.
I had another look at your code and there is a much easier way - updated the capx - same download link as above. You already had an x offset amount for your joystick so I have just taken that that offset to set the angle.
Just in case you were very quick I messed up the save location (saved to desktop not dropbox !) - if you got the same file as before then please try again.
Member since 2 Feb, 2013