Author: X39
Author Website: https://github.com/X39/ObjectOrientedScripting

Version: 0.8.0 Alpha

Short description: A C# Project to bring SQF to the next level.

Date: 2016-04-02 16:38


Comments: (0)
Rating:



 

ObjectOrientedScripting

by
X39


Description:
What is ObjectOrientedScripting (OOS)?
OOS is a new script language that will be translated to native SQF meaning that it is 100% compatible with SQF.
It makes it possible to develop modifications in an ObjectOriented way (thats why it is callen ObjectOrientedScripting ... ok i admit ... that was too obvious :P)

Why would we want to stop using SQF?
well ... its a quite complex thematic where most of it is personal choice thus i cant rly help you with this questions
there is just one thing i can tell you:
ObjectOriented Programming (in this case Scripting) has the benefit that youre (in theory) faster in developing scripts
for some comparison, please read this: http://vbsoftwaredeveloper.blogspot.de/2012/05/procedual-programming-vs-object.html


Installation / Usage:
Warning:
Exe files can harm your PC! Before running this you should make sure you understand the risks!
Armaholic is in no way responsible if this file causes any damages what so ever! Downloading and installing this program is at your own risk.
We have run anti-virus tools on the included exe and found no issues, this is however not a guarantee so precaution should be taken while installing this!

Download the setup.exe and execute the Wrapper.exe application using the command line.


Known issues:
Passing an object of the same class which you are in right now will result in
the object getting assigned an invalid type
((Internally it will ref to the function which is for sure nonsense ...
however ... harder to fix then it might sounds in first place due to the
lower logic behind it))
(Not rly an issue but more of a note) currently only idents are allowed to be
callen. Thus you cannot call from an expression
following would be invalid:
(new foobar()).foo()
due to the fact that it is the following:
<EXPRESSION>.<IDENT><FUNCTIONCALL>
Casts currently do not check if given object is kind of cast target thus you
can enforce invalid object types
Downcasting has to be done explicit
casting to an object having a template requires you to write it like so (example shows array cast):
< array >yourVariable
creating a new template object which gets another template object as kind requires you to write it like so (example shows array in another array):
new array< array >()


Notes:
Interfaces are temporary disabled as function arguments due to missing idea (yes ... no idea) about how to implement em with a minimum performance loss


Links:
GitHub
Changelog:
v0.8.0-ALPHA
|- stdLib: Added interface ::std::ISerializable
|- stdLib: Added ::std::Vehicle(string, vec3) constructor
|v- stdLib: Added `using ::std::Tupel`
||- Added Tupel2<T1, T2>
||- Added Tupel3<T1, T2, T3>
||- Added Tupel4<T1, T2, T3, T4>
|\- Added Tupel5<T1, T2, T3, T4, T5>
|- Compiler: ReEnabled (& implemented) interfaces
|- Compiler: Fixed TryCatch variable is not getting printed
|- Compiler: Changed how virtual functions are adressed
|- Compiler: Changed where object meta data is located
|- Compiler: Fixed issue in switch
|- Compiler: Fixed NPE in Idents on LNK errors
\v- Compiler: Only one PreInit function is allowed now
\- Added new Linker exception LNK0060

v0.7.4-ALPHA
|v- Compiler: Fixed error in PreProcessor preventing some macros to work
|v- Compiler: Fixed define compiler flag
|v- Compiler: Added internal defines:
||- __VERSION <-- Contains current compiler version
||- __NEXCEPT(MSG) <-- Wrapper for Exception Object
|\ Only working in Native Functions
|- Compiler: `async` attribute functions now have to be of type script
|- Compiler: Added `inline` attribute to functions
| static inline [ async ]
| ( ) [ throwing ] {...}
|- Compiler: Added `throwing` attribute to functions
| throwing is required when using the "throw" operation.
| functions that call such a function but do not catch the
| potential exception will generate a warning
| Syntax:
| static [ inline | external ] [ async ] [ virtual ]
| ( ) throwing {...}
|v- Compiler: Added internal object Exception (extendable for custom)
||- catch now has to use Exception type
|\- throw now has to use Exception type
|v- Compiler: updated vec3 (thx to Zeven90`s PR #48)
||- new constructor `vec3(array)`
||- new member function `vec3 add(vec3 other)`
||- new member function `vec3 diff(vec3 other)`
||- new member function `vec3 dot(vec3 other)`
||- new member function `vec3 cross(vec3 other)`
||- new member function `scalar cos(vec3 other)`
||- new member function `scalar magnitude()`
||- new member function `scalar magnitudeSqr()`
||- new member function `vec3 multiply(scalar n)`
||- new member function `scalar distance(vec3 other)`
||- new member function `scalar distanceSqr(vec3 other)`
|\- new member function `vec3 normalized()`
|- stdLib: Updated ::std::Marker to use vec3
|- stdLib: Updated ::std::base::VehicleBase to use vec3
|v- stdLib: ::std::base::VehicleBase (thx to Zeven90` PR #48)
|\- Fixed error in `::std::Config getConfigEntry()`
|v- stdLib: ::std::Man (thx to Zeven90` PR #47)
||- Added enum ::std::Man::VisionMode
||- Fixed locality on `void disableAI(AiSection)` (throws now)
||- Fixed locality on `void enableAI(AiSection)` (throws now)
|\- Updated enum ::std::Man::AiSection to 1.56
\v- stdLib: ::std::Group (thx to Zeven90` PR #47)
| Fixed locality on `void delete()` (throws now)
| Added `void join()`
\ Added `::std::Man getLeader()`

0.7.3-ALPHA
|v- Compiler: Added `deref <ident>` operation, returns SQF name of given
|| Non-Native function (virtual functions are not allowed too)
|| or of given static variable
||- Added new Linker exception LNK0052
|| "Invalid Operation, Native functions are not derefable"
||- Added new Linker exception LNK0053
|| "Invalid Operation, Virtual Functions are not derefable"
||- Added new Linker exception LNK0054
|\ "Invalid Operation, Non-Static Variables are not derefable"
||- Added new Linker exception LNK0055
|\ "Invalid Operation, using this in static functions"
|v- Compiler: rewrote Expression code & EBNF
||v- Compiler: Expressions get parsed according to following precedence
|||- First: "+" | "-" | "*" | "/"
|||- Second: ">=" | "<=" | "==" | "<" | ">"
||\- Third: "&&" | "||"
||- EXPOP `==` is now using isEqualTo
||- removed EXPOP `===`
||- removed EXPOP `&`
|\- removed EXPOP `|`
|- Compiler: added `bool array<T>::contains(T)` function
|v- stdLib: Added missing functions to ::std::Marker
||- string getText()
|\- void setText(string)
|- stdLib: Fixed ::std::Man constructor not returning objects
|v- stdLib: Altered how ::std::Group is working
||- Removed ::std::Group::createGroup*() functions
||v- stdLib: Added ::std::Side class
|||- Member Function: ::std::Side asEast()
|||- Member Function: ::std::Side asWest()
|||- Member Function: ::std::Side asResistance()
|||- Member Function: ::std::Side asCivilian()
|||- Member Function: ::std::Side asLogic()
|||- Member Function: ::std::Side asEnemy()
|||- Member Function: ::std::Side asFriendly()
||\- Member Function: ::std::Side asUnknown()
|\- Added constructor ::std::Group::Group(::std::Side)
|- Compiler: Fixed exception when LNK0012 happens
|- Compiler: Fixed external functions had to return
|- Compiler: Fixed variables without value get printed in function
|- Compiler: Fixed Fixed static functions throw LNK0051
|- Compiler: Fixed encapsulation call check (on private/protected)
|- Compiler: Fixed for loop arg1 variable not private in parents scope
|- Compiler: Fixed private functions
\- Compiler: Fixed "_" in fnc name fucks up config.cpp



Forum topic:
- BI forums




Enable javascript to be able to download from Armaholic please!



Tags: No tags