BSL:BFW Scripting Language: Difference between revisions

From OniGalore
Jump to navigation Jump to search
m (→‎Knowledge database: BSL:IGMD to IGMD)
(rewriting)
Line 1: Line 1:
== Bungie Scripting Language (or BSL) ==
'''Bungie Scripting Language (or BSL)''' is what [[BSL:Scripts|Oni scripts]] are written in. It's a programming language akin to C with some shell-script features as well, although it is far more limited in scope than a "real" programming language, as it was designed only to move events forward in the game, not to build programs.
is what [[BSL:Scripts|Oni scripts]] are written in. It's a programming language akin to C with some shell-script features as well.


== Editing Scripts ==
==What Are Scripts?==
Scripts are the files that dictate the in-game processes in Oni, which include level logic, environment effects, as well as cutscenes. They are the *.bsl files inside the folder ...Oni/GameDataFolder/IMGD/. By editing scripts, you can alter how the game plays.


==Editing Scripts==
Scripts can be edited with and word-processing program, such as NotePad. They can be edited simply by typing inside the file.
Scripts can be edited with and word-processing program, such as NotePad. They can be edited simply by typing inside the file.
Script files can be generated by creating a *.txt document, then changing the extension from txt to bsl.
Script files can be generated by creating a *.txt document, then changing the extension from "txt" to "bsl". To learn BSL by example, you can read the .bsl files in Oni and draw connections to the events in the game that were produced by those scripts. For a primer in writing BSL, see the Tutorials section below. For a thorough course in BSL, see the Knowledge Database below.


== Scripted Mods ==
==Scripted Mods==
 
Scripted Mods are great examples of what can be accomplished by editing scripts. They edit the *.bsl files to create interesting, and often amusing results. They can change everything from the fog, to how the characters and level interact. However, they cannot add characters or change the level layout, only its contents, as they are handled by the Binaries. Information on [[OBD: Oni Binary Data]] . They are great examples of what can be achieved simply by typing into a file. The possibilities are simply endless.  
Scripted Mods are great examples of editing scripts. They edit the *.bsl files to create interesting, and often amusing results. They can change everything from the fog, to how the characters and level interact. However, they cannot add characters or change the level layout, only its contents, as they are handled by the Binaries. Information on [[OBD: Oni Binary Data]] . They are great examples of what can be achieved simply by typing into a file. The possibilities are simply endless.  


Probably the best specimens of Scripted Mods are the [[ONK:OTA|Oni Team Arena]] scripts. Based on an idea for multiplayer Oni, and inspired by Unreal Tournament, they augment Oni's hand-to-hand combat and gunplay integration with a scoring system much like Unreal Tournament's DeathMatch. More information about this exciting project can be found at the page listed above.
Probably the best specimens of Scripted Mods are the [[ONK:OTA|Oni Team Arena]] scripts. Based on an idea for multiplayer Oni, and inspired by Unreal Tournament, they augment Oni's hand-to-hand combat and gunplay integration with a scoring system much like Unreal Tournament's DeathMatch. More information about this exciting project can be found at the page listed above.
Line 15: Line 15:
All other scripted mods are basically anything you can imagine. From free-for-all arenas to objective based missions and enhancements of the original level, they spice up the games original levels and provide a more exciting experience to those who have finished the game. They keep the game alive, outside of its original levels.
All other scripted mods are basically anything you can imagine. From free-for-all arenas to objective based missions and enhancements of the original level, they spice up the games original levels and provide a more exciting experience to those who have finished the game. They keep the game alive, outside of its original levels.


Downloads of OTA Mods are available at the OTA page. ([[ONK:OTA|Oni Team Arena]])
Downloads of OTA Mods are available at the [[ONK:OTA|Oni Team Arena page]].
Downloads for other scripted mods mave been gathered here : [http://your-mom.oni2.net/Downloads.htm Script Download Page] [http://script10000.oni2.net/scripts.html and here.]


== What Are Scripts? ==
Downloads for other scripted mods mave been gathered here: [http://your-mom.oni2.net/Downloads.htm Script Download Page] and [http://script10000.oni2.net/scripts.html here.]


Scripts are the files that dictate the in-game processes in Oni, which include level logic, environment effects, as well as cutscenes. They are the *.bsl files inside the folder ...Oni/GameDataFolder/IMGD/. By editing scripts, you can alter how the game plays.
==[[BSL:Tutorial|Tutorials]]==
For the practical minds who don't care (too much) about the theory:
*Wanna make minor (yet cool-looking) changes to the original level logic?
*Wanna script a "patch" that's effective in every level but doesn't affect the original logic?
*Wanna create completely new level logic from scratch? [[BSL:Tutorial/Scratch|Here you are.]]


===Knowledge database===
==Knowledge Database==
For the theoretical minds, everything you'll ever need to know about BSL
*[[BSL:Statements|Statements]]
*[[BSL:Statements|Statements]]
*[[BSL:Variables|Variables]]
*[[BSL:Variables|Variables]]
Line 29: Line 31:
*[[BSL:Operators|Operators]]
*[[BSL:Operators|Operators]]
*[[BSL:Data|Data types]]
*[[BSL:Data|Data types]]
More on modding basics
*[[BSL:Inventory|Inventory management]]
 
Documentation that describes the locations that BSL scripts reside in:
*[[IGMD|IGMD folder]]
*[[IGMD|IGMD folder]]
*[[IGMD/global|global folder]]
*[[IGMD/global|global folder]]
And some random (so far) useful pages
*[[BSL:Inventory|Inventory management]]
===[[BSL:Tutorial|Tutorials]]===
For the practical minds who don't care (too much) about the theory.
*Wanna make minor (yet cool-looking) changes to the original level logic?
*Wanna script a "patch" that's effective in every level but doesn't affect the original logic?
*Wanna create completely new level logic from scratch? [[BSL:Tutorial/Scratch|Here you are]]


==Overview==
==Syntax Overview==
{| border="1" cellpadding="5" cellspacing="0" align="center"
{| border="1" cellpadding="5" cellspacing="0" align="center"
|+'''BSL syntax overview table'''
|+'''BSL syntax overview table'''

Revision as of 17:13, 29 January 2008

Bungie Scripting Language (or BSL) is what Oni scripts are written in. It's a programming language akin to C with some shell-script features as well, although it is far more limited in scope than a "real" programming language, as it was designed only to move events forward in the game, not to build programs.

What Are Scripts?

Scripts are the files that dictate the in-game processes in Oni, which include level logic, environment effects, as well as cutscenes. They are the *.bsl files inside the folder ...Oni/GameDataFolder/IMGD/. By editing scripts, you can alter how the game plays.

Editing Scripts

Scripts can be edited with and word-processing program, such as NotePad. They can be edited simply by typing inside the file. Script files can be generated by creating a *.txt document, then changing the extension from "txt" to "bsl". To learn BSL by example, you can read the .bsl files in Oni and draw connections to the events in the game that were produced by those scripts. For a primer in writing BSL, see the Tutorials section below. For a thorough course in BSL, see the Knowledge Database below.

Scripted Mods

Scripted Mods are great examples of what can be accomplished by editing scripts. They edit the *.bsl files to create interesting, and often amusing results. They can change everything from the fog, to how the characters and level interact. However, they cannot add characters or change the level layout, only its contents, as they are handled by the Binaries. Information on OBD: Oni Binary Data . They are great examples of what can be achieved simply by typing into a file. The possibilities are simply endless.

Probably the best specimens of Scripted Mods are the Oni Team Arena scripts. Based on an idea for multiplayer Oni, and inspired by Unreal Tournament, they augment Oni's hand-to-hand combat and gunplay integration with a scoring system much like Unreal Tournament's DeathMatch. More information about this exciting project can be found at the page listed above.

All other scripted mods are basically anything you can imagine. From free-for-all arenas to objective based missions and enhancements of the original level, they spice up the games original levels and provide a more exciting experience to those who have finished the game. They keep the game alive, outside of its original levels.

Downloads of OTA Mods are available at the Oni Team Arena page.

Downloads for other scripted mods mave been gathered here: Script Download Page and here.

Tutorials

For the practical minds who don't care (too much) about the theory:

  • Wanna make minor (yet cool-looking) changes to the original level logic?
  • Wanna script a "patch" that's effective in every level but doesn't affect the original logic?
  • Wanna create completely new level logic from scratch? Here you are.

Knowledge Database

Documentation that describes the locations that BSL scripts reside in:

Syntax Overview

BSL syntax overview table
BSL separators
; , # "
{ } ( )

Click on a separator for details

BSL operators
+ - = !
and or eq ne
< > <= >=

Click on an operator for details

BSL keywords
at float if repeat string
bool for int return using
else fork iterate schedule var
every func over sleep void

Click on a keyword for details