x39 101 Posted June 12, 2015 (edited) Prologue 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 How does it look like? more or less like so (begging for a better example here, so if you just learned how to write in OOS please provide a better one due to the fact that im a horrible example provider as author of the lang): namespace X39 { namespace testNamespace { class cFoo { public void foobar(string _someRandomArg) { SQF diag_log("class foo " + _someRandomArg); } public void test(string _test, string _test2) { } private void test2(string _test, string _test2) { } } class cBar : cFoo { public void override foobar(string _someRandomArg) { SQF diag_log("class bar " + _someRandomArg); } } } interface testInterface { void interfaceFnc(string, scalar, scalar); } class testObj : testInterface { public testObj() { this.testVarPublic = ""; testVarStatic = ""; this.testFncPublic("arg1", "arg2"); this.testFncPublic("arg1", "arg2"); ::X39::testObj::testFncStatic("arg1", "arg2"); } public string testVarPublic; static string testVarStatic; public void testFncPublic(string _arg1, string _arg2) { SQF diag_log(SQF str(_arg1)); } static string testFncStatic(string _arg1, string _arg2) { SQF diag_log(SQF str(_arg2)); return ""; } void interfaceFnc(string s, scalar i, scalar j) { return; } } static void castDynamicTest(::X39::testNamespace::cBar testVar) { auto casted = $testNamespace::cFoo$ testVar; } static void castStaticTest(strict ::X39::testNamespace::cBar testVar) { auto casted = §testNamespace::cFoo§ testVar; } static bool instanceOfTest(::X39::testNamespace::cFoo testVar) { return testVar is ::X39::testNamespace::cBar; } static bool returnTrue() { return true; } static void preInit() { SQF diag_log("preInit"); auto _obj = new ::X39::testObj(); _obj.testFncPublic("preInitArg1", "preInitArg2"); ::X39::testObj::testFncStatic("preInitArg1", "preInitArg2"); auto _foo = new ::X39::testNamespace::cFoo(); _foo.foobar("normal foo"); auto _bar = new ::X39::testNamespace::cBar(); _foo.foobar("normal bar"); auto _testing = 0; auto scalarArray = {1, 2, 3, 4, 5, 6}; auto stringArray = {"test1", "test2", "test3"}; auto boolArray = {false, true, false}; auto scalarValue = scalarArray[0]; auto stringValue = stringArray[0]; auto boolValue = boolArray[0]; string castedString = §string§ scalarValue; for(auto _test = 0; _test < 10; _test = _test + 1) { SQF diag_log("test"); } switch(SQF alive (SQF player)) { case true: try { throw "foobar"; } catch(string test) { SQF diag_log(test); } break; default: if(::X39::returnTrue()) { SQF systemChat("aprooved"); } else { SQF systemChat("nop"); } break; } while(true) { break; } } } I want to try it! So where is the link? Just scroll a lil further and you will see the download section, from there just download the setup.exe and execute the Wrapper.exe application using the command line. A good thing to start with would be to use the -help param to check the available param list of your Wrapper.exe Never trusted executables out of unknown sources ... any way to get the source so i can compile it by myself? Yes you can! The Entire project is OpenSource and thus anybody can contribute to the developement. What you need is a simple installation of VisualStudio and youre good to go (if you got further questions please either ask here or create a new ticket in the github repository) Important Links Downloads v0.8.0-ALPHA v0.7.4-ALPHA v0.7.3-ALPHA v0.7.2-ALPHA v0.7.1-ALPHA v0.7.0-ALPHA v0.6.2-ALPHA v0.6.1-ALPHA v0.6.0-ALPHA v0.5.3-ALPHA v0.5.2-ALPHA v0.5.1-ALPHA v0.5.0-ALPHA v0.4.0-ALPHA v0.3.0-ALPHA v0.2.0-ALPHA v0.1.0-ALPHA GitHub X39.io Project Page Skype group Task List General Describing Document ObjectOrientedScripting "project" example Same but in SQF (hand translated) GreetsX39 PS If you got questions, feel free to ask Edited May 23, 2016 by x39 Share this post Link to post Share on other sites
j_murphy 10 Posted June 16, 2015 Hi, As someone who is looking to get into programming scripting this sounds like a great opportunity. Currently I have good HTML and CSS knowledge but a lot of motivation.I also do understand languages like js and php I'm just no good at them. Can I help you because this sounds like a great project with good intentions and I am very keen to help you? Share this post Link to post Share on other sites
x39 101 Posted June 16, 2015 Hi,As someone who is looking to get into programming scripting this sounds like a great opportunity. Currently I have good HTML and CSS knowledge but a lot of motivation.I also do understand languages like js and php I'm just no good at them. Can I help you because this sounds like a great project with good intentions and I am very keen to help you? i appreciate every help i can get :P just try to get into the code and finish a few of those dozend open tasks its "just string handling" so nothing rly hard (tbh ... string handling can be one of the most hardest shit in the universe) feel free to add me in steam or skype if you got questions in regards of the code greets X39 Share this post Link to post Share on other sites
j_murphy 10 Posted June 16, 2015 i appreciate every help i can get :Pjust try to get into the code and finish a few of those dozend open tasks its "just string handling" so nothing rly hard (tbh ... string handling can be one of the most hardest shit in the universe) feel free to add me in steam or skype if you got questions in regards of the code greets X39 Alright will do. I'll get back to you when I can do those tasks then I'll look into more complicated things. Would you recommend C++ or C#? Can you recommend any tutorials?(video or writing doesn't bother me). Share this post Link to post Share on other sites
x39 101 Posted June 16, 2015 Alright will do. I'll get back to you when I can do those tasks then I'll look into more complicated things. Would you recommend C++ or C#? the tool itself is written in c# thus for this project i would recommend c# (which is in general a better language to start with then c++ due to the fact that c# leaves out a lot of the pointer arithmetic and is "truely" object oriented unlike c++) Share this post Link to post Share on other sites
j_murphy 10 Posted June 16, 2015 the tool itself is written in c# thus for this project i would recommend c# (which is in general a better language to start with then c++ due to the fact that c# leaves out a lot of the pointer arithmetic and is "truely" object oriented unlike c++) Thanks. Share this post Link to post Share on other sites
x39 101 Posted July 14, 2015 (edited) Some info update: threw out pretty much the entire handmade parsing and replacing it by coco/r ... should make parsing way faster (and sooner done) for this i am also rewriting the entire EBNF file COMPILER OOS CHARACTERS DIGIT = "0123456789". CHARACTER = 'abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ'. UNDERSCORE = '_'. LINETERMINATOR = ';'. TOKENS UINTEGER = DIGIT {DIGIT}. UDOUBLE = INTEGER '.' INTEGER. INTEGER = ['-' | '+'] UINTEGER. DOUBLE = ['-' | '+'] UDOUBLE. SCALAR = DOUBLE | INTEGER. BOOL = 'true' | 'false'. VALUE = SCALAR | ARRAY | BOOL; ARRAY = '[' VALUE | ']' MATHOPERATORS = '+' | '-' | '*' | '/'. LOGICOPERATORS = '&&' | '||' | '|' | '&'. IDENT = CHARACTER {CHARACTER | UNDERSCORE | DIGIT}. LOCALIDENT = UNDERSCORE (CHARACTER | UNDERSCORE) {CHARACTER | UNDERSCORE | DIGIT}. FQIDENT = ["::"] IDENT { "::" IDENT } [ '.' IDENT ]. PRODUCTIONS ENCAPSULATION<out ClassEncapsulation e> (. e = ClassEncapsulation.PUBLIC; .) = [ "private" (. e = ClassEncapsulation.PRIVATE; .) | "public" (. e = ClassEncapsulation.PUBLIC; .) ] . ASSIGNMENTOPERATORS<out AssignmentOperators ao> = '+=' (. ao = AssignmentOperators.PlusEquals; .) | '-=' (. ao = AssignmentOperators.MinusEquals; .) | '*=' (. ao = AssignmentOperators.MultipliedEquals; .) | '/=' (. ao = AssignmentOperators.DividedEquals; .) | '=' (. ao = AssignmentOperators.Equals; .) . OOS (. OosNamespace n; .) = NAMESPACE<out n> . NAMESPACE<out OosNamespace n> (. n = new OosNamespace(); BaseLangObject blo; .) = IDENT (. n.Name = t.val; .) '{' { NAMESPACE<out blo> (. n.addChild(blo); blo.setParent(n); .) | CLASS<out blo> (. n.addChild(blo); blo.setParent(n); .) | GLOBALFUNCTION<out blo> (. n.addChild(blo); blo.setParent(n); .) | GLOBALVARIABLE<out blo> (. n.addChild(blo); blo.setParent(n); .) } '}' [LINETERMINATOR {LINETERMINATOR}] . CLASS<out OosClass c> (. c = new OosClass(); BaseLangObject blo; .) = "class" IDENT (. c.Name = t.val; .) [ ':' IDENT (. c.ParentClasses.add(t.val); .) { ',' IDENT (. c.ParentClasses.add(t.val); .) } ] '{' { CLASS<out blo> (. c.addChild(blo); blo.setParent(c); .) | CLASSCONSTRUCTOR (. c.addChild(blo); blo.setParent(c); ((BaseFunctionObject)blo).Name = c.Name; .) | GLOBALFUNCTION<out blo> (. c.addChild(blo); blo.setParent(c); .) | GLOBALVARIABLE<out blo> (. n.addChild(blo); blo.setParent(n); .) | CLASSFUNCTION<out blo> (. c.addChild(blo); blo.setParent(c); .) | CLASSVARIABLE<out blo> (. c.addChild(blo); blo.setParent(c); .) } '}' [LINETERMINATOR {LINETERMINATOR}] . ARGLIST<out List<string> l> (. l = new List<string>(); .) = '(' { IDENT (. l.add(t.val); .) } ')' . CLASSCONSTRUCTOR<out OosClassFunction cf> (. cf = new OosClassFunction(); BaseLangObject blo; List<string> argL;.) = ENCAPSULATION "constructor" ARGLIST(out argL) (. cf.ArgList = argL; .) '{' { ( CODEINSTRUCTION<out blo> (. cf.addChild(blo); .) LINETERMINATOR {LINETERMINATOR} ) } '}' [LINETERMINATOR {LINETERMINATOR}] . CLASSFUNCTION<out OosClassFunction cf> (. cf = new OosClassFunction(); BaseLangObject blo; List<string> argL; Encapsulation e;.) = ENCAPSULATION<out e> (. cf.Encapsulation = e; .) "function" IDENT (. cf.Name = t.val; .) ARGLIST(out argL) (. cf.ArgList = argL; .) '{' { ( CODEINSTRUCTION<out blo> (. cf.addChild(blo); .) LINETERMINATOR {LINETERMINATOR} ) } '}' [LINETERMINATOR {LINETERMINATOR}] . GLOBALFUNCTION<out OosGlobalFunction gf> (. gf = new OosGlobalFunction(); BaseLangObject blo; List<string> argL;.) = "static" "function" IDENT (. gf.Name = t.val; .) ARGLIST(out argL) (. gf.ArgList = argL; .) '{' { ( CODEINSTRUCTION<out blo> (. gf.addChild(blo); .) LINETERMINATOR {LINETERMINATOR} ) } '}' [LINETERMINATOR {LINETERMINATOR}] . CLASSVARIABLE<out OosClassVariable cv> (. cv = new OosClassVariable(); Encapsulation e; BaseLangObject blo; .) = ENCAPSULATION<out e> (. cv.Encapsulation = e; .) "auto" IDENT (. cv.Name = t.val; .) [ '=' EXPRESSION<out blo> (. cv.Value = blo; .) ] LINETERMINATOR {LINETERMINATOR} . GLOBALVARIABLE<out OosGlobalVariable gv> (. gv = new OosGlobalVariable(); Encapsulation e; BaseLangObject blo; .) = "static" "auto" IDENT (. gv.Name = t.val; .) [ '=' EXPRESSION<out blo> (. gv.Value = blo; .) ] LINETERMINATOR {LINETERMINATOR} . EXPRESSION<out OosExpression e> (. e = new OosExpression(); BaseLangObject blo; .) = ( '(' ( FUNCTIONCALL<out blo> (. e.LInstruction = blo; .) | VALUE (. e.LInstruction = new OosValue(t.val); .) | OBJECTCREATIONL<out blo> (. e.LInstruction = blo; .) | IDENT (. e.LInstruction = new OosVariable(t.val); .) | FQIDENT (. e.LInstruction = new OosVariable(t.val); .) | LOCALIDENT (. e.LInstruction = new OosVariable(t.val); .) ) ')' ) | ( EXPRESSION (. e.LInstruction = blo; .) ( "&&" (. e.Op = ExpressionOperator.AndAnd; .) | '&' (. e.Op = ExpressionOperator.And; .) | "||" (. e.Op = ExpressionOperator.OrOr; .) | '|' (. e.Op = ExpressionOperator.Or; .) | "==" (. e.Op = ExpressionOperator.ExplicitEquals; .) | "===" (. e.Op = ExpressionOperator.Equals; .) | '+' (. e.Op = ExpressionOperator.Plus; .) | '-' (. e.Op = ExpressionOperator.Minus; .) | '*' (. e.Op = ExpressionOperator.Multiplication; .) | '/' (. e.Op = ExpressionOperator.Division; .) ) EXPRESSION (. e.RInstruction = blo; .) ) . LOCALVARIABLE<out OosLocalVariable lv> (. lv = new OosLocalVariable(); BaseLangObject blo; .) = "auto" LOCALIDENT (. lv.Name = t.val; .) [ '=' EXPRESSION<out blo> (. lv.Value = blo; .) ] . QUICKASSIGNMENT<out OosQuickAssignment qa> (. qa = new OosQuickAssignment(); List<string> argL; AssignmentOperators ao; BaseLangObject blo; .) = ( IDENT (. qa.Variable = new OosVariable(t.val); .) | FQIDENT (. qa.Variable = new OosVariable(t.val); .) | LOCALIDENT (. qa.Variable = new OosVariable(t.val); .) ) [ '[' UINTEGER (. qa.ArrayPosition = t.val; .) ']' ] ( "++" (. qa.QuickAssignmentType = QuickAssignmentTypes.PlusPlus; .) | "--" (. qa.QuickAssignmentType = QuickAssignmentTypes.MinusMinus; .) ) . NORMALASSIGNMENT<out OosVariableAssignment va> (. va = new OosVariableAssignment(); List<string> argL; AssignmentOperators ao; BaseLangObject blo; .) = ( IDENT (. va.Variable = new OosVariable(t.val); .) | FQIDENT (. va.Variable = new OosVariable(t.val); .) | LOCALIDENT (. va.Variable = new OosVariable(t.val); .) ) [ '[' UINTEGER (. va.ArrayPosition = t.val; .) ']' ] ASSIGNMENTOPERATORS<out ao> (. va.AssignmentOperator = ao; .) EXPRESSION<out blo> (. va.Value = blo; .) . ASSIGNMENT<out OosVariableAssignment va> = QUICKASSIGNMENT<out va> | NORMALASSIGNMENT<out va> . CALLLIST<out List<BaseLangObject> l> (. l = new List<BaseLangObject>(); BaseLangObject blo; .) = '(' { EXPRESSION<out blo> (. l.add(blo); .) } ')' . FUNCTIONCALL<out OosFunctionCall fc> (. fc = new OosFunctionCall(); List<string> argL; .) = FQIDENT (. fc.Name = t.val; .) CALLLIST<out argL> (. fc.ArgList = argL; .) . TYPEOF<out OosTypeOf to> (. to = new OosTypeOf(); BaseLangObject blo; .) = ("typeof" | "typeOf") '(' EXPRESSION<out blo> (. to.Argument = blo; .) ')' . INSTANCEOF<out OosInstanceOf to> (. to = new OosInstanceOf(); BaseLangObject blo; .) = EXPRESSION<out blo> (. to.LArgument = blo; .) ("instanceof" | "instanceOf") EXPRESSION<out blo> (. to.RArgument = blo; .) . OBJECTCREATION<out OosObjectCreation oc> (. oc = new OosObjectCreation(); List<string> argL; .) = "new" FQIDENT (. oc.Name = t.val; .) CALLLIST<out argL> (. oc.ArgList = argL; .) . CODEINSTRUCTION<out OosCodeInstruction ci> (. ci = new OosCodeInstruction(); ci.Suffix = ""; BaseLangObject blo; .) = FUNCTIONCALL<out blo> (. ci.Instruction = blo; ci.Suffix = ";"; .) | ASSIGNMENT<out blo> (. ci.Instruction = blo; .) | QUICKASSIGNMENT<out blo> (. ci.Instruction = blo; .) | LOCALVARIABLE<out blo> (. ci.Instruction = blo; .) | FORLOOP<out blo> (. ci.Instruction = blo; .) | WHILELOOP<out blo> (. ci.Instruction = blo; .) | IFELSE<out blo> (. ci.Instruction = blo; .) | TRYCATCH<out blo> (. ci.Instruction = blo; .) | THROWINSTRUCTION<out blo> (. ci.Instruction = blo; .) . FORLOOP = "for" '(' [ ASSIGNMENT ] LINETERMINATOR [ EXPRESSION ] LINETERMINATOR [ ASSIGNMENT ] ')' ( ( [ CODEINSTRUCTION ] LINETERMINATOR {LINETERMINATOR} ) | ( '{' { CODEINSTRUCTION LINETERMINATOR {LINETERMINATOR} } '}' ) ) . WHILELOOP = "while" '(' EXPRESSION ')' ( ( [ CODEINSTRUCTION ] LINETERMINATOR {LINETERMINATOR} ) | ( '{' { CODEINSTRUCTION LINETERMINATOR {LINETERMINATOR} } '}' ) ) . SWITCH = "switch" '(' EXPRESSION ')' '{' { ( ( "case" VALUE ) | "default" ) ':' '{' { CODEINSTRUCTION LINETERMINATOR {LINETERMINATOR} } '}' } '}' . TRYCATCH = "try" ( ( CODEINSTRUCTION LINETERMINATOR {LINETERMINATOR} ) | ( '{' { CODEINSTRUCTION LINETERMINATOR {LINETERMINATOR} } '}' ) ) "catch" '(' IDENT ')' ( ( CODEINSTRUCTION LINETERMINATOR {LINETERMINATOR} ) | ( '{' { CODEINSTRUCTION LINETERMINATOR {LINETERMINATOR} } '}' ) ) . THROWINSTRUCTION = "throw" EXPRESSION . IFELSE = "if" '(' EXPRESSION ')' ( ( CODEINSTRUCTION LINETERMINATOR {LINETERMINATOR} ) | ( '{' { CODEINSTRUCTION LINETERMINATOR {LINETERMINATOR} } '}' ) ) [ "else" ( ( CODEINSTRUCTION LINETERMINATOR {LINETERMINATOR} ) | ( '{' { CODEINSTRUCTION LINETERMINATOR {LINETERMINATOR} } '}' ) ) ] . END OOS. so stay tuned for updates! ---------edit--------- Parsing? Done! Transpatching? InProgress! so the first release might come out quite soon Edited July 15, 2015 by X39 Share this post Link to post Share on other sites
x39 101 Posted July 19, 2015 (edited) ALPHA RELEASE of OOS is available <3 https://github.com/X39/ObjectOrientedScripting/releases/tag/v0.1.0-ALPHA HaveFun whith testing/writing/raging using OOS Edited July 19, 2015 by X39 Share this post Link to post Share on other sites
ImperialAlex 72 Posted July 20, 2015 ALPHA RELEASE of OOS is available <3 https://github.com/X39/ObjectOrientedScripting/releases/tag/v0.1.0-ALPHA HaveFun whith testing/writing/raging using OOS Ohhhhhh, interesting! I'm going to have to play with this once my schedule clears up :) Share this post Link to post Share on other sites
x39 101 Posted July 21, 2015 0.2.0 ALPHA just has been released: https://github.com/X39/ObjectOrientedScripting/releases/tag/v0.2.0-ALPHA Version 0.2.0-ALPHA |v- New Parameters for Wrapper.exe ||- "sc=<FILE>" Used to check the syntax of some document ||- "dll=<FILE>" Forces given dll (ignores project settings) |\- "log[=<FILE>]" Enables LogToFile (with optional file parameter) |- Compiler: Fixed TryCatch |- Compiler: Fixed Expressions |- Compiler: Implemented class inheritance |- Compiler: Implemented public/private encapsulation |- Wrapper: Fixed ArgumentDetection (foo=bar was not detected) \- Logger: Disabled logToFile per default Share this post Link to post Share on other sites
Guest Posted July 21, 2015 Release frontpaged on the Armaholic homepage. ObjectOrientedScripting v0.3.0 Alpha Share this post Link to post Share on other sites
i_deadly_i 10 Posted July 21, 2015 Opa, interesting. I'm new to ObjectOrientedScripting, could someone please bring a comparison between this and .sqf. Share this post Link to post Share on other sites
j_murphy 10 Posted July 21, 2015 Opa, interesting. I'm new to ObjectOrientedScripting, could someone please bring a comparison between this and .sqf. https://en.m.wikipedia.org/wiki/Object-oriented_programming - I can't really give a comparison but the fundamentals are there. Share this post Link to post Share on other sites
x39 101 Posted July 21, 2015 (edited) Release frontpaged on the Armaholic homepage. http://www.armaholic.com/datas/users/news_download_a3_3.pngObjectOrientedScripting v0.3.0 Alpha thanks but funny that you released V0.3.0-ALPHA before i could :P (you got the version number wrong ^^) here it comes btw: Release 0.3.0-ALPHA https://github.com/X39/ObjectOrientedScripting/releases/tag/v0.3.0-ALPHA Version 0.3.0-ALPHA |- Compiler: changed block native code from: | native <instructions> endnative | to: | startnative <instructions> endnative |- Compiler: Added "native(<instructions>)" specially for expressions | (will be merged at some point with the block native again) |- Compiler: Added SQF Call instruction: | SQF [ (<arg1>, <argN>) ] <instruction> [ (<arg1>, <argN>) ] |- Compiler: Added missing detection for | unsigned integer/double values in VALUE |- Compiler: Added missing detection for | >, >=, <, <= operations in EXPRESSION |- Compiler: Added missing LOCALVARIABLE alternative for FORLOOP |- Compiler: Fixed FORLOOP |- Compiler: PrettyPrint sqf output improved with a new kind of instruction to call SQF commands: SQF [ (<arg1>, <arg2>, <argN>) ] <instruction> [ (<arg1>, <arg2>, <argN>) ] and a change to the native command (now needs "startnative [...] endnative" or "native(...)" inside of expressions) also, we reached a point where you can start using the project "productive" (not recommended but you could do thought, there still should be plenty of bugs) Opa, interesting. I'm new to ObjectOrientedScripting, could someone please bring a comparison between this and .sqf. here you can see how it looks like in OOS: https://github.com/X39/ObjectOrientedScripting/tree/master/TestProject for the SQF translation, please use the compiler :P the output structure looks like so: http://i.imgur.com/9QW3rOt.png (just that the config.cpp file is missing in that image) Edited July 21, 2015 by X39 Share this post Link to post Share on other sites
Guest Posted July 21, 2015 thanks but funny that you released V0.3.0-ALPHA before i could :P (you got the version number wrong ^^) Yep, sometimes I am to quick for my own good :D I have fixed the Armaholic mirror with the proper 0.3.0 alpha version. ObjectOrientedScripting v0.3.0 Alpha Share this post Link to post Share on other sites
SavageCDN 231 Posted July 21, 2015 Yep, sometimes I am to quick for my own good :D Fox's ex-wife can confirm this :p Share this post Link to post Share on other sites
code34 248 Posted July 22, 2015 hi :) Another breaking the wheel :) you should look at this place, a tech already exists to build sqf++ without external content (since 2013) http://forums.bistudio.com/showthread.php?167980-Object-Oriented-SQF-Scripting-and-Compiling so much good energy spend on tech that are used by nobody make me feel sick. Share this post Link to post Share on other sites
ImperialAlex 72 Posted July 22, 2015 you should look at this place, a tech already exists to build sqf++ without external content (since 2013) http://forums.bistudio.com/showthread.php?167980-Object-Oriented-SQF-Scripting-and-Compiling That project seems to be going for something very different. While the example you linked is technically implementing OO features into SQF, it's severely limited in the fact that it's based solely on the weak preprocessor system of SQF. Since the preprocessor is incredibly simple this means that the 'compilation' is essentially just a series of syntax transforms. It's insane that somebody managed to actually pull it off but it won't help with issues like static analysis (type checking?) or optimization. Share this post Link to post Share on other sites
x39 101 Posted July 22, 2015 hi :) Another breaking the wheel :) you should look at this place, a tech already exists to build sqf++ without external content (since 2013) http://forums.bistudio.com/showthread.php?167980-Object-Oriented-SQF-Scripting-and-Compiling so much good energy spend on tech that are used by nobody make me feel sick. There is also the carma project but all of them share one thing in common They extend sqf Oos reforms sqf by providing a new language Share this post Link to post Share on other sites
code34 248 Posted July 22, 2015 It s nice that you believe in your project. There is a many coding langage since years that happens in global range (out of arma). But after all, must of them, don't really make a difference versus main stream langage as C# or java did. A langage is a langage, and the main reason to use it, is the way to achieve a goal. In A3, the OO langage should be a feature since a while (for technical reason cause we use objects and simple type variablen and could be a salvation for the script engine), but BIS certainly for compatibility reason, and community reason didn't do it. The sqf is currently in the same way of what was PHP3. Hope your project will be a success , and i will follow your thread to look how things happen :) Share this post Link to post Share on other sites
x39 101 Posted July 22, 2015 It s nice that you believe in your project. There is a many coding langage since years that happens in global range (out of arma). But after all, must of them, don't really make a difference versus main stream langage as C# or java did.A langage is a langage, and the main reason to use it, is the way to achieve a goal. In A3, the OO langage should be a feature since a while (for technical reason cause we use objects and simple type variablen and could be a salvation for the script engine), but BIS certainly for compatibility reason, and community reason didn't do it. The sqf is currently in the same way of what was PHP3. Hope your project will be a success , and i will follow your thread to look how things happen :) for what i hope: more people join the project its open source thus everybody can contribute so that the lang. growth with time to something even more better then now Share this post Link to post Share on other sites
x39 101 Posted August 20, 2015 Help Wanted OOS currently has quite some big task going on that brings type safety into OOS to remove the currently quite significant performance overhead so i please you to help developing the EBNF and judging it so that it improoves and gets to the best EBNF possible https://github.com/X39/ObjectOrientedScripting/blob/TypeSafety/Concept/oos.ebnf greetings X39 Share this post Link to post Share on other sites
DevinGn 10 Posted August 22, 2015 This looks like it has a good bit of potential. It reminds me of when I first began scripting for ArmA and you spent over an hour explaining to me that SQF has absolutely no qualities of an OOP language. I'm looking forward to seeing what I can cook up with this tomorrow. the tool itself is written in c# thus for this project i would recommend c# (which is in general a better language to start with then c++ due to the fact that c# leaves out a lot of the pointer arithmetic and is "truely" object oriented unlike c++) Not to derail the thread or anything, but I do not necessarily agree that C sharp is a better language to begin programming in (at least not for OOP). Not that C# isn't a wonderful language, but it makes certain things too easy to understand (such as pointer arithmetic). Understanding pointers and memory management is a key computer science concept and it shouldn't be simply omitted out of ease. Not every language you will work with in the future is going to handle things like your garbage collection for you. I'm probably making a death wish by saying this, but Java is probably the best OOP language for a beginner to learn. Only because C++ relies far more on abstraction than Java and it only creates learning curves down the road. Also, could you clarify what makes C++ an untrue OOP language? Last time I checked it meets all four characteristics of one. Share this post Link to post Share on other sites
x39 101 Posted August 22, 2015 This looks like it has a good bit of potential. It reminds me of when I first began scripting for ArmA and you spent over an hour explaining to me that SQF has absolutely no qualities of an OOP language. I'm looking forward to seeing what I can cook up with this tomorrow. Not to derail the thread or anything, but I do not necessarily agree that C sharp is a better language to begin programming in (at least not for OOP). Not that C# isn't a wonderful language, but it makes certain things too easy to understand (such as pointer arithmetic). Understanding pointers and memory management is a key computer science concept and it shouldn't be simply omitted out of ease. Not every language you will work with in the future is going to handle things like your garbage collection for you. I'm probably making a death wish by saying this, but Java is probably the best OOP language for a beginner to learn. Only because C++ relies far more on abstraction than Java and it only creates learning curves down the road. Also, could you clarify what makes C++ an untrue OOP language? Last time I checked it meets all four characteristics of one. C++ is more or less like this project it does has the concepts in but the end result is not created with objects in mind and everything is fiddled around the non-objectoriented environment it is just "a better c" with object oriented stuff in it whilst java (as example) does do that stuff BTW. right now there is a bug in the OOS project which causes naming of object functions to be wrong in the config.cpp will be fixed till monday i think Share this post Link to post Share on other sites
x39 101 Posted August 23, 2015 RELEASE 0.4.0-ALPHA https://github.com/X39/ObjectOrientedScripting/releases/tag/v0.4.0-ALPHA Version 0.4.0-ALPHA |- Wrapper: Now returns -1 if was not successfully |- Wrapper: Added "setFlags(string[])" function to ICompiler interface |- Wrapper: Fixed compilerDLL search location | Working dir (applicationside) was checked | and not executable dir |- Compiler: Fixed naming of functions in output config file | being incorrect |- Compiler: Added flag /CLFN with STRING value ("/CLFN=blabla.cfg") | Sets how the output config will be named |- Compiler: Added flag /NFNC \ Removes the CfgFunctions class from the config file Share this post Link to post Share on other sites