ChatGPT working with PlayCanvas!

Hey!

I was playing around with Chat GPT and tried to ask coding questions about playcanvas, now when I used it I’ve asked about stuff that I already knew how to implement and noticed that it was coming up with ultra simple and unlikely to work solutions, like I asked how to register a click on a 3D entity in the level, and it’s solution was to just use the this.entity.onClick() feature, or when I asked how to ray trace from the camera, it said to use app.system.camera.pick(app.cursor.position)

Now am I missing something here or are those functions in the engine, but regardless even if they’re not, would be amazing to understand if in the future it could be used as a tool to find solutions?

If you expert could have a got at it, that would be amazing!

Hi @Lux87 and welcome,

@yaustar on Discord was doing some experiments with Chat GPT, it was quite fun.

But both suggestions you shared above aren’t right agreed:

  • There is no onClick method available on entities.
  • There is no app.system property (it’s systems, but there is no camera pick system).

There is future in this area though for certain!

I’ve been looking at it recently. It’s not accurate enough that I want to set it loose tbh. It’s useful to those that can work around the 90% working code but not for beginners or those new to the platform

1 Like

Yeah I thought so, seemed too good to be true :smile: Thanks for your replies!

Tried making a custom GPT that takes the latest stable engine code from github and a reference to official documentation if you wanna try (needs PRO account):

https://chat.openai.com/g/g-jdsb0e7Fb-playcanvas-pro

It, well, sort of works at least. But give it a try. Will not replace a programmer or anything. But a good help for lazy devs like myself.

2 Likes