Search found 41 matches

by var77
Fri Jul 19, 2019 3:47 pm
Forum: Support and Development
Topic: [SOLVED] Strange draw order
Replies: 3
Views: 789

Re: Strange draw order

Thanks pgimeno your rough draft solved my issue. I understand my mistake of the last draw in my list of circle (kinda obvious with fresh eyes ^^ ). By the way thanks Zorg for the tips, it could be something missed in older code and never changed it.
by var77
Fri Jul 19, 2019 10:24 am
Forum: Support and Development
Topic: [SOLVED] Strange draw order
Replies: 3
Views: 789

[SOLVED] Strange draw order

Hi everyone, I back here with a graphic issue that really surprised me. So I try to display some random circle (white) and try to hide one circle (red) that move on the screen behind others. But here is the trick if I understand well how drawing is working the last draw will be the upper one. And I ...
by var77
Sat Jul 13, 2019 11:47 am
Forum: Support and Development
Topic: [SOLVED] Math + Spread bullets
Replies: 10
Views: 1261

Re: [SOLVED] Math + Spread bullets

Thanks theHUG for this precision. It could still help ;)
by var77
Fri Jul 12, 2019 3:34 pm
Forum: Support and Development
Topic: [SOLVED] Math + Spread bullets
Replies: 10
Views: 1261

Re: Math + Spread bullets

Why make things easier when you can complex them... I finaly found exactly the expected result. Sorry @pgimeno you were right (as often with my issues) just need to add some math.rad() to the angle like this for example: table.insert(b, {x = startX, y = startY, dx = visor.speed * math.cos(angle+math...
by var77
Thu Jul 11, 2019 4:44 pm
Forum: Support and Development
Topic: [SOLVED] Math + Spread bullets
Replies: 10
Views: 1261

Re: Math + Spread bullets

First thanks again all of you. Both aproach gave interesting result. After post my last reply I found what I was searching with just adding two var that I may have to random: table.insert(b, {x = startX, y = startY, dx = bulletDx, dy = bulletDy,r=size,vx=15,vy=15}) -- and v.x = v.x + ((v.dx+v.vx) * ...
by var77
Wed Jul 10, 2019 8:40 pm
Forum: Support and Development
Topic: [SOLVED] Math + Spread bullets
Replies: 10
Views: 1261

Re: Math + Spread bullets

First of all thanks both a you for aswering me I think I see my issue more clearly. So I got to add some "offsetX/Y" or "VelocityX/Y" to my projectile to get this effect, with an other function that will spread my result (position X/Y). But I guess I don't handle how in my case. I create my projecti...
by var77
Wed Jul 10, 2019 4:20 pm
Forum: Support and Development
Topic: [SOLVED] Math + Spread bullets
Replies: 10
Views: 1261

Re: Math + Spread bullets

ps: files if it's also help ^^
test.zip
(11.45 MiB) Downloaded 21 times
(sorry to post that in a reply buts seems buggy when I post multiple attachement stuff)
by var77
Wed Jul 10, 2019 4:09 pm
Forum: Support and Development
Topic: [SOLVED] Math + Spread bullets
Replies: 10
Views: 1261

[SOLVED] Math + Spread bullets

Hi everyone, I'm back here with a little issue with my "spread bullets". So here is the deal, I try to make some firing (like a shotgun) and spread alls bullets randomly. My actual result is not spreading like how it should with my rotate gun. spread_firering.png So if any one got a tips in how to r...
by var77
Wed May 15, 2019 2:40 pm
Forum: Support and Development
Topic: [SOLVED] Resolution display
Replies: 2
Views: 1176

Re: [SOLVED] Resolution display

BTW I figure out what was the problem with canvas library (or canvas in it self). I was using position by my screen size unless using position by my canvas (or absolute position). So if you are looking the same issues as me use absolute position then draw every thing in a canvas and resize it. :crazy:
by var77
Tue May 14, 2019 11:32 am
Forum: Support and Development
Topic: [SOLVED] Resolution display
Replies: 2
Views: 1176

Re: Resolution display

So after few research I finaly solve my issue with this awesome library:
https://github.com/Romans-I-XVI/Love-Lo ... ion-Camera

It's just a scale not a canvas solution but fit well for me.
If some are interesting of a sample here it is.
https://www.youtube.com/watch?v=CF5XRS5EDmI