Basic Questions and Observations about Celx
Posted: 29.03.2006, 13:20
The followng is a discussion of some problems with Celx from my viewpoint. I'm offering this in the spirt of starting a discussion and maybe getting some explanation of points I'm still confused about. Bear in mind that most of this is based on my own limited experimentation and others may have more insight.
Let's start with the command "SetSpeed." Speed is the appropriate word because there's only one value, a scalar. Unfortunately this, by itself, makes no sense. We are actually setting a velocity vector in at specified direction but that direction is not defined in the documentation. My experimentation leads me to believe that what the documentation should say is that this command sets the velocity value of the x component of the orientation vector.
Constrast this with the command in Cel "move," which allows you to set a velocity vector (and is well-documented). Of course, you could duplicate this command in Celx by first setting the orientation and then calling "SetSpeed," but there is another problem. The look direction is in the direction of the orientation vector. You can change the look angle with LookAt in Celx but only to a position, which is not very useful. This means that the velocity vector (if you use this method) is tied to the look angle.
Cel, on the other hand, allows you full independent control of the camera which is well documented.
Now if one is only interested in writing toy programs in Celx this is probably all you need, but it ignores the most general problem where acceleration affects the full 3D velocity vector. It's as if the writers of Celx assumed that script writers were only interested in writing programs in which the universe had no forces. In my case I want the observer to "feel" the mass of a passing planet as a moving acceleration vector. I want an independent camera, not just one that can look at specified positions. There should be two vectors, one that represents the sum of all the forces on the observer, and another which is the direction the observer is looking.
Now the way to get around this is to ignore SetSpeed and use SetPosition but that means you have to write code that is already available in Cel, which is a bit crazy.
And then there is the lack of the equivalent comand to Cel's essential "orbit" which I've discussed elsewhere.
I believe that Celx is a great programming language but it needs better documentation and it needs to rethink its selection of basic commands that together form a useful set.
Henry
Let's start with the command "SetSpeed." Speed is the appropriate word because there's only one value, a scalar. Unfortunately this, by itself, makes no sense. We are actually setting a velocity vector in at specified direction but that direction is not defined in the documentation. My experimentation leads me to believe that what the documentation should say is that this command sets the velocity value of the x component of the orientation vector.
Constrast this with the command in Cel "move," which allows you to set a velocity vector (and is well-documented). Of course, you could duplicate this command in Celx by first setting the orientation and then calling "SetSpeed," but there is another problem. The look direction is in the direction of the orientation vector. You can change the look angle with LookAt in Celx but only to a position, which is not very useful. This means that the velocity vector (if you use this method) is tied to the look angle.
Cel, on the other hand, allows you full independent control of the camera which is well documented.
Now if one is only interested in writing toy programs in Celx this is probably all you need, but it ignores the most general problem where acceleration affects the full 3D velocity vector. It's as if the writers of Celx assumed that script writers were only interested in writing programs in which the universe had no forces. In my case I want the observer to "feel" the mass of a passing planet as a moving acceleration vector. I want an independent camera, not just one that can look at specified positions. There should be two vectors, one that represents the sum of all the forces on the observer, and another which is the direction the observer is looking.
Now the way to get around this is to ignore SetSpeed and use SetPosition but that means you have to write code that is already available in Cel, which is a bit crazy.
And then there is the lack of the equivalent comand to Cel's essential "orbit" which I've discussed elsewhere.
I believe that Celx is a great programming language but it needs better documentation and it needs to rethink its selection of basic commands that together form a useful set.
Henry