Search found 1745 matches

by deltarho[1859]
Jul 21, 2019 5:50
Forum: Game Dev
Topic: Physics question
Replies: 52
Views: 1069

Re: Physics question

BasicCodr2 wrote:I have a special folder called the dodicat folder because I find his examples so useful and/or entertaining.

Snap! My folder is called 'DodicatGems'.
by deltarho[1859]
Jul 20, 2019 22:35
Forum: Game Dev
Topic: Physics question
Replies: 52
Views: 1069

Re: Physics question

but are the pieces good starting points to learn (painting or coding)? Probably not. If van Gogh and Constable got into programming I'd reckon van Gogh would plug for Top-Down programming and Constable would plug for Bottom-Up programming. <smile> Both methods have their pros and cons, best bet is ...
by deltarho[1859]
Jul 20, 2019 21:08
Forum: Game Dev
Topic: Physics question
Replies: 52
Views: 1069

Re: Physics question

badidea wrote:but the whole structure is a bit of a mess.

I think that Vincent van Gogh's paintings are a bit of a mess but some folk have parted with some serious money to get their hands on them. One thing is for sure and that is dodicat is not a John Constable. <smile>
by deltarho[1859]
Jul 20, 2019 10:22
Forum: Game Dev
Topic: Physics question
Replies: 52
Views: 1069

Re: Physics question

I was in error, bypassing sleep during a drag. It happens to the best of us. Graphics are not my strong point so it is probably not much coming from me but I reckon that code is one of the best that I have seen. I will make a point of studying it to better my understanding of FB's graphic's capabil...
by deltarho[1859]
Jul 20, 2019 2:13
Forum: Game Dev
Topic: Physics question
Replies: 52
Views: 1069

Re: Physics question

Found the problem. Forget everything that I have written re this problem. In the 'Angle example' '#macro mouse(m)' there is 'Sleep 1,1' just after 'Display()'. That Sleep is not in dodicat's last code. Inserting 'Sleep 1, 1' as follows sees the drag & drop now work perfectly on my machine for bo...
by deltarho[1859]
Jul 20, 2019 0:36
Forum: Game Dev
Topic: Physics question
Replies: 52
Views: 1069

Re: Physics question

I removed the 'rain'. That helped. I then removed all the 'Sleep 0', one at a time, but did not establish a bottleneck. So, the rain was problematic. Perhaps the rain should have been in a separate thread of execution (TOE). I have noticed that many, if not all, graphics apps are single core and hav...
by deltarho[1859]
Jul 20, 2019 0:10
Forum: Game Dev
Topic: Physics question
Replies: 52
Views: 1069

Re: Physics question

srvaldez wrote:that I believe is by design, look at the code for rain.

In deep space? In deep space we are down to about three degrees Kelvin. Perhaps we are near to a black hole and in a Hawking radiation storm. <smile>
by deltarho[1859]
Jul 19, 2019 23:56
Forum: Game Dev
Topic: Physics question
Replies: 52
Views: 1069

Re: Physics question

however if I drag the red dot around and around, the CPU usage rises to 92% This can happen when code is running in a tight loop, so we need to release the time slice. This is not necessary for each iteration, perhaps every 128 or 256. However, to keep things simple I inserted 'Sleep 0' before the ...
by deltarho[1859]
Jul 19, 2019 22:57
Forum: Game Dev
Topic: Physics question
Replies: 52
Views: 1069

Re: Physics question

Thanks dodicat. No luck there. The drag & drop can take between 10 and 20 seconds to work but the drop is nowhere near where it should be. I will leave it and wait to see if anyone else has any issues. I don't want to waste your time so if no one else reports any issues then, probably, there is ...
by deltarho[1859]
Jul 19, 2019 21:42
Forum: Game Dev
Topic: Physics question
Replies: 52
Views: 1069

Re: Physics question

@dodicat I am having problems running some of your code. Your very first code is working fine as is you code where we can drag & drop one of three circles. However, every other code where we should be able to drag & drop either the red or green circle sees the CPU max out on a core, I have f...
by deltarho[1859]
Jul 18, 2019 20:54
Forum: Game Dev
Topic: Physics question
Replies: 52
Views: 1069

Re: Physics question

With sin(0) = 0, cos(0) = 1, sin(90) = 1 and cos(90) = 0 From second post with beta = 0 we have towards centre = F angular momentum = 0 This corresponds to BasicCoder2's fig. 5 With beta = 90 we have towards centre = 0 angular momentum = F This corresponds to BsicCoder2's fig. 4 fig. 3 corresponds w...
by deltarho[1859]
Jul 16, 2019 17:16
Forum: Game Dev
Topic: Physics question
Replies: 52
Views: 1069

Re: Physics question

The 'towards centre' force can be broken into x-y components, and we get:

dx = - F * Sin(beta) * Cos(beta) and dy = F * Cos(beta) * Cos(beta)

I reckon. <smile>
by deltarho[1859]
Jul 16, 2019 16:46
Forum: Game Dev
Topic: Physics question
Replies: 52
Views: 1069

Re: Physics question

No response so far, 40 views, so I will take a wild guess. http://deltarho.org.uk/Downloads/badidea.jpg Thrust will be split into two forces; One toward the centre of the saucer; the other as angular momentum - he says with such confidence. <laugh> We have Sin(90-beta) = (towards centre)/F So, towar...
by deltarho[1859]
Jul 16, 2019 12:23
Forum: Windows
Topic: InputBox() in console program
Replies: 34
Views: 722

Re: InputBox() in console program

@dodicat I am going to be really pedantic. <smile> Drop 'Setfocus( EditBox )' just after 'createmessagewindow(textmessage)'. I hate GUIs which don't pass the see-saw pivot test (Not always possible) so centre EditBox and the three buttons. The EditBox needs some 'breathing space' above it, so use a ...
by deltarho[1859]
Jul 16, 2019 8:14
Forum: Windows
Topic: InputBox() in console program
Replies: 34
Views: 722

Re: InputBox() in console program

I use AfxOpenFileDialog in Encrypternet. I have just done a quick search and found that 10 different Afx* are used in that application; If I had to rely on my knowledge of the SDK I would probably still be writing it. <smile>

Go to advanced search