When does "scripting" become "programming"?

General discussion about LÖVE, Lua, game development, puns, and unicorns.
User avatar
miko
Party member
Posts: 410
Joined: Fri Nov 26, 2010 2:25 pm
Location: PL

Re: When does "scripting" become "programming"?

Post by miko »

MarekkPie wrote:These terms have always thrown me off, and it's frustrating, because it seems everyone else learns it through osmosis. People talk about "adding scripting into games" so that "non-programmers can add some logic." To me, this doesn't make sense, and it seems to imply that scripting is a derisive term for "real programmers."
I think this is a historical term. At the beginning all games were written in assembler or C (because the computers were much slower than today), and their code was highly optimized (and so, had to be compiled/tested/debugged/distributed). Then some games allowed changing something in their logic by using config files, then scripts. The main difference was that the scripts could be changed in real-time, without using SDK (so "for non-programmers"), but they were simple languages, without any advanced constructs, and without low-level API. In fact, often these were just some keywords with some list of arguments allowed, not a real language. I would say they were extension of simple configuration files.

The same goes in unix: there were programs (compiled) written by programmers, and there were scripts (using shells), often written by the system administrators.

Now, as the computers became more powerful, so did the scripting languages. Lua is no more a simple bash. OTOH, people tend to like some dynamic properties of languages (garbage collection, variable types, etc.), so even the "compiled programs" look more like scripts today. So, programs and scripts were in different worlds once, but today they are much closer to each other, so the distinction can be difficult.

I am using lua for some scripting (usually in linux system), but when I write for love, especially when using object oriented design, and calling low-level API (which love offers), I am definitely programming in lua.
My lovely code lives at GitHub: http://github.com/miko/Love2d-samples
User avatar
vrld
Party member
Posts: 917
Joined: Sun Apr 04, 2010 9:14 pm
Location: Germany
Contact:

Re: When does "scripting" become "programming"?

Post by vrld »

miko wrote:I think this is a historical term. At the beginning all games were written in assembler or C (because the computers were much slower than today), and their code was highly optimized (and so, had to be compiled/tested/debugged/distributed). Then some games allowed changing something in their logic by using config files, then scripts. The main difference was that the scripts could be changed in real-time, without using SDK (so "for non-programmers"), but they were simple languages, without any advanced constructs, and without low-level API.
Lisp is older than C and Lisp programs can be changed without recompiling them. You can even change Lisp programs while they run. Lisp basically invented live coding before it was cool. Also, Lisp has - and continues to have - the most advanced programming constructs there are. Just look at common lisp's loop for construct (you can basically write English sentences and the thing figures out what to do) or the object system.
I have come here to chew bubblegum and kick ass... and I'm all out of bubblegum.

hump | HC | SUIT | moonshine
User avatar
ston
Prole
Posts: 21
Joined: Fri Jan 27, 2012 9:53 am
Location: Holt, a small village in Wiltshire. We have cider!

Re: When does "scripting" become "programming"?

Post by ston »

MarekkPie wrote:If the question is invalid, then why did you answer it?
I didn't; I clarified it.

[edit: I felt this deserved some further detail of what I meant]

A computer programmer was originally a person who used to physically punch instructions into a machine, bit-by-bit, thereby programming it. Literally flipping switches to set bits.

An analogy to this would be the computer operator; this was originally a person who used to manage the input and output media, schedule and control job runs, etc. The tasks performed by a computer operator have now been completely replaced by software: the Operating System.

One could therefore argue that the task of actually programming the computer is performed these days by the compilers, linkers, interpreters, run-time libraries and operating systems. So nobody really programs computers any more; they've become far too complex for a human being to manage this task.

If the meaning of the word 'programming' has changed to mean 'coding', then writing code in any language, be it a scripted or compiled language could be considered to be programming. It just depends on what that word actually means to you.
Last edited by ston on Tue Jan 31, 2012 12:16 pm, edited 2 times in total.
User avatar
bartbes
Sex machine
Posts: 4946
Joined: Fri Aug 29, 2008 10:35 am
Location: The Netherlands
Contact:

Re: When does "scripting" become "programming"?

Post by bartbes »

As far as I'm concerned scripting and programming doesn't really have anything to do with the language.
Scripts are, in my opinion, smaller pieces of code that either do trivial things, automation, or provide a way for a 3rd party (/users) to change parts of your program.
User avatar
GijsB
Party member
Posts: 380
Joined: Wed Jul 20, 2011 10:19 pm
Location: Netherlands

Re: When does "scripting" become "programming"?

Post by GijsB »

making things in a engine = programming
making things in a engine in a engine = scripting

._.?
User avatar
thelinx
The Strongest
Posts: 857
Joined: Fri Sep 26, 2008 3:56 pm
Location: Sweden

Re: When does "scripting" become "programming"?

Post by thelinx »

That's not what he said at all.
User avatar
runyonave
Prole
Posts: 27
Joined: Tue Dec 06, 2011 2:06 am

Re: When does "scripting" become "programming"?

Post by runyonave »

To me, writing code on LOVE is programming, not scripting. When you write a game, you are writing the collision detection, A.I., game states, save system, game loops etc. Your basically creating a game from scratch. Now compared to writing a game in C++, in LOVE you don't specifically set pointers, or need to worry about memory leaks (unless you do something ridiculous in love that would slow down the computer). You also don't need to bother with coding for video cards. These are all handled by LOVE. You just worry about the actual code for the game.

Now a scripting language could be something like JavaScript. When you make a dynamic website you use HTML and PHP. If you want to make a menu that expands when a user hovers over it, you can use JavaScript. JavaScript acts as an extension to HTML and PHP. In this case, it isn't a necessity but adds more content and compliments the website.
User avatar
Robin
The Omniscient
Posts: 6506
Joined: Fri Feb 20, 2009 4:29 pm
Location: The Netherlands
Contact:

Re: When does "scripting" become "programming"?

Post by Robin »

runyonave wrote:Now a scripting language could be something like JavaScript. When you make a dynamic website you use HTML and PHP. If you want to make a menu that expands when a user hovers over it, you can use JavaScript. JavaScript acts as an extension to HTML and PHP. In this case, it isn't a necessity but adds more content and compliments the website.
But that doesn't have anything to do with JavaScript. I often use Lua like the way you described, so does that make it a scripting language? Also, you can make games and applications in JavaScript just like you can make them in Lua (in fact, I'm working on a text adventure game written completely in CoffeeScript (which compiles to JavaScript)).`
Help us help you: attach a .love.
User avatar
runyonave
Prole
Posts: 27
Joined: Tue Dec 06, 2011 2:06 am

Re: When does "scripting" become "programming"?

Post by runyonave »

Robin wrote:
runyonave wrote:Now a scripting language could be something like JavaScript. When you make a dynamic website you use HTML and PHP. If you want to make a menu that expands when a user hovers over it, you can use JavaScript. JavaScript acts as an extension to HTML and PHP. In this case, it isn't a necessity but adds more content and compliments the website.
But that doesn't have anything to do with JavaScript. I often use Lua like the way you described, so does that make it a scripting language? Also, you can make games and applications in JavaScript just like you can make them in Lua (in fact, I'm working on a text adventure game written completely in CoffeeScript (which compiles to JavaScript)).`
Sorry I should have been more clear, I didn't mean to say that JavaScript is a strictly scripting language, it isn't. I know you can a do a ton of stuff with JS, I'm a web developer so I use JS/JQuery on a daily basis. I meant that within the context of my example (using JS to write an expanded menu function on top of HTML/PHP) it could be considered scripting. But as you stated, you're making a text adventure game using CoffeeScript and JS. In that case, I would call it programming because you are applying the full functionality of CS and JS to create something.
owen
Prole
Posts: 4
Joined: Wed Feb 08, 2012 1:39 pm

Re: When does "scripting" become "programming"?

Post by owen »

i don't think this is something you need to worry about because its all "programming". Using a calculator is a form of programming. I think scripting is just used to represent writing a program in a language that is interpreted instead of compiled. Its why Javascript is called "Java"-"Script" instead of just "Java" (even though its relatively the same). There is nothing derogatory about it the name its just a class. Programming on a interpreted language is most times HARDER than programming in a scripting language because the error checking is stronger which is probably why scripting is regarded as the easier of the two. Once you start coding in a compiled language you are no longer scripting. Don't worry about it.
Post Reply

Who is online

Users browsing this forum: Ahrefs [Bot] and 5 guests