Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Help needed regarding Lesson 17
#6
Quote:I try to figure out how to count angle between two points. I based my attempt on Qb64tutorials lesson 17 and there is this Trig demo I based my poor knowledge. This is simplified attempt I try to figure out:

$Color:32

screen1 = _NewImage(1280, 720, 32)
Screen screen1

Const PI = 3.1415926
x1 = 622 + 8
y1 = 395 + 8

x2 = 636 + 4
y2 = 356 + 4

angle = _Atan2(x2 - x1, y2 - y1) * 180 / PI
If angle < 0 Then angle = angle + 360

Print angle

PSet (x1, y1), White
PSet (x2, y2), White

Maybe I misunderstand something totally. The angle should be around 190, give or take, right?

^ The issue as reported on Discord, in case you can sort out what the solution might be for what they're looking for here.
Reply


Messages In This Thread
Help needed regarding Lesson 17 - by RhoSigma - 10-08-2024, 10:39 AM
RE: Help needed regarding Lesson 17 - by bplus - 10-08-2024, 05:24 PM
RE: Help needed regarding Lesson 17 - by bplus - 10-08-2024, 05:46 PM
RE: Help needed regarding Lesson 17 - by SMcNeill - 10-08-2024, 06:32 PM
RE: Help needed regarding Lesson 17 - by bplus - 10-08-2024, 06:59 PM
RE: Help needed regarding Lesson 17 - by SMcNeill - 10-08-2024, 07:04 PM
RE: Help needed regarding Lesson 17 - by bplus - 10-08-2024, 07:17 PM
RE: Help needed regarding Lesson 17 - by bplus - 10-08-2024, 07:10 PM
RE: Help needed regarding Lesson 17 - by bplus - 10-08-2024, 07:22 PM
RE: Help needed regarding Lesson 17 - by SMcNeill - 10-08-2024, 07:44 PM
RE: Help needed regarding Lesson 17 - by bplus - 10-08-2024, 08:16 PM
RE: Help needed regarding Lesson 17 - by bplus - 10-09-2024, 01:25 PM
RE: Help needed regarding Lesson 17 - by SMcNeill - 10-09-2024, 04:19 PM
RE: Help needed regarding Lesson 17 - by bplus - 10-09-2024, 03:17 PM
RE: Help needed regarding Lesson 17 - by bplus - 10-09-2024, 04:00 PM
RE: Help needed regarding Lesson 17 - by bplus - 10-09-2024, 04:11 PM
RE: Help needed regarding Lesson 17 - by bplus - 10-09-2024, 10:43 PM
RE: Help needed regarding Lesson 17 - by bplus - 10-10-2024, 10:33 PM
RE: Help needed regarding Lesson 17 - by bplus - 10-11-2024, 03:01 PM
RE: Help needed regarding Lesson 17 - by bplus - 10-11-2024, 06:36 PM
RE: Help needed regarding Lesson 17 - by bplus - 10-11-2024, 07:08 PM
RE: Help needed regarding Lesson 17 - by bplus - 10-11-2024, 08:51 PM



Users browsing this thread: 5 Guest(s)