Tuesday 22 May 2012

Application Software and Languages

Application Software Language - JavaScript

What are the types of Application Software Languages?

There are several types of languages which are used in application software and games which I shall be looking at in depth in terms of how they are created and what they provide. Languages are needed as the background code for several different types of applications or softwares which may need a dedicated language to run what is needed. They're several differences between certain languages with some of them being faster than other, other languages not being able to run certain things such as games or advanced applications and some which are designed to work on certain platforms such as JavaScript can run on all devices if coded to do so.

Application software languages have their differences in terms of what they can output meaning that Visual basic can output simple windows applications, where as C# can output more complex applications for a wider platform, such as basic games and or applications. Along with languages they're scripts which are used as the background to most complex games and their game engine which runs the game, this means instead of using a standard language, it has it's own script which is wrote & designed through the games engine, typically known engines would be; Frostbite 2, Crytek 3, Unreal Engine & Quake engine. All of these have their own dedicated gaming language to use and program the games which are run through them, I shall be looking at them closely to see what they have created over time.

The languages & Scripts I shall be looking at:

Interpreted languages for games -
  • Java
  • C# Programming Language
Interpreted languages are the slowest out of all the types available, this is due to when it is read and processed each line of code is checked and processed one after another meaning that if there is a loop in the programming code, it will continuously check the same lines of code over and over. This is not beneficial for games as if the code is slow to read it means that the game itself will take a long time to load and the game play will be sluggish compared to other types of languages. 

Java is a interpreted language meaning that each line of code that is written in Java will slow the game down considerably, most games which are written in Java are for mobile phones as most smart phones use Java as a basis for their system meaning the games can be implemented quite swiftly, however they're many drawbacks to Java games. The biggest drawback is that if the platform using the game needs to be quick and processing otherwise the game will run very slow due to it needing to process each line every time. This is a drawback for many handheld devices and older computers as the language itself is a simple and effective way of producing and playing games however if they cannot process the games quick enough, the game will run very slowly. 

C# is another language used to create simple games either without a GUI interface or without one meaning that mouse and keyboard can be switched between depending on the style of the game. Games created within the C# language can be made to be single player or in some cases developed to work across a network or the internet for people to play together. C# is another interpreted language which means that when it is run, it will takes much longer than other languages, as each line of code is processed line by line. Games which are well known and have been created through C# are; Brikwars, Chessbin, HuoChess & MonoGame all of which have been created using C# language. 

Compiled languages for games -
  • C++
These are faster to process and are typically used for more power extensive games which need fast processing to run and display. Compiled languages are much quicker than interpreted because they don't need each line read each and every time, when the language has been compiled it is faster to process as the code lines are compressed together and made easier to read. However once this has been compiled the code cannot be changed or modified as the lines of code will be put together and made unchangeable once compiled, however once it has been completed it will run up to 6x faster than the interpreted language which Java and C# use when compiled. 

Beside the use of gaming C++ has a formidable role in application design and software, with it being used to develop and design advanced programs for use on mobiles, computers and games consoles. It is a world wide used language that incorporates the use of simple scripting and language to define and create complex programs used across multiple platforms.

Object-oriented - 
  • C++
  • C#
  • Java
  • J2SE
Object oriented programming differ slightly from compiled and interpreted as the other two write each line of code as it comes to create the program or software, however with object oriented the different parts of code are wrapped within objects and then called for when they are needed. This type of programming allows for parts of code to be put into their own 'object' and called for later on during the programs runtime, this in affect allows for a quicker functionality of the program. This objects are normally put in place to run certain events at certain times of the runtime instead which would be a loading screen within a game, the next part of a level or if anything is meant to load during a level such as a cut scene. 

Object oriented programming is used in all languages and scripts and is the best way to manage strings and strands of code when they are being written. Once these objects have been created and the code has been stored within them it can then be linked to the rest of the code and or used with other objects to create a string of objects to run during runtime of the software/application. Each object has the ability to receive, send and process their own messages between other objects whilst in operation, these can then be defined as their own 'sub-program' where they closely link with the other objects around them. 

Scripting -
  • UnrealScript
  • QuakeC
  • Maya
Scripts are used in the background of running games and are normally entwined with complex game engines to run them. They are short and can be quickly designed and wrote to carry out advanced actions such as running a cut scene or defining a runtime event within a game, they are used to carry out events within the game engine such as rendering a certain area or lighting to switch on. Scripts such as the UnrealScript, QuakeC & Maya are all written to carryout runtime events within a game or program.

Scripts are normally used to carry out the events of AI & game play meaning that when the person is playing the game the scripts activate how the AI work and how the environment react to the players movement. For example if a person was playing a shooting game, the basis of the scripts would be defined to attack the player when they have entered a certain area or done a certain task. This is how events are carried out in real time during the runtime of the game as the scripts will be written to react to how the person is playing. They are short and kept simple so that the processing does not take a long time, this means that when its running it doesn't lag as much opposed to other methods of programming like interpreted.