BresoDEV Posted December 2, 2010 Share Posted December 2, 2010 Awesome work ZAZ....this is very helpfull for all thanks EdUaRdO, nice website Hey ZAZ, you know how to block scripts cleo or prevent it from being decompiled? Why has not some that decompiles Sanny .. was wondering if there's any way to do this .. Tnks add three unused codelines at the scriptend and then try to find it with hexeditor in the compiled cleo script you should look for dots before the global variable list start and change one dot with three letters Thanks. I did. I used the list of upcodes Sanny and SASCM.ini Link to comment https://gtaforums.com/topic/403594-sa-~-cleo-script-tutorial-~/?do=findComment&comment=1060227009 Share on other sites More sharing options...
kmlwin.1996 Posted January 4, 2011 Share Posted January 4, 2011 Hey! ZAZ! Please tell me how we need to use collision. I don't understand some codes of yours. It is full of mathematics coding. Link to comment https://gtaforums.com/topic/403594-sa-~-cleo-script-tutorial-~/?do=findComment&comment=1060278971 Share on other sites More sharing options...
ZAZ Posted January 4, 2011 Author Share Posted January 4, 2011 (edited) Hey! ZAZ! Please tell me how we need to use collision. I don't understand some codes of yours. It is full of mathematics coding. 1. Objects which works for collisions-check with builings, ground, cars, peds and objects there are only a few objects which works for fully collisions check the others can't check buildings and ground below the useful objects: ID number, model name 1598, beachball 3065, BBALL_col 2891, kmb_packet 3054, DYN_WREKING_BALL 1305, dyn_quarryrock01 1582, pizzabox, prop_pizzabox They have a standart collisionsfunction by default, they are explosion dynamical, throwable, and works for collisionscheck Take the beachball or the BBALL_col, they have settings in object.dat you can add an object reference in object.dat if it still not exist there with the same settings of BBALL_col to give your object the required behavior for full collisions check data\object.datbball_col 10.0, 10.0 1.00, 0.3, 50.0, 0.0, 0.1, 0, 2, 1, 0, 0, 0.0, 0.0, 0.0, noneOr use 2 objects, one which should be shown like a rocket and one which works with full collisions check like BBALL_col,then attach the rocket to the BBALL_col, make BBALL_col unvisible and throw it and do a collisions check for BBALL_col if04DA: has_object 1@ collidedjf @next 2. moveable object for collisions check need further settings Mostly it needs to throw the object with 0381: throw_object furthermore codes to activate collisions check and to make it movable 04D9: object 1@ set_scripted_collision_check 10392: make_object 1@ moveable 10381: throw_object 1@ velocity_in_direction 15@ 16@ 18@ 3. throw object As first a simple examplescript to throw an object {$CLEO .cs}:Objectthrow_very_simplethread 'OTHROW':Objectthrow_1wait 0if0256: player $PLAYER_CHAR definedjf @Objectthrow_1if0AB0: key_pressed 8//-----------------------------press backspace jf @Objectthrow_10247: request_model 3054:Objectthrow_3wait 0if0248: model 3054 availablejf @Objectthrow_304C4: create_coordinate 11@ 12@ 13@ from_actor $PLAYER_ACTOR offset 0.0 5.0 0.00107: 1@ = create_object 3054 at 11@ 12@ 13@0906: set_object 1@ mass_to 300.0 // float0908: set_object 1@ turn_mass_to 30004D9: object 1@ set_scripted_collision_check 10382: set_object 1@ collision_detection 1wait 20000392: object 1@ toggle_in_moving_list 10381: throw_object 1@ distance 0.0 5.0 15.0wait 5000Object.Destroy(1@)0249: release_model 3054jump @Objectthrow_1the throw-object-opcode0381: throw_object 1@ distance 0.0 5.0 15.0 requires x,y,z, float values which gives the orientation in relation to the object for the throwing but the orientation itself of the object is ignored so the example above (0.0 5.0 15.0) let the object move 5.0 in direction north and 15.0 in the height to get the values for the throw_object opcode needs to read the player z-angle and calculate it with sin and cosin The script below throws the beachball which keeps the position by collision for 1 second press right mouse button to throw it {$CLEO .cs}:Objectthrow_with_destination_and_collisions_checkthread 'OTHROW'//1598, beachball:Objectthrow_1wait 0if0256: player $PLAYER_CHAR definedjf @Objectthrow_1if0AB0: key_pressed 2//-----------------------------press right mouse buttonjf @Objectthrow_10247: request_model 1598:Objectthrow_3wait 0if0248: model 1598 availablejf @Objectthrow_304C4: create_coordinate 11@ 12@ 13@ from_actor $PLAYER_ACTOR offset 0.0 2.0 0.50107: 1@ = create_object 1598 at 11@ 12@ 13@0750: set_object 1@ visibility 104D9: object 1@ set_scripted_collision_check 10382: set_object 1@ collision_detection 10906: set_object 1@ mass_to 30000.0 // float0908: set_object 1@ turn_mass_to 30000.0 // float0172: 19@ = actor $PLAYER_ACTOR Z_angle0453: set_object 1@ XY_rotation 0.0 0.0 angle 19@02F6: 15@ = sine 19@ // (float)02F7: 16@ = cosine 19@ // (float)15@ *= 60.0 // (float)16@ *= 60.0 // (float)15@ *= -1.00819: 18@ = actor $PLAYER_ACTOR distance_from_ground18@ += 3.0 // (float)0392: make_object 1@ moveable 10381: throw_object 1@ velocity_in_direction 15@ 16@ 18@33@ = 0:Objectthrow_5wait 0if0256: player $PLAYER_CHAR definedjf @Objectthrow_130400: store_coords_to 11@ 12@ 13@ from_object 1@ with_offset 0.0 -2.0 0.00381: throw_object 1@ velocity_in_direction 15@ 16@ 18@if or04DA: has_object 1@ collided8474: not actor $PLAYER_ACTOR near_object_in_cube 1@ radius 200.0 200.0 200.0 flag 00019: 33@ > 7000jf @Objectthrow_50392: make_object 1@ moveable 00382: set_object 1@ collision_detection 000A1: put_actor $PLAYER_ACTOR at 11@ 12@ 13@wait 10000392: make_object 1@ moveable 10382: set_object 1@ collision_detection 1wait 1000:Objectthrow_130108: destroy_object 1@0249: release_model 1598jump @Objectthrow_1 one more example, the Missilescript, below press backspace to throw bball_col with attached missile if bball_col collide, the script let the engine read the position of the object and do explosions at this point {$CLEO .cs}:Missilethread 'MISSILE':MISSILE_11wait 0if Player.Defined($PLAYER_CHAR)jf @MISSILE_11if0AB0: key_pressed 8jf @MISSILE_11Model.Load(3065)Model.Load(3786):MISSILE_56wait 0if and Model.Available(3065) Model.Available(3786)jf @MISSILE_562@ = Actor.Angle($PLAYER_ACTOR)04C4: store_coords_to 11@ 12@ 13@ from_actor $PLAYER_ACTOR with_offset 1.0 -0.5 1.31@ = Object.Create(3065, 11@, 12@, 13@)2@ += 270.0Object.Angle(1@) = 2@0750: set_object 1@ visibility 019@ = Object.Create(3786, 0.0, 0.0, 0.0)Object.Angle(19@) = 2@04D9: object 1@ set_scripted_collision_check 1Object.CollisionDetection(1@) = True0906: set_object 1@ mass_to 30000.0 // float0908: set_object 1@ turn_mass_to 30000.0 // float069A: attach_object 19@ to_object 1@ with_offset 0.0 0.0 0.0 rotation 0.0 0.0 0.0Object.CollisionDetection(19@) = False2@ = Actor.Angle($PLAYER_ACTOR)0819: 18@ = actor $PLAYER_ACTOR distance_from_ground4@ = 80.102F6: 5@ = cosine 2@ // (float)02F7: 6@ = sine 2@ // (float)006B: 5@ *= 4@ // (float)006B: 6@ *= 4@ // (float)5@ *= -1.018@ += 1.0Object.ToggleInMovingList(1@) = TrueObject.Throw(1@, 5@, 6@, 18@)33@ = 0:MISSILE_376wait 0if Player.Defined($PLAYER_CHAR)jf @MISSILE_3760400: store_coords_to 11@ 12@ 13@ from_object 1@ with_offset 0.0 0.0 0.0095C: create_smoke_at 11@ 12@ 13@ velocity 0.0 0.0 0.0 RGBA 1.0 1.0 1.0 1.0 size 0.5 last_factor 0.1if or04DA: has_object 1@ collided 33@ > 7000jf @MISSILE_3760400: store_coords_to 11@ 12@ 13@ from_object 1@ with_offset 0.0 0.0 0.0020C: create_explosion_with_radius 3 at 11@ 12@ 13@0565: create_soundless_explosion_at 11@ 12@ 13@ type 50400: store_coords_to 11@ 12@ 13@ from_object 1@ with_offset 5.0 0.0 0.0020C: create_explosion_with_radius 3 at 11@ 12@ 13@0565: create_soundless_explosion_at 11@ 12@ 13@ type 50400: store_coords_to 11@ 12@ 13@ from_object 1@ with_offset -5.0 0.0 0.0020C: create_explosion_with_radius 3 at 11@ 12@ 13@0565: create_soundless_explosion_at 11@ 12@ 13@ type 50400: store_coords_to 11@ 12@ 13@ from_object 1@ with_offset 0.0 5.0 0.0020C: create_explosion_with_radius 3 at 11@ 12@ 13@0565: create_soundless_explosion_at 11@ 12@ 13@ type 50400: store_coords_to 11@ 12@ 13@ from_object 1@ with_offset 0.0 -5.0 0.0020C: create_explosion_with_radius 3 at 11@ 12@ 13@0565: create_soundless_explosion_at 11@ 12@ 13@ type 5Model.Destroy(3065)Model.Destroy(3786)095C: create_smoke_at 11@ 12@ 13@ velocity 0.0 0.0 0.0 RGBA 0.0 0.0 0.0 0.2 size 3.0 last_factor 0.10682: detach_object 19@ 0.0 0.0 0.0 collision_detection 1Object.Destroy(1@)Object.Destroy(19@)jump @MISSILE_11 The script checks the collision and the time if or04DA: has_object 1@ collided 33@ > 7000jf @MISSILE_376If the object don't collide, the timer 33@ let the script end and restart after 7 seconds Edited November 20, 2016 by ZAZ Link to comment https://gtaforums.com/topic/403594-sa-~-cleo-script-tutorial-~/?do=findComment&comment=1060279588 Share on other sites More sharing options...
kmlwin.1996 Posted January 5, 2011 Share Posted January 5, 2011 Great Tut. Sometimes, I wonder how you can write a lot of codes. I want to do that like you but I cannot. Sometimes, I write some codes. Sometimes, they work. Sometimes, they crash. I want to be like you. But I am from Myanmar, you are from Germany. We are sooo... far. I want to be your pupil. If I can. Plz tell me how you write a lot of codes. Explain me! Ops! One thing, how to put missions into scm? <<by patrickW: merged tripple post>> Link to comment https://gtaforums.com/topic/403594-sa-~-cleo-script-tutorial-~/?do=findComment&comment=1060280412 Share on other sites More sharing options...
ZAZ Posted January 5, 2011 Author Share Posted January 5, 2011 (edited) Great Tut. Sometimes, I wonder how you can write a lot of codes. I want to do that like you but I cannot. Sometimes, I write some codes. Sometimes, they work. Sometimes, they crash. I want to be like you. But I am from Myanmar, you are from Germany. We are sooo... far. I want to be your pupil. If I can. Plz tell me how you write a lot of codes. Explain me! Ops! One thing, how to put missions into scm? <<by patrickW: merged tripple post>> I do that since 5 years, reading informations like tutorials, posts of mission coding as well as the scripts of main.scm and find methods by trial and error. It need the mood to do it. I had very often problems and was going mad because i could not find the failure. But instead asking in the forum i tried it the next day and then it was easy to solve a simple problem. how to put missions into scm isn't a cleo theme, read Dutchys Tut or ask in mission coding forum Edited January 16, 2011 by ZAZ Link to comment https://gtaforums.com/topic/403594-sa-~-cleo-script-tutorial-~/?do=findComment&comment=1060281217 Share on other sites More sharing options...
gtasite1 Posted January 18, 2011 Share Posted January 18, 2011 And I have a question, how to build a script to use one button to fly the car and the two buttons to control the amount of eg 1-down, 2-up to not have to type the code RIPAZHA? Link to comment https://gtaforums.com/topic/403594-sa-~-cleo-script-tutorial-~/?do=findComment&comment=1060300482 Share on other sites More sharing options...
ZAZ Posted January 18, 2011 Author Share Posted January 18, 2011 And I have a question, how to build a script to use one button to fly the car and the two buttons to control the amount of eg 1-down, 2-up to not have to type the code RIPAZHA? cheat RIPAZHA = Cars Fly memadress 0x969160 - Cars can Fly it needs to find and set the working value into this memadress read the theme read memory Link to comment https://gtaforums.com/topic/403594-sa-~-cleo-script-tutorial-~/?do=findComment&comment=1060300670 Share on other sites More sharing options...
Silent Posted January 18, 2011 Share Posted January 18, 2011 0x969160 - Cars can Flyit needs to find and set the working value into this memadress It should be a bool, so values are 0 and 1 Link to comment https://gtaforums.com/topic/403594-sa-~-cleo-script-tutorial-~/?do=findComment&comment=1060300900 Share on other sites More sharing options...
ZAZ Posted January 18, 2011 Author Share Posted January 18, 2011 0x969160 - Cars can Flyit needs to find and set the working value into this memadress It should be a bool, so values are 0 and 1 Thx, i didn't try it. Do all cheat-mems work with bool? Link to comment https://gtaforums.com/topic/403594-sa-~-cleo-script-tutorial-~/?do=findComment&comment=1060301135 Share on other sites More sharing options...
gtasite1 Posted January 20, 2011 Share Posted January 20, 2011 OK. I am using this code 0A8C: write_memory 9867616 size 4 value 10.0 virtual_protect 1 , but I like trying to fly a car, nothing happens. But it' s something you try to think. And I have a question about the pager from GTA 3 to GTA SA in the sense of a script in cleo I use this code // This file was decompiled using sascm.ini published by Seemann (http://sannybuilder.com/files/SASCM.rar) on 13.10.2007 {$VERSION 3.1.0027} {$CLEO .cs} //-------------MAIN--------------- thread 'PAGER' 0000: NOP wait 5000 0@ = -64.0 1@ = 64.0 0390: load_txd_dictionary 'PAGER' 038F: load_texture "PAGER" as 1 // Load dictionary with 0390 first Audiostream.Load($PAGER, "CLEO\GTA3PAGER.MP3") Audiostream.PerformAction($PAGER, PLAY) :PAGER_92 03F0: enable_text_draw 1 038D: draw_texture 1 position 0@ 60.67 size 128.0 119.47 RGBA 255 255 255 255 03E3: set_texture_to_be_drawn_antialiased 1 :PAGER_134 wait 0 if not 0@ > 64.0 jf @PAGER_181 0@ += 2.0 jump @PAGER_92 0AB2: ret 0 :PAGER_181 wait 0 if not 0@ == 64.0 jf @PAGER_218 jump @PAGER_92 0AB2: ret 0 :PAGER_218 jump @PAGER_134 0A93: end_custom_thread , but when the pager is able to spot flashes and do not know what to do. We tried to fix it with a friend but it was even worse. And here a link to the entire module http://www.przeklej.pl/plik/pulpit-rar-0025tk6177tb Link to comment https://gtaforums.com/topic/403594-sa-~-cleo-script-tutorial-~/?do=findComment&comment=1060303257 Share on other sites More sharing options...
Silent Posted January 20, 2011 Share Posted January 20, 2011 Thx, i didn't try it. Do all cheat-mems work with bool? Some are function calls, the rest should work as a bool. Link to comment https://gtaforums.com/topic/403594-sa-~-cleo-script-tutorial-~/?do=findComment&comment=1060303640 Share on other sites More sharing options...
ZAZ Posted January 20, 2011 Author Share Posted January 20, 2011 Thx, i didn't try it. Do all cheat-mems work with bool? Some are function calls, the rest should work as a bool. well, i changed the gravity-mem to 2 and everything was hovering then i tried a float and caused a crazy world where the trees has bended very much and to restore the gravity to normal world needs to change it to 1006834287 Link to comment https://gtaforums.com/topic/403594-sa-~-cleo-script-tutorial-~/?do=findComment&comment=1060303663 Share on other sites More sharing options...
Silent Posted January 20, 2011 Share Posted January 20, 2011 (edited) Well, I never tested that memory adress in single player, but (according to SA-MP and MTA) it is a float, and default gravity is 0.008. Edit: Checked it now, and it is a float, default is 0.008 Edited January 20, 2011 by SilentPL Link to comment https://gtaforums.com/topic/403594-sa-~-cleo-script-tutorial-~/?do=findComment&comment=1060303665 Share on other sites More sharing options...
ZAZ Posted January 21, 2011 Author Share Posted January 21, 2011 Well, I never tested that memory adress in single player, but (according to SA-MP and MTA) it is a float, and default gravity is 0.008. Edit: Checked it now, and it is a float, default is 0.008 question: are you the reincarnation of plpython? Link to comment https://gtaforums.com/topic/403594-sa-~-cleo-script-tutorial-~/?do=findComment&comment=1060305056 Share on other sites More sharing options...
Silent Posted January 21, 2011 Share Posted January 21, 2011 question: are you the reincarnation of plpython? Hmm, you're the third (fourth?) guy that asks me that. No, I'm not PLPynton The main difference: Birthday: 5 March 1995 Birthday: 31 May 1978 Link to comment https://gtaforums.com/topic/403594-sa-~-cleo-script-tutorial-~/?do=findComment&comment=1060305167 Share on other sites More sharing options...
rieman Posted January 21, 2011 Share Posted January 21, 2011 hey, i was just wandering wether this cleo thing would be able to help me script a vehicle so it cau use the wepons that i have put onto it. if so i was wondering wether i could find any 1 who would be willing to have 60% of the credit for me releasing a vehicle with working weapons. Link to comment https://gtaforums.com/topic/403594-sa-~-cleo-script-tutorial-~/?do=findComment&comment=1060305225 Share on other sites More sharing options...
achil Posted January 22, 2011 Share Posted January 22, 2011 jesus pretty big but usefull you have much future at your life Link to comment https://gtaforums.com/topic/403594-sa-~-cleo-script-tutorial-~/?do=findComment&comment=1060306660 Share on other sites More sharing options...
gtasite1 Posted January 22, 2011 Share Posted January 22, 2011 sh*t f*ck me Link to comment https://gtaforums.com/topic/403594-sa-~-cleo-script-tutorial-~/?do=findComment&comment=1060307224 Share on other sites More sharing options...
gtasite1 Posted January 25, 2011 Share Posted January 25, 2011 (edited) I use this main.scm in Open Vice, but my game is crashed I goto to Tommy hotel http://www.sendspace.pl/file/c03dabadc2658ffcd193c70 Please help me. Please help me Edited January 25, 2011 by gtasite1 Link to comment https://gtaforums.com/topic/403594-sa-~-cleo-script-tutorial-~/?do=findComment&comment=1060310658 Share on other sites More sharing options...
BresoDEV Posted February 9, 2011 Share Posted February 9, 2011 How do I remove any money from CJ. I made the following way, did the first confirmation of the amount of money, then put the opcode 0109 is as follows: 010B: $TOTAL_MONEY = player $PLAYER_CHAR money 0038: $TOTAL_MONEY _2 == $TOTAL_MONEY 000C: $TOTAL_MONEY -= $TOTAL_MONEY _2 0109: player $PLAYER_CHAR money += $TOTAL_MONEY But I think this error in the values of the calculations, and tried to use the opcode 0AD3, but failed, thus: 010B: $TOTAL_MONEY = player $PLAYER_CHAR money 0038: $TOTAL_MONEY _2 == $TOTAL_MONEY 000C: $TOTAL_MONEY -= $TOTAL_MONEY _2 0AD3: $TOTAL_MONEY _3 = format "$TOTAL_MONEY _2 + $TOTAL_MONEY = $TOTAL_MONEY _4" 2 2 40109: player $PLAYER_CHAR money += $TOTAL_MONEY_4 If you can help me, I'll be grateful Link to comment https://gtaforums.com/topic/403594-sa-~-cleo-script-tutorial-~/?do=findComment&comment=1060331541 Share on other sites More sharing options...
martincho Posted February 9, 2011 Share Posted February 9, 2011 I want to create a flashlight for weapons like the mod Ryosuke "accesory" And that can be activated by pressing the letter "Y" can you help me? sorry I'm noob ... Link to comment https://gtaforums.com/topic/403594-sa-~-cleo-script-tutorial-~/?do=findComment&comment=1060331555 Share on other sites More sharing options...
Silent Posted February 9, 2011 Share Posted February 9, 2011 (edited) How do I remove any money from CJ. I made the following way, did the first confirmation of the amount of money, then put the opcode 0109 is as follows: 010B: $TOTAL_MONEY = player $PLAYER_CHAR money 0038: $TOTAL_MONEY _2 == $TOTAL_MONEY 000C: $TOTAL_MONEY -= $TOTAL_MONEY _2 0109: player $PLAYER_CHAR money += $TOTAL_MONEY But I think this error in the values of the calculations, and tried to use the opcode 0AD3, but failed, thus: 010B: $TOTAL_MONEY = player $PLAYER_CHAR money 0038: $TOTAL_MONEY _2 == $TOTAL_MONEY 000C: $TOTAL_MONEY -= $TOTAL_MONEY _2 0AD3: $TOTAL_MONEY _3 = format "$TOTAL_MONEY _2 + $TOTAL_MONEY = $TOTAL_MONEY _4" 2 2 40109: player $PLAYER_CHAR money += $TOTAL_MONEY_4 If you can help me, I'll be grateful You did it a bit wrong. 010B: 0@ = player 0 money0012: 0@ *= -10109: player 0 money += 0@ I want to create a flashlight for weapons like the mod Ryosuke "accesory" And that can be activated by pressing the letter "Y" can you help me?sorry I'm noob ... Tricky business, which need tons of calculations and ATAN function in SCM. @ZAZ Sorry for topic steal, I can surely stop doing that Edited February 9, 2011 by SilentPL Link to comment https://gtaforums.com/topic/403594-sa-~-cleo-script-tutorial-~/?do=findComment&comment=1060331839 Share on other sites More sharing options...
BresoDEV Posted February 9, 2011 Share Posted February 9, 2011 (edited) Very thanks SilentPL....is very simple,,,, and i making totally wrong Edited February 9, 2011 by EdUaRdO - Brazil Link to comment https://gtaforums.com/topic/403594-sa-~-cleo-script-tutorial-~/?do=findComment&comment=1060332698 Share on other sites More sharing options...
ZAZ Posted February 10, 2011 Author Share Posted February 10, 2011 I want to create a flashlight for weapons like the mod Ryosuke "accesory" And that can be activated by pressing the letter "Y" can you help me?sorry I'm noob ... Ryosukes methods are for advanced coding. If you're a noob so start >here< Link to comment https://gtaforums.com/topic/403594-sa-~-cleo-script-tutorial-~/?do=findComment&comment=1060333844 Share on other sites More sharing options...
martincho Posted February 11, 2011 Share Posted February 11, 2011 I want to create a flashlight for weapons like the mod Ryosuke "accesory" And that can be activated by pressing the letter "Y" can you help me?sorry I'm noob ... Ryosukes methods are for advanced coding. If you're a noob so start >here< ok thanks! Link to comment https://gtaforums.com/topic/403594-sa-~-cleo-script-tutorial-~/?do=findComment&comment=1060334072 Share on other sites More sharing options...
gtasite1 Posted February 12, 2011 Share Posted February 12, 2011 @ZAZ main.scm or you can create that will contain all the side missions, all mini-games but without the main story for GTA SA, or can I use your module if you do so main.scm without a main thread. I asked because I do not have too much head as clear is how you do it send me this file to the PM. Thanks in advance. Link to comment https://gtaforums.com/topic/403594-sa-~-cleo-script-tutorial-~/?do=findComment&comment=1060335929 Share on other sites More sharing options...
BresoDEV Posted February 13, 2011 Share Posted February 13, 2011 (edited) @ZAZ main.scm or you can create that will contain all the side missions, all mini-games but without the main story for GTA SA, or can I use your module if you do so main.scm without a main thread. I asked because I do not have too much head as clear is how you do it send me this file to the PM. Thanks in advance. Yes there is a way to remove the missions and maintain the external scripts ... follow the example below: DEFINE MISSIONS 0 //thi define zero missions in mainDEFINE EXTERNAL_SCRIPTS 78 // here put the external script number....original is 78DEFINE UNKNOWN_EMPTY_SEGMENT 0DEFINE UNKNOWN_THREADS_MEMORY 574{$VERSION 3.0.0000}//-------------MAIN---------------03A4: name_thread 'MAIN' 01F0: set_max_wanted_level_to 6 0111: toggle_wasted_busted_check 0 00C0: set_current_time_hours_to 8 minutes_to 0 04E4: unknown_refresh_game_renderer_at 2488.56 -1666.84 03CB: set_rendering_origin_at 2488.56 -1666.84 13.38 0053: $PLAYER_CHAR = create_player #NULL at 2488.56 -1666.84 13.38 01F5: $PLAYER_ACTOR = create_player_actor $PLAYER_CHAR 07AF: $PLAYER_GROUP = player $PLAYER_CHAR group 0373: set_camera_directly_behind_player 01B6: set_weather 0 0001: wait 0 ms 087B: set_player $PLAYER_CHAR clothes_texture "PLAYER_FACE" model "HEAD" body_part 1 087B: set_player $PLAYER_CHAR clothes_texture "JEANSDENIM" model "JEANS" body_part 2 087B: set_player $PLAYER_CHAR clothes_texture "SNEAKERBINCBLK" model "SNEAKER" body_part 3 087B: set_player $PLAYER_CHAR clothes_texture "VEST" model "VEST" body_part 0 070D: rebuild_player $PLAYER_CHAR 01B4: toggle_player $PLAYER_CHAR can_move 1 016A: fade 1 time 0 04BB: select_interior 0 0629: change_integer_stat 181 to 4 016C: restart_if_wasted_at 2027.77 -1420.52 15.99 angle 137.0 town_number 0 016D: restart_if_busted_at 1550.68 -1675.49 14.51 angle 90.0 town_number 0 0180: set_on_mission_flag_to $ONMISSION // Note: your missions have to use the variable defined here 0004: $DEFAULT_WAIT_TIME = 25003E6: remove_text_box // put your create_thread commands here:MISSAO_PRINCIPAL0001: wait 0 ms0256: player $PLAYER_CHAR defined 004D: jump_if_false @MISSAO_PRINCIPAL0001: wait 0 ms0002: jump @MISSAO_PRINCIPAL// put your mods (threads) here//-------------Mission 0---------------// put your missions here//-------------External script 0---------------// It lets you down like the original, it is here that have the external scripts//ex://-------------External script 1 (WARDROBE)---------------:WARROBE//comands here The script will be so great, why not post it in full here That was your question? Edited February 13, 2011 by EdUaRdO - Brazil Link to comment https://gtaforums.com/topic/403594-sa-~-cleo-script-tutorial-~/?do=findComment&comment=1060336618 Share on other sites More sharing options...
gtasite1 Posted February 13, 2011 Share Posted February 13, 2011 (edited) ok tkanks. I am found this file http://zazmahall.de/ZAZGTASANATORIUM/zazma...Stripped%20Main But my question is how to edit the sannybuilder main.scm 3.04 and play on the old record of the game? AND how to use this array with spawn actors $2701 = 0 :INITIAL_19059if 6 > $2701 jf @INITIAL_19159 $2671($2701,6i) = Object.Create(#PORTAKABIN, $2677($2701,6f), $2683($2701,6f), $2689($2701,6f))Object.Angle($2671($2701,6i)) = $2695($2701,6f)Object.ToggleInMovingList($2671($2701,6i)) = FalseObject.RemoveFromMissionCleanupList($2671($2701,6i))$2701 += 1 jump @INITIAL_19059 :INITIAL_19159 Edited February 13, 2011 by gtasite1 Link to comment https://gtaforums.com/topic/403594-sa-~-cleo-script-tutorial-~/?do=findComment&comment=1060337002 Share on other sites More sharing options...
BresoDEV Posted February 13, 2011 Share Posted February 13, 2011 (edited) ok tkanks. I am found this file http://zazmahall.de/ZAZGTASANATORIUM/zazma...Stripped%20Main But my question is how to edit the sannybuilder main.scm 3.04 and play on the old record of the game? AND how to use this array with spawn actors $2701 = 0 :INITIAL_19059if 6 > $2701 jf @INITIAL_19159 $2671($2701,6i) = Object.Create(#PORTAKABIN, $2677($2701,6f), $2683($2701,6f), $2689($2701,6f))Object.Angle($2671($2701,6i)) = $2695($2701,6f)Object.ToggleInMovingList($2671($2701,6i)) = FalseObject.RemoveFromMissionCleanupList($2671($2701,6i))$2701 += 1 jump @INITIAL_19059 :INITIAL_19159 Play with the old records, I think it is not be done This is part of creating objects, you need to create actors use other opcodes: 009A: @TEST_ACTOR = create_actor_pedtype 8 model #FAM2 at 2483.1711 -1650.733 13.4687 0223: set_actor @TEST_ACTOR health_to 250 0173: set_actor @TEST_ACTOR Z_angle_to 177.6617 You want to create objects near the ped? So looks like this: 0107: $2671($2701,6i) = create_object #PORTAKABIN at $2677($2701,6f) $2683($2701,6f) $2689($2701,6f) 0177: set_object $2671($2701,6i) Z_angle_to $2695($2701,6f) 0392: make_object $2671($2701,6i) moveable 0 01C7: remove_object_from_mission_cleanup_list $2671($2701,6i) 0400: store_coords_to 20@ 21@ 22@ from_object $2671($2701,6i) with_offset 0.0 4.0 0.001C7: remove_object_from_mission_cleanup_list $2671($2701,6i) 009A: $ACTOR_TEST = create_actor_pedtype 8 model #FAM2 at 20@ 21@ 22@ 0223: set_actor $ACTOR_TEST health_to 250 0173: set_actor $ACTOR_TEST Z_angle_to 177.6617 but before you need to set the coordinates to create the object You need put the ID of object, not the name... but this is a hard way to do this, you can try this way: (This is one example of create object and ped at Groove, and the actor dancing) //-------------MAIN---------------03A4: name_thread 'OBJECT_PED'0007: $COORD_X = 2491.2278 0007: $COORD_Y = -1672.2573 0007: $COORD_Z = 13.33590007: $RADIUS = 80.0 0007: $ANGULO = 0.0 :OBJECT_PED_690001: wait 0 ms 0256: player $PLAYER_CHAR defined 004D: jump_if_false @OBJECT_PED_69 0001: wait 0 ms 00D6: if 0038: $ONMISSION == 0 004D: jump_if_false @OBJECT_PED_69 0001: wait 0 ms 00D6: if 0256: player $PLAYER_CHAR defined 004D: jump_if_false @OBJECT_PED_69 00D6: if 0007: $COORD_X = 2491.2278 0007: $COORD_Y = -1672.2573 0007: $COORD_Z = 13.33590007: $RADIUS = 80.0 0007: $ANGULO = 0.0 00FE: actor $PLAYER_ACTOR sphere 0 in_sphere $COORD_X $COORD_Y $COORD_Z radius $RADIUS $RADIUS $RADIUS 004D: jump_if_false @OBJECT_PED_69 0247: load_model 16840247: load_model #FAM2 04ED: load_animation "DANCING" :OBJECT_PED_1710001: wait 0 ms 00D6: if and0248: model 1684 available 0248: model #FAM2 available 04EE: animation "DANCING" loaded 0007: $COORD_X = 2491.2278 0007: $COORD_Y = -1672.2573 0007: $COORD_Z = 12.33590007: $RADIUS = 80.0 0007: $ANGULO = 0.0 004D: jump_if_false @OBJECT_PED_171 0107: $OBJECT = create_object 1684 at $COORD_X $COORD_Y $COORD_Z 0177: set_object $OBJECT Z_angle_to $ANGULO 0392: make_object $OBJECT moveable 0 01C7: remove_object_from_mission_cleanup_list $OBJECT 0400: store_coords_to 20@ 21@ 22@ from_object $OBJECT with_offset $ANGULO $ANGULO 5.001C7: remove_object_from_mission_cleanup_list $2671($2701,6i) 009A: $ACTOR_TEST = create_actor_pedtype 8 model #FAM2 at 20@ 21@ 22@ 0223: set_actor $ACTOR_TEST health_to 250 0173: set_actor $ACTOR_TEST Z_angle_to $ANGULO 0812: AS_actor $ACTOR_TEST perform_animation "DAN_Loop_A" IFP_file "DANCING" 4.0 loopA 0 lockX 0 lockY 0 lockF 0 time -1 // versionB 0001: wait 5000 ms 0249: release_model 1684 0249: release_model #FAM2 04EF: release_animation "DANCING" :OBJECT_PED_3110001: wait 0 ms 00D6: if 00FE: actor $PLAYER_ACTOR sphere 0 in_sphere $COORD_X $COORD_Y $COORD_Z radius $RADIUS $RADIUS $RADIUS 004D: jump_if_false @OBJECT_PED_384 0001: wait 0 ms 00D6: if 0038: $ONMISSION == 0 004D: jump_if_false @OBJECT_PED_384 0001: wait 0 ms 0002: jump @OBJECT_PED_311 :OBJECT_PED_3840108: destroy_object $OBJECT 009B: destroy_actor $ACTOR_TEST 0002: jump @OBJECT_PED_69 I hope I have helped you Sorry my english Edited February 13, 2011 by EdUaRdO - Brazil Link to comment https://gtaforums.com/topic/403594-sa-~-cleo-script-tutorial-~/?do=findComment&comment=1060337427 Share on other sites More sharing options...
gtasite1 Posted February 13, 2011 Share Posted February 13, 2011 ok tkanks Link to comment https://gtaforums.com/topic/403594-sa-~-cleo-script-tutorial-~/?do=findComment&comment=1060337541 Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now