Game Development Community

TorqueBASIC: A Scripting Language

by TechLord · in General Discussion · 07/13/2004 (11:48 am) · 143 replies

I love C++ (Torque) and TorqueScript. However, I'm very fond of the BASIC syntax as it was my very first programming language.

I've used other game development 'languages' which used a BASIC syntax and found them relative easy to get started. BASIC Game Dev Languages also have a large customer base. I can see TorqueScript with a BASIC syntax beneficial for Torque in this regard.

Sometime in the unknown future, I'm going to write a TorqueBASIC to TorqueScript Converter or TorqueBASIC Compiler for Torque.

Thoughts wanted.
Page «Previous 1 2 3 4 5 6 7 Last »
#1
07/13/2004 (11:56 am)
That sounds like a great idea. Would help me out. I know basic but not C++.
#2
07/13/2004 (11:56 am)
I'D LOVE TO SEE A TORQUE BASIC SCRIPT !

The BASIC was my first language too, then I moved to Visual Basic. I'm a crappy C++ programmer, but I'm very fluent in VB. I bet I'm not the only one in this case, so a Torque BASIC to Torque Script would be a great help for a lot of people.
#3
07/13/2004 (12:08 pm)
I don't have torque yet, but I think BASIC would be awesome.
BASIC is my first language too.
#4
07/13/2004 (12:31 pm)
I used to be all about DarkBASIC before I came to GG and found out about TGE. Miss them days of apple IIe BASIC ;)
#5
07/13/2004 (12:49 pm)
That would rock! I know of several people who would snap up the TGE just like that if a BASIC syntaxed language were available. They are "C/C++ challenged"...
#6
07/13/2004 (1:14 pm)
Torque Basic would allow noob programmers (like me) to create games, however, will not allow advanced programmers to have the same type of control in a game.

I recommend connecting them so that when the Basic language gets to an error, it will check with C++ for what it will do.
#7
07/13/2004 (3:43 pm)
You might try Josh Ritter's TGE Python (not sure that's the name). I understand Python is a lot easier to understand than TorqueScript/C++.
#8
07/13/2004 (3:59 pm)
Replacing TorqueScript may sound like a good idea at first, but what people seem to forget is that doing that would mean you have to rewrite pretty much all the existing scripts for it to be of any use, especially to newbies. That is an extremely huge and tedious job.

T.
#9
07/13/2004 (4:27 pm)
I think this would be a step backwards. If we must have another scripting language, lets implement Lua.

http://www.lua.org/
#10
07/13/2004 (4:29 pm)
Lau

There we go!
#11
07/13/2004 (5:48 pm)
I'm sorry, but I just don't see the point.

I mean, I have more experience with using BASIC than I do with using C or C++ but TorqueScript only has about 20 keywords. The bulk of any script is made up of functions, the syntax of which wouldn't change if used with BASIC.

Most modern BASIC dialects are similar to C anyway, or at least similar enough for the transition from one to the other to be much easier than it was in the days of BASIC-A or GWBASIC.
#12
07/13/2004 (6:01 pm)
Yeah, I mean that'd be cool Frank and I love BASIC too but Torque Script itself isn't that hard in the first place. Heck even the C++ engine code isn't that tough to figure out although you don't even need to mess with that to make a game with Torque. If you make it I'm sure people would use it but one of the great things about Torque is learning how a "AAA" game engine works and expanding your horizons. If you pick up Ken's book it's really not that tough.
#13
07/13/2004 (9:21 pm)
Have you guys seen PyTorque?
#14
07/13/2004 (9:41 pm)
I have purchased 3DGPAi1 and it is indeed a great resource and shedding much light on Torque. Great work Ken!

My prior experience with DarkBasic, BlitzBasic and others 'Game' Basics are motivators. The appeal of a BASIC Syntax would lure 1000s of inspiring Game Developers to Torque.

In my opinion, the learning curve with TorqueScript is slightly steeper than some 'Game' BASIC out there. Even with small set of keywords, working with console commands, datablocks, object methods require some getting use to.

TorqueBASIC will be an option. A Developer will always have the option to dive in the native TorqueScript or C++ engine code. I have already gone to some extent to start catagorizing a TorqueBASIC Command Set. Expression and conditional loops will use a syntax similar to most BASICs.
for loop = 1 to 10
//do something
next

if a=1 and b=2 then c=c+1
#15
07/13/2004 (9:56 pm)
I would absolutely LOVE to see an implementation of BASIC that would be a scripting language for Torque. I think it would open up the world of Torque to many, many more users.

-Jeff Tunnell GG

Edit: Python and Lua are NOT substitutions for BASIC. Programmers that are already good at what they do make the assumption that they are, but they are not as simple. There are many people that have already learned VB that are potential users of Torque. Keep in mind that people can learn a LOT and have a lot of fun even if they can only access a portion of Torque. Just look at the response to Melv's Torque 2D. The more we can lower the bar, the more fun people will have with the engine.
#16
07/13/2004 (10:03 pm)
As a fan of BASIC from ages ago (though I've pretty much abandoned it completely) I think TorqueBASIC would be interesting. Problem is... you'd have to attract someone to doing TorqueBASIC that knows C++ (well, Torque in general :-) but that is still interested in BASIC, and has the time to create a BASIC implementation. No small set of problems there :-) But it could be cool... of course, I know this lazy programmer who keeps talking about doing AMOS for the PC who could just use Torque as the base and solve the problem... ;-) (Quick ribbin on Tom Bampton from some of our conversations in IRC ;-)
#17
07/13/2004 (11:10 pm)
Jeff, are you implying that I am already good at what I do? :P

Actually, what might be an interesting project would be writing a BASIC interpreter in TorqueScript. It ought to be a lot faster to get up and running than a C++ integration, and it would be immediately compatible with the existing Torque Demo. It should be fairly easy to develop, since TorqueScript already has some powerful metaprogramming functionality. I think a dedicated script hacker could turn out a prototype in a week or two. And it would be a nice testament to Torque's flexibility. ;)

(The reason I brought up PyTorque is because it's an example of how to integrate a different language into Torque; for either a Lua conversion or a Basic language project it's probably got a lot of good lessons. Personally, I think that Lua and Python are both subpar compared to TorqueScript for programming complex, networked games. It's only much higher up the game complexity curve that it really becomes worthwhile to switch to Lua/Python/Java - ie, for a big MMO project it might be worth it, but for an FPS or other non-gargantuan game, I think that TorqueScript is more than sufficient and lot better suited to the task.)

Interesting fact - before I started working with Torque, I spent many years doing VB development.
#18
07/13/2004 (11:23 pm)
100 PRINT "HELLO WORLD"
200 GOTO 100
#19
07/14/2004 (12:19 am)
Yeah, I agree that the 'concept' behind the datablocks and the object oriented approach are probably a stretch for a lot of people who just like to sit down, code the logic, and then watch it work. I happen to be liking what I'm learning with Torque at the moment but of course I did spend my fair share of time with DarkBASIC and Blitz3D. I learned C++ before I ever coded BASIC on a PC though but the truth is I didn't really fully understand what I could accomplish with it and object orientation before I got a lot of experience with BASIC game development. Now I'm coming full circle back to C++ with a much greater understanding of why it's a cool language and why object orientation is nice.

Still that's me personally, if Torque did have a BASIC implementation it'd surely open up the gates to more users and also the spread of ideas. That's one thing that I really like about BASIC communities is how many different little algorithms they just throw around and share for the heck of it because you can code the concepts with relative ease. Good luck with this concept.
#20
07/14/2004 (12:36 am)
In my opinion, the true power of Visual Basic for developers-- and the reason it's so popular-- lies not so much in the language itself, but in two other areas: its easy to understand, simple to use programming environment, and its mountain of easy to follow documentation.

Surely, BASIC syntax is nice and understandable, that's a benefit. But VB got so popular not so much because it used BASIC, but because of the awesomely powerful and easy to use Form-construction interface the IDE implements, and the simple to understand documentation that has always accompanied it.

Indeed, BASIC, the language itself, was around for a very long time, but it wasn't until Microsoft's Visual Basic, with its superb IDE and excellent documentation, that so many people started using it.

To me, having an even easier to understand scripting language for Torque would be nice. However, the real pay-off would come in the development of a VB-like programming IDE, and accompying tutorials, references, guides, and examples.

Having a development environment such as VB's would be the best way to enable VB developers to start using Torque and having fun.

Torque has a good start in this area-- it's GUI and World Editors offer much more than many other engines, when it comes to flexibility and ease of use. Enhancing these editors while making them easier to use, and integrating a script-editing environment would put Torque development within grasp of many more people. Can you imagine if it were anywhere near as easy to build simple games with Torque as it to build simple Windows, forms, or database applications with VB? And of course having accompanying quality documentation anything like what is available to VB developers would be a huge boon as well.

Maybe one day such a development environment will exist for Torque. It would be an interesting and useful project to work on.. but of course there are many interesting and useful projects to work on. :)
Page «Previous 1 2 3 4 5 6 7 Last »