|
Post by (X) on Feb 22, 2023 2:56:48 GMT 1
ChatGPT on Sjouke Hamstra...
|
|
|
Post by (X) on Feb 22, 2023 3:56:48 GMT 1
I asked ChatGPT: "Do you know what a hash type is in "GFA-BASIC 32"?"
I'd say that's pretty good!
|
|
|
Post by Roger Cabo on Feb 23, 2023 19:06:18 GMT 1
Can we create a new forum entry with ChatGPT and GFA BASIC 32?I was able to let write the first simple code in gb32. Of a gravity falling rectangle and damping back by 80%. Yes you can learn chatGPT to code in real GB32. Give him some examples and tell him to learn the syntax.. Here is the result. Dim x(4) As Double, y(4) As Double x(1) = 100 : y(1) = 100 x(2) = 200 : y(2) = 100 x(3) = 200 : y(3) = 200 x(4) = 100 : y(4) = 200
Dim cx As Double, cy As Double cx = (x(1) + x(2) + x(3) + x(4)) / 4 cy = (y(1) + y(2) + y(3) + y(4)) / 4
Dim i As Integer Dim vy As Double vy = 0
Do Cls cx = (x(1) + x(2) + x(3) + x(4)) / 4 cy = (y(1) + y(2) + y(3) + y(4)) / 4 For i = 1 To 4 Line x(i), y(i), x(i Mod 4 + 1), y(i Mod 4 + 1) Dim xtemp As Double, ytemp As Double xtemp = x(i) ytemp = y(i) RotatePoint xtemp, ytemp, cx, cy, 1 x(i) = xtemp y(i) = ytemp Next i 'Berechne neue Positionen und Geschwindigkeit aufgrund der Gravitation vy = vy + 0.1 For i = 1 To 4 y(i) = y(i) + vy If y(i) > 500 Then y(i) = 500 vy = -vy * 0.8 'Elastischer Stoß mit dem Boden End If Next i Line 0, 500, 1000, 500 DoEvents Pause 0.5 Loop Until MouseK
Sub RotatePoint(ByRef x As Double, ByRef y As Double, cx As Double, cy As Double, angle As Double) Dim rad_ As Double rad_ = angle * PI / 180 Dim xnew As Double, ynew As Double xnew = (x - cx) * Cos(rad_) - (y - cy) * Sin(rad_) + cx ynew = (x - cx) * Sin(rad_) + (y - cy) * Cos(rad_) + cy x = xnew y = ynew EndSub
|
|
|
Post by Roger Cabo on Jun 2, 2023 19:05:31 GMT 1
Unfortunately, I had to abort the attempt to teach ChatGPT GFABasic. The quasi long-term memory was shrunk. Strangely, after one day, some things were forgotten, and what was forgotten varied in different chats. VB6 is the only equivalent works closest.
|
|
|
Post by larrybtoys on Oct 6, 2023 14:02:43 GMT 1
It appears that ChatGPT got an upgrade and now understands GFA Basic 32. This is what it has to say about it:
Yes, I'm familiar with GFA Basic 32! It's a programming language, and the "GFA" stands for "Good, Fast, and Cheap," which were the goals of the original GFA Basic. GFA Basic 32 is an extended version of GFA Basic that supports 32-bit architecture. It's often used for creating applications and games on the Atari ST and compatible systems. If you have any questions or if there's something specific you'd like to know, feel free to ask!
I had it write a small snippet of code for me as well.
Enjoy!
|
|
|
Post by (X) on Oct 6, 2023 15:43:33 GMT 1
I've obtained some good hints from ChatGPT but: - it often misunderstands what I am asking and - sometimes gives outright wrong information such as the value of a Constant and - may "invent" functions that don't exist.
Still, this tool is a much more pleasant interface than most results from a Google search.
I certainly hope this will continue to improve.
|
|
|
Post by Roger Cabo on Oct 7, 2023 22:49:11 GMT 1
Hi X,
I use the chatgpt plus version.
If you like to solve some mathematics or quirky logic then let develop ChatGPT in Python.
Then there are 2 amazing options. 1) he can execute the code and run for testing and debug purposes. He's able to run line by line and track all variables for false computations and find bugs.
2) it's possible to let him draw an image with the result. Let's say you want to animate or compute any 2D graphic, he can draw the result.
And if it works well, then ask him to translate to vb6 or any other language code. The default version of ChatGPT is not able to work that well..but for sure the plus version is also not perfect.. but a lot better.
|
|