![]() ![]() |
![]() ![]() Post #1 | |
![]() Trained Member Posts: 77 Joined: 25-October 10 ![]() | CLEO Every programming language has Hello world example. Now CLEO SCM has got one: SANNY {$CLEO} 0000: START :DISPLAY wait 1000 0AD1: show_formatted_text_highpriority "Hello world!" time 2000 jump @DISPLAY {$CLEO} tells SB to create .cs file, not .scm. :DISPLAY is label that we can jump afterwards to. 0AD1 is CLEO4 opcode to display text from variables. Easiest for example. jump @DISPLAY - of course GTA parser must know what to do. Without this it would crash, because code is ended up. This post has been edited by fastman92: Jan 20 2011, 03:43 PM |
![]() Post #2 | |
![]() Member Posts: 197 From: Liberty City, Shoreside Joined: 15-July 10 ![]() | Hey. I don't think that gta's "scripting" is a QUOTE programming language btw, why did you make wait in 1000 and set the time flag to 2000? QUOTE jump @DISPLAY - of course GTA parser must know what to do. Without this it would crash, because code is ended up. hm... |
![]() Post #3 | |
![]() Coding like a Rockstar! ![]() Posts: 1,468 From: ??? Joined: 28-May 09 ![]() | Actually.. The SCM Parser doesn't crash because the file ended. The file is loaded into memory, so the parser doesn't know where the file ends. It just keeps reading data, including data which comes after the loaded script. This data could be information for the next CLEO Script or something else. Worth knowing as an idea to write SCM through memory. I believe he made the time flag 2000 to compensate for any lag, which is not actually needed since both scripts and the text drawn runs by the same timer. "Program" is usually used to refer to giving the computer instructions. Here, we are giving the game engine instructions, which then gives the computer instructions. Not a big difference really. The SCM is actually quite powerful (perhaps more so than some programming languages) since there is not too much that is done inbetween parsing the script and executing the instructions. Of course, if you were to use ASM in the script, you are definitely programming ![]() 0ACC or 0ACD are more appropriate for text-only messages. -------------------- | CLEO 4.3.22 | A?i?a?o?3D | UI SDK | Black Market Mod 1.0.1 | GInput 0.3 | Cheat Keyboard | Tactile Cheat Activation | Stream Ini Extender 0.7 | SuperVars | ScrDebug | Vigilante Justice: San Andreas | |
![]() Post #4 | |
![]() Trained Member Posts: 77 Joined: 25-October 10 ![]() | 0AD1 sets high priority text for some time given in miliseconds. I wrote time 2000. It is only simple hello world Then i added wait 1000. There is no need to wait 0 in this simple code, text is set up for 2 seconds, wait is for 1 second. No other operations are here. I know that GTA .cs or .scm are only structure of instructions, labels. I also think Sanny SCM is programming language. You have high level representation, labels, opcodes, if, while, for, costants and Sanny understands how to compile it. It is language. |
![]() Post #5 | |
![]() Member Posts: 197 From: Liberty City, Shoreside Joined: 15-July 10 ![]() | QUOTE (Deji) Of course, if you were to use ASM in the script, you are definitely programming Ok, I agree ![]() |
![]() Post #6 | |
![]() User banned by request due to personal reasons. - SV Posts: 24 From: 0xFFFFFFFF Joined: 14-March 10 ![]() | QUOTE I also think Sanny SCM is programming language. You have high level representation, labels, opcodes, if, while, for, costants and Sanny understands how to compile it. It is language. Actually it doesn't depend on the structure the compiler interprets your code (whether low- or high-level) but on the construction itself. SCM is a scrip language such as LUA and Tcl (although LUA now supports WINAPI libarys and structures it is still a script language). Even SCM combined with ASM is still a scripting process... sorry for smartassing -------------------- ![]() User banned by request due to personal reasons. - SV |
![]() ![]() |