Popular Post Link2012 1,632 Posted December 22, 2016 Popular Post Share Posted December 22, 2016 (edited) GTA3script Toolchain This is a compiler, editor extension, and debugger for the GTA3script language, which was the de facto language used by Rockstar North to code the mission scripts of the 3D Universe.The compiler is cross-platform, well tested and provides a CLI interface based off GCC/Clang. So if you are familiar with command line interfaces, this should be pretty standard for your tastes.The editor extension is a extension for VSCode, which is a lightweight, cross-platform, and extensible text editor (definitely not Visual Studio). Such extension provides syntax highlighting, auto-completion and documentation crawled from GTAModding and GTAG. This provides access to the compiler as well, so there's no need to touch the command line interface if you aren't familiar with that.The debugger is a client-server protocol which supports breakpoints, variable watching, and more. It's currently work-in-progress, but you should see it working together the editor extension pretty soon. Do note it is a protocol, as such it is game, compiler and editor agnostic, it just needs to be implemented on them.Everything is open source, as usual, and as noticed, it's all future-proof, in such a way that it can be used in future recreations of the game, such as OpenRW.This is compatible with all three games in the trilogy, III, Vice City and San Andreas.Get It:Download the compiler, or compile it yourself. Download VSCode and the extension (read the instructions). Download the debug server... ehh.. not yet. It's dangerous to go alone, take this:Learn GTA3script in Y minutes GTA3script at GTAModding GTA3script Complete Tutorial (PT-BR) GTA3 Multifile Source Code Quick Vehicle Spawner Source Code Special Thanks: Wesser for immensurable help in understanding the language, its principles and its future. Deji for his previous research and attempts at making a working compiler. Junior_Djjr and Silent for testing and feedback. I would also like to thank a certain company, without their slips, this wouldn't be possible. Edited June 5, 2017 by LINK/2012 56 Link to post Share on other sites
Silent 15,932 Posted December 22, 2016 Share Posted December 22, 2016 first 2 Link to post Share on other sites
Inadequate 3,730 Posted December 22, 2016 Share Posted December 22, 2016 Second. 11 Link to post Share on other sites
fastman92 2,617 Posted December 24, 2016 Share Posted December 24, 2016 Good job. Try to make it compatible with other than GTA 3 games, if it's not. Link to post Share on other sites
Junior_Djjr 2,924 Posted December 25, 2016 Share Posted December 25, 2016 I met LINK/2012 in 2011 when he was still learning a create custom scripts. Today he totally recreated the way to make such mods, in an incredible way. This renews the forces (and fun) of modding. Now my mods will be created using it, and I'll share some source codes here. btw this thing is cool to use together. 3 Link to post Share on other sites
Blackbird88 1,671 Posted December 25, 2016 Share Posted December 25, 2016 Good job. Try to make it compatible with other than GTA 3 games, if it's not. LINK didn't specifically noted it in OP, but III/VC/SA are supported AFAIK. Link to post Share on other sites
_Israel_ 16 Posted December 25, 2016 Share Posted December 25, 2016 Now my mods will be created using it (...) We are 2, that gives a certain mood ! Link to post Share on other sites
The_GTA 561 Posted December 25, 2016 Share Posted December 25, 2016 Very professional product! Noted that I take a look at this in my spare time. Link to post Share on other sites
thehambone 2,924 Posted December 25, 2016 Share Posted December 25, 2016 (edited) It's great to see a compiler for the native GTA3-era scripting language! Looks very well-built and authentic, as if Rockstar created the tool themselves. Awesome work! Edited December 25, 2016 by thehambone Link to post Share on other sites
fastman92 2,617 Posted December 25, 2016 Share Posted December 25, 2016 You should implement a support of GTA LCS/VCS as well. Link to post Share on other sites
Silent 15,932 Posted December 26, 2016 Share Posted December 26, 2016 (edited) You should implement a support of GTA LCS/VCS as well. It is a open source project, you could help with an contribution too Edited December 26, 2016 by Silent 8 Link to post Share on other sites
Link2012 1,632 Posted December 26, 2016 Author Share Posted December 26, 2016 You should implement a support of GTA LCS/VCS as well. I don't know if LCS/VCS support is worth it. We'll need to guess a lot of language semantics and command names, and that should be done carefully. Since nobody does Stories scripting, this would be an unnecessary danger. Link to post Share on other sites
fastman92 2,617 Posted December 26, 2016 Share Posted December 26, 2016 (edited) You should implement a support of GTA LCS/VCS as well. I don't know if LCS/VCS support is worth it. We'll need to guess a lot of language semantics and command names, and that should be done carefully. Since nobody does Stories scripting, this would be an unnecessary danger. I have studied LCS/VCS SCM for a long time. A plenty of commands got carefully researched. Edited December 26, 2016 by fastman92 Link to post Share on other sites
Ash_735 17,325 Posted December 26, 2016 Share Posted December 26, 2016 So why not help out then? Oh wait, you'll only do it if you can somehow attach f92 in there somewhere 1 1 Link to post Share on other sites
thehambone 2,924 Posted December 26, 2016 Share Posted December 26, 2016 Support for LCS/VCS would certainly be useful for me. Hex editing main.scm is a pain. Link to post Share on other sites
Silent 15,932 Posted December 26, 2016 Share Posted December 26, 2016 gta3sc aims for accuracy though and we know almost nothing about Stories-exclusive SCM features which requires even more guessing - and the more guessing is used, the worse the tool becomes. 2 Link to post Share on other sites
fastman92 2,617 Posted December 26, 2016 Share Posted December 26, 2016 Support for LCS/VCS would certainly be useful for me. Hex editing main.scm is a pain.I have a simple SCM compiler for GTA LCS and VCS, which uses a limited Sanny Builder syntax.Hex editing of main.scm is the worst that can be done. Link to post Share on other sites
goodidea82 325 Posted December 27, 2016 Share Posted December 27, 2016 (edited) A translator from SB would be great, to port existing mods. A decompiler would also be great, it is very useful for learning and checking scripts from other people. Edited December 27, 2016 by goodidea82 Link to post Share on other sites
Link2012 1,632 Posted December 27, 2016 Author Share Posted December 27, 2016 (edited) A translator from SB would be great, to port existing mods. A decompiler would also be great, it is very useful for learning and checking scripts from other people. I tried writing a high-level decompiler at some point but I failed miserably and ended up frustated . A low-level one exists by the way and was used to decompile VC/SA so they could be test cases, it isn't very intuitive to use though. I could try again at some point (don't count on it) since I learnt a lot with the mistakes on the first try, but at the moment I'm expecting Seemann to finish his attempt. The translator should be pretty straightforward to do really, but I invite somebody else to write one since I don't really feel like it. A Python script should be a good pick . Edited December 27, 2016 by LINK/2012 Link to post Share on other sites
Junior_Djjr 2,924 Posted December 28, 2016 Share Posted December 28, 2016 I also thought about a translator, including the first things I did with GTA3script was to manually translate some mods I've already created. (right now I'm translating one more). I didn't even give this tip to LINK/2012 because, in a way, not having a translator is good, because you are required to translate it manually, and at the beginning this helps you to practice. Link to post Share on other sites
Vadim M. 683 Posted January 7, 2017 Share Posted January 7, 2017 Good job! 1 Link to post Share on other sites
Link2012 1,632 Posted January 7, 2017 Author Share Posted January 7, 2017 Updated with some fixes. 4 Link to post Share on other sites
Link2012 1,632 Posted January 27, 2017 Author Share Posted January 27, 2017 (edited) Added a complete GTA3script tutorial by Junior_Djjr on the OP. It assumes no previous programming knowledge from the reader. It's in Brazilian Portuguese, but still may be helpful. Edited January 27, 2017 by LINK/2012 1 Link to post Share on other sites
gts. 2,326 Posted January 29, 2017 Share Posted January 29, 2017 I'm very interested on this. Will be some kind of converter available for Sanny Builder to GTA3script? I mean, will be a pain in the ass re-write long Sanny scripts to port them into GTA3script. Link to post Share on other sites
fastman92 2,617 Posted January 29, 2017 Share Posted January 29, 2017 (edited) This is the core reason why I cannot develop CLEO scripts using GTA3script Toolchain. The amount of time that would be required to rewrite the Sanny Builder code into GTA3script is prohibitive. It's not an option to throw away everything what has already been made for Sanny Builder. Edited January 29, 2017 by fastman92 Link to post Share on other sites
thehambone 2,924 Posted January 30, 2017 Share Posted January 30, 2017 It's not an option to throw away everything what has already been made for Sanny Builder.Who says you have to do that, though? GTA3script seems more like an alternative, rather than a replacement, for Sanny's scripting. 3 Link to post Share on other sites
Silent 15,932 Posted January 30, 2017 Share Posted January 30, 2017 The way I see it you should treat this as "ok, next time I do SCM stuff I'll use gta3sc". 3 Link to post Share on other sites
spaceeinstein 1,807 Posted February 8, 2017 Share Posted February 8, 2017 Is it possible to do weird tricks that R* never used, like the assignment of a label to a variable? In SB: [email protected] = @label Link to post Share on other sites
Wesser 371 Posted February 8, 2017 Share Posted February 8, 2017 (edited) Yes, partially. Doing so, we would pay the price of putting a brand new token in front of *VAR_INTs (alike the dollar sign leading *VAR_TEXT_LABELs), because the identifier of variables and label references can conflict without issues (unlike string constants). Configuring the SET command pair to grant such an assignment, the compiler wouldn't be capable of matching the right alternative and differentiating *VAR_INT from LABEL arguments. That said, featuring the GET_LABEL_FILE_OFFSET command by the runtime is the only way to go (in view of the decompilation process as well). Edited February 8, 2017 by Wesser 1 Link to post Share on other sites
Deji 814 Posted March 7, 2017 Share Posted March 7, 2017 Bravo, you managed where I failed in making the essential GTA modding tool which will be heavily underappreciated and mostly unused. Next step is to realise SCR and "CLEO VM" or whatever it should be called 5 Link to post Share on other sites