Kamazy 0 Posted May 15, 2006 I wana start scripting my own mods so i want to know if there's a clean main.scm (SA) i can start with. By clean i mean one without mission,pick-ups and other stuff that is on gta so i can start making my own missions and pick-ups. Share this post Link to post Share on other sites
LDzOmbieHunter 0 Posted May 15, 2006 Do a search in this forum there are several posted. I do not have a totally clean one or I would post it for you. Sorry Share this post Link to post Share on other sites
Y_Less 0 Posted May 15, 2006 And re your topic title, that's not really the way to get help, either improve your attitude or I'll bin your topics. Share this post Link to post Share on other sites
Demarest 22 Posted May 15, 2006 I think he was comically referring to that old movie quote "Badges? We don't need no stinkin badges! Though the correct title for the topic would be stripped SCM. Of course if we're talking proper, the idea would be to run a search first before creating a topic Share this post Link to post Share on other sites
Kamazy 0 Posted May 15, 2006 (edited) @LDzOmbieHunter: Thx i'll search for one. Guess i should have done that before i posted. @Y_Less: Learn to take a joke. @Demarest: I would have wrote "Description!? We don’t need to stintin’ description!" but i was too long. [edit] LDzOmbieHunter: mind pointing me to one of them? i con't seem to find any. Edited May 15, 2006 by Kamazy Share this post Link to post Share on other sites
LDzOmbieHunter 0 Posted May 15, 2006 here you go. This is one Dem posted a month or so ago. I will assume you know how to set the player start position variables. DEFINE VERSION SA 0.33 0002: jump ££Second_Segment DEFINE MEMORY 43800; Equals Mission Builder type global variable range $2 to $10949 :Second_Segment 0002: jump ££Third_Segment DEFINE OBJECTS 3 DEFINE OBJECT MOO ; This is an unused object. You can put anything here. DEFINE OBJECT BRIBE ; Object number -1 DEFINE OBJECT HEALTH ; Object number -2 :Third_Segment 0002: jump ££Fourth_Segment DEFINE MISSIONS 0 :Fourth_Segment 0002: jump ££Fifth_Segment DEFINE EXTERNAL_SCRIPTS 0 :Fifth_Segment 0002: jump ££Sixth_Segment DEFINE UNKNOWN_FIFTH_SEGMENT DEFINE UNKNOWN1 0 :Sixth_Segment 0002: jump ££MAIN_1 DEFINE UNKNOWN_SIXTH_SEGMENT DEFINE UNKNOWN3 574 ;-------------MAIN--------------- :MAIN_1 03A4: name_thread 'MAIN' 016A: fade 0 () 0 ms 01F0: set_max_wanted_level_to 6 0111: set_wasted_busted_check_to 0 (disabled) 00C0: set_current_time 10 0 0007: @10 = -300.0 0007: @11 = -150.0 0007: @12 = 0.0 04E4: unknown_refresh_game_renderer_at @10 @11 03CB: set_camera @10 @11 @12 0053: $PLAYER_CHAR = create_player #NULL at @10 @11 @12 01F5: $PLAYER_ACTOR = create_emulated_actor_from_player $PLAYER_CHAR 0629: change_stat 181 (islands unlocked) to 4 ; integer see statdisp.dat 01B6: set_weather 1 070D: $PLAYER_CHAR 04BB: select_interior 0;; select render area 01B4: set_player $PLAYER_CHAR frozen_state 1 (unfrozen) 01B7: release_weather 016C: restart_if_wasted at @10 @11 @12 angle 0.0 unknown 0 016D: restart_if_busted at @10 @11 @12 angle 0.0 unknown 0 016A: fade 1 () 1000 ms 0001: wait 200 ms 03E6: remove_text_box :MAIN_3 0001: wait 2500 ms 0002: jump ££MAIN_3 Share this post Link to post Share on other sites
Kamazy 0 Posted May 16, 2006 So i erese the original Main and add this lines. (sry real noob at coding) And i'll look into tutorials about everything else. THX Share this post Link to post Share on other sites
LDzOmbieHunter 0 Posted May 16, 2006 yes erase the orig and add these save as something else. then replace the coords on these lines: 0007: @10 = -300.0 0007: @11 = -150.0 0007: @12 = 0.0 with the spot you want CJ to spawn at Share this post Link to post Share on other sites
Kamazy 0 Posted May 16, 2006 ok i did that. and also changed 0053: $PLAYER_CHAR = create_player #NULL at @10 @11 @12 to 0053: $PLAYER_CHAR = create_player 0 at @10 @11 @12 now cj spawns in grove in his underwear. i tryed changing the 0 to 9,7 and other ped IDs but i didn't work why? I'm mostly looking at the original code and learning what i does. Share this post Link to post Share on other sites
LDzOmbieHunter 0 Posted May 16, 2006 AHH. You need to dress him Add these lines 087B: set_player $PLAYER_CHAR clothes "VEST" "VEST" 0 087B: set_player $PLAYER_CHAR clothes "JEANSDENIM" "JEANS" 2 087B: set_player $PLAYER_CHAR clothes "SNEAKERBINCBLK" "SNEAKER" 3 087B: set_player $PLAYER_CHAR clothes "PLAYER_FACE" "HEAD" 1 right after 04BB: select_interior 0;; select render area Share this post Link to post Share on other sites
Kamazy 0 Posted May 16, 2006 Those lines worked but only when i put them here. 01B6: set_weather 1 087B: set_player $PLAYER_CHAR clothes "VEST" "VEST" 0 087B: set_player $PLAYER_CHAR clothes "JEANSDENIM" "JEANS" 2 087B: set_player $PLAYER_CHAR clothes "SNEAKERBINCBLK" "SNEAKER" 3 087B: set_player $PLAYER_CHAR clothes "PLAYER_FACE" "HEAD" 1 070D: $PLAYER_CHAR i saw it was there in the original code so i tryed it and it worked. but i doesn't work for me if i put it after 04BB: select_interior 0;; select render area I also made weapon spawns. Share this post Link to post Share on other sites
Kamazy 0 Posted May 16, 2006 (edited) Where and what code do i put to have a save pickup? [edit] oops Double posted. Edited May 16, 2006 by Kamazy Share this post Link to post Share on other sites
random_download 0 Posted May 16, 2006 For save pickups you need not only to create an icon, but you also need a sniffer thread to check for if it is picked up: @startcreate_pickup #model, 0, X, Y, Z, [email protected] 0if 0is_pickup_picked_up $Save_Handlejf @[email protected] 0if 0is_save_donejf @issavedjump @start GTA:MA code, but you can find the opcodes to use in MB by searching here You might also want to create a radar icon. Share this post Link to post Share on other sites
Kamazy 0 Posted May 16, 2006 (edited) Thats a GREAT web site THX. [edit] ok.. made a icon (still looking for the save icon ID) with a red circle but i guess i can put it under ground where noone will se it. As for the saving still not close. [edit] My first script that does something. :MAIN_30001: wait 5000 ms00b6: if 000e1: is_key_pressed 0 18004D: jump_if_false ££MAIN_3 0003: shake_cam 1000 0002: jump ££MAIN_3 Shakes cam is crouch if pressed. [edit] question: If i make it like this :MAIN_30001: [u]wait 1 ms[/u]00b6: if 000e1: is_key_pressed 0 18004D: jump_if_false ££MAIN_3 0003: shake_cam 1000 0002: jump ££MAIN_3 So it loops faster will it couse and kind of problem latter. And is there a way to if the key is pressed it jumps not it jumps in key is not pressed? Edited May 16, 2006 by Kamazy Share this post Link to post Share on other sites
random_download 0 Posted May 16, 2006 If you change the first digit of a conditional ocpode from 0 to 8, it makes it NOT, eg.: 00b6: if 080e1: NOT is_key_pressed 0 18004D: jump_if_false ££MAIN_3 Notice the 8 at the start of the opcode (the "NOT" is not needed but it makes it easier to see). The code will now check to see if the key is not pressed, and as it is a jump_if_false the NOT and false cancel out, so it will jump when the key is pressed. If you use wait 1 in a loop, then it would just check more often. This doesn't often casue problems unless you have lots of low wait loops at the same time. The main problem this causes is in key_pressed checks as you are doing. The user when tapping a key will infact hold it down for more than 1 ms, so your code will run several times (if it is wait 1 probably about 200-300 times) when the user only pressed the key once. You should adjust the wait time until it "feels" the right time. I think around 1000 is good IIRC. As for the red circle and save icon, find label ":PSAVE1_3" in the original scm and you will find an example of creating save icons. The basic code you need for a save icon is opcode 03d8. It displays the save screen. Then you just need to check to see if your save pickup is picked up yet, once it is show the save screen, then loop until the user has finished saving, then re-create the pickup and probably move the player out of the way so he doesn't trigger the pickup again. Share this post Link to post Share on other sites
Kamazy 0 Posted May 16, 2006 (edited) Ok i'll try that. [edit] I'm gona use this to check if it was picked up. 0214: is_pickup_picked_up ($pickupid) [edit] ok i got the saving to work right but with a weapons pick up cuz then i put this line 0213: ($ID) = create_pickup #PICKUPSAVE type 3 at X Y Z it says it can't find >#PICKUPSAVE< in the IDE. so i guess i need the save pickups iD. does anyone know it? Edited May 17, 2006 by Kamazy Share this post Link to post Share on other sites
random_download 0 Posted May 16, 2006 You should have near the top of the scm file: DEFINE OBJECT PICKUPSAVE ; Object number -43 But I guess you can use ID 43 instead. Share this post Link to post Share on other sites
Kamazy 0 Posted May 16, 2006 (edited) 0213: $811 = create_pickup 43 type 3 at 2486.356 -1645.457 15.07718 :MAIN_30001: wait 500 ms00D6: if 00214: pickup $811 picked_up004D: jump_if_false ££MAIN_3 0002: jump ££MAIN_4 :MAIN_403D8: show_save_screen0213: $811 = create_pickup 43 type 3 at 2486.356 -1645.457 15.077180002: jump ££MAIN_3 This seems to work i just have to hove CJ. But the save pick-up is invisible or nothing. BTW: This has a funny misstake by me. \/ (All controled as 1 character) [edit] Ok got the save pickup to show with this line. DEFINE OBJECT PICKUPSAVE; Object number -2 In the original it's nimber -43 cuz thats just it's place in line. i have only bribe and savepick so bribe is 1 and savepickup is 2. [edit] Question: Does everything in my script have to loop. For axample: Savegamepickup then goes to Ammunation then goes to Burgershop then to back to Savegamepickup. So my whole script should loop around all the scripts? [edit] Second script that does something. :Telle00D6: if 000e1: is_key_pressed 0 8004D: jump_if_false ££MAIN_30002: jump ££Tlprt:Tlprt016A: fade 0 () 1000 ms0247: request_model 4110001: wait 1000 ms00A1: put_actor $PLAYER_ACTOR at @10 @11 @1200D6: if 00248: is_model_available 411004D: jump_if_false ££MAIN_300A5: $GroveCar01 = create_car 411 at 2499.146 -1666.746 13.34858016A: fade 1 () 1000 ms 0002: jump ££MAIN_3 Edited May 17, 2006 by Kamazy Share this post Link to post Share on other sites
random_download 0 Posted May 17, 2006 After the initialisation eg. create the player, set respawn points etc. then usually in stripped scripts and in the original scm the code goes on into an endless loop that handles various things (or does nothing in stripped scripts). A while ago CyQ pointed out that you can infact just do end_thread instead. ...0001: wait 200 ms03E6: remove_text_box:MAIN_30001: wait 2500 ms0002: jump ££MAIN_3 If you want to you can just do this instead: ...0001: wait 200 ms03E6: remove_text_box004E: end_thread About your code: When making global vars try not to name them things like $811 as this is confusing, and more importantly if used in a non-stripped script can reference a var used elsewhere and mess things up. Also, in your car spawning script: :Telle0001: wait 200 ms00D6: if 000e1: is_key_pressed 0 8004D: jump_if_false ££Telle016A: fade 0 () 1000 ms0247: request_model 4110001: wait 1000 ms00A1: put_actor $PLAYER_ACTOR at @10 @11 @12:Tlprt0001: wait 10 ms00D6: if 00248: is_model_available 411004D: jump_if_false ££Tlprt00A5: $GroveCar01 = create_car 411 at 2499.146 -1666.746 13.34858016A: fade 1 () 1000 ms0002: jump ££Telle That would be better. Labels do not take up any space in the compiled scm file, so don't be afraid to limit the number you use. By checking to see if the model is loaded like this, you only request the model once. Also, if you have code right before a label there is no need to jump to it, as the code will run on anyway: <do some stuff here>0002: jump ££label; This jump is not needed as the place you are jumping to is going to be run next anyway:label<some more stuff> Share this post Link to post Share on other sites
Kamazy 0 Posted May 17, 2006 Guess i still have stuff to learn. about the "004E: end_thread" this should only be used if there's nothing to check right? If i use it and then have the :Telle before it. Won't that make it :telle stop working? BTW: What's the opcode to make cj look like a ped? THX. Share this post Link to post Share on other sites
random_download 0 Posted May 17, 2006 004F creates a thread, and 004E ends it. Before :MAIN_3 in your stripped script is where you would insert your create_threads. You don't have to end a thread, you can just have it looping indefinately as with the 'MAIN' thread. The idea of a thread is that it runs simultaneously with all other threads (although this is not strictly true). Share this post Link to post Share on other sites
Kamazy 0 Posted May 17, 2006 Ow nice so if i use 2 therd they will loop simultaneously and i wont have to make everything loop together in 1 loop. Hope this is right. Share this post Link to post Share on other sites
random_download 0 Posted May 17, 2006 Yep. You can have for example, one thread to check if the player pickup the save icon and another to check if the player is pressing the keys to spawn a car. Share this post Link to post Share on other sites
Kamazy 0 Posted May 17, 2006 Here's the new script but the Saving won't work and i'm not sure why. DEFINE VERSION SA 0.330002: jump ££Second_SegmentDEFINE MEMORY 43800; Equals Mission Builder type global variable range $2 to $10949:Second_Segment0002: jump ££Third_SegmentDEFINE OBJECTS 3DEFINE OBJECT MOO; This is an unused object. You can put anything here.DEFINE OBJECT BRIBE; Object number -1DEFINE OBJECT PICKUPSAVE; Object number -2:Third_Segment0002: jump ££Fourth_SegmentDEFINE MISSIONS 0:Fourth_Segment0002: jump ££Fifth_SegmentDEFINE EXTERNAL_SCRIPTS 0:Fifth_Segment0002: jump ££Sixth_SegmentDEFINE UNKNOWN_FIFTH_SEGMENTDEFINE UNKNOWN1 0:Sixth_Segment0002: jump ££MAIN_1DEFINE UNKNOWN_SIXTH_SEGMENTDEFINE UNKNOWN3 574;-------------MAIN---------------:MAIN_103A4: name_thread 'MAIN'016A: fade 0 () 0 ms01F0: set_max_wanted_level_to 00111: set_wasted_busted_check_to 0 (disabled)00C0: set_current_time 9 00007: @10 = 2488.5620007: @11 = -1666.8640007: @12 = 12.875704E4: unknown_refresh_game_renderer_at @10 @1103CB: set_camera @10 @11 @120053: $PLAYER_CHAR = create_player 0 at @10 @11 @12 01F5: $PLAYER_ACTOR = create_emulated_actor_from_player $PLAYER_CHAR0629: change_stat 181 (islands unlocked) to 4; integer see statdisp.dat01B6: set_weather 1087B: set_player $PLAYER_CHAR clothes "VEST" "VEST" 0 087B: set_player $PLAYER_CHAR clothes "JEANSDENIM" "JEANS" 2 087B: set_player $PLAYER_CHAR clothes "SNEAKERBINCBLK" "SNEAKER" 3 087B: set_player $PLAYER_CHAR clothes "PLAYER_FACE" "HEAD" 1 070D: $PLAYER_CHAR04BB: select_interior 0;; select render area01B4: set_player $PLAYER_CHAR frozen_state 1 (unfrozen)01B7: release_weather 016C: restart_if_wasted at @10 @11 @12 angle 0.0 unknown 0016D: restart_if_busted at @10 @11 @12 angle 0.0 unknown 0016A: fade 1 () 1000 ms0001: wait 200 ms03E6: remove_text_box ;--------------------------- Tread_Creating-----------------------------------004F: create_thread ££ChSave004F: create_thread ££Telle;----------------------------------------------------------------------------- 004E: end_thread;---------------------------Check Save pickup---------------------------------:Chsave03A4: name_thread 'ChSave'0007: @10 = 2488.5620007: @11 = -1666.8640007: @12 = 12.87570001: wait 500 ms0213: $811 = create_pickup #PICKUPSAVE type 3 at 2499.146 -1666.746 13.34858 00D6: if 00214: pickup $811 picked_up004D: jump_if_false ££Chsave:Save_Game03D8: show_save_screen00A1: put_actor $PLAYER_ACTOR at @10 @11 @12016A: fade 1 (back) 1000 ms0213: $811 = create_pickup #PICKUPSAVE type 3 at 2499.146 -1666.746 13.348580002: jump ££Chsave004E: end_thread;-----------------------------Telleport and spawn car------------------------:Telle03A4: name_thread 'Telle'0007: @10 = 2488.5620007: @11 = -1666.8640007: @12 = 12.87570001: wait 500 ms00D6: if 000e1: is_key_pressed 0 8004D: jump_if_false ££Telle016A: fade 0 () 1000 ms0247: request_model 4110001: wait 1000 ms00A1: put_actor $PLAYER_ACTOR at @10 @11 @12:Tlprt0001: wait 10 ms00D6: if 00248: is_model_available 411004D: jump_if_false ££Telle00A5: $GroveCar01 = create_car 411 at 2499.146 -1666.746 13.34858016A: fade 1 () 1000 ms 0002: jump ££Telle004E: end_thread I think Chsave works cuz the pickup shows and respawns after i pick it up but i don't save first or get moved. i also tryed adding a jump after 004D: jump_if_false ££Chsave but still didn't work. The telleport and car spawn work fine. Share this post Link to post Share on other sites
Demarest 22 Posted May 18, 2006 Here's the new script but the Saving won't work and i'm not sure why. A few things I'm seeing here... There's no reason to end the MAIN thread immediately after creating 2 threads. If you're done with MAIN, then simply make it one of the new threads. In the Chsave thread, you loop name_thread and the assignment of the vars. Not necessary. Same is true of your Telle thread. Do NOT use DMA unless you know what it is and know that you need to be using it. The MB readme says to make custom vars by giving them textual names, so do that. You use the show_save_screen command, but don't bother to loop a is_save_done. This shows a lack of immitating existing code. Immitating existing code of course being the surest path to successful coding. You have a jump command immediately followed by an end_thread command. Because of the jump, this end_thread will never be reached and therefore not needed. end_thread is not a requirement. If you'd like to keep threads visually separated, doing so by way of commented lines like you have is the way, not by adding needless commands that will add to the weight of your SCM and its processing time. Same is true of your Telle thread. An is_model_available loop should do just that: loop. Not jump back in the event that it's false. If you're going to use a model to spawn a car or an actor, you need to discard that model once you're finished using it. Likewise, if you no longer need the code to track a car or actor you've created, you need to remove_references to that object. Both of these add to crash free code by not overloading memory. As always, this is not meant to be harsh, but to help. I realize it's a lot, but you seem like somebody who has a real future in coding, so probably best to get into good habits straightaway, eh? Share this post Link to post Share on other sites
random_download 0 Posted May 18, 2006 Also something you might want to consider in your Telle thread, is that if the player is in a car when the press the key then the game will crash. You should check to see if the player is in a car, and if he is remove him using the remove_actor_from_car_and_put_at opcode. Share this post Link to post Share on other sites
Kamazy 0 Posted May 18, 2006 @ Random_downlaod: It doesn't crash the game just telleports him with the car he's driving. But i guess i should telleport him without the car. @ Demarest: There's no reason to end the MAIN thread immediately after creating 2 threads. If you're done with MAIN, then simply make it one of the new threads. I know that i was just testing making threads. In the Chsave thread, you loop name_thread and the assignment of the vars. Not necessary. Same is true of your Telle thread. Ok. vers shouldn't be looped got it. Do NOT use DMA unless you know what it is and know that you need to be using it. The MB readme says to make custom vars by giving them textual names, so do that. Ok. So give them names not numbers. You use the show_save_screen command, but don't bother to loop a is_save_done. This shows a lack of immitating existing code. Immitating existing code of course being the surest path to successful coding. This works so why change it. (Won't add is_save_done loop) You have a jump command immediately followed by an end_thread command. Because of the jump, this end_thread will never be reached and therefore not needed. end_thread is not a requirement. If you'd like to keep threads visually separated, doing so by way of commented lines like you have is the way, not by adding needless commands that will add to the weight of your SCM and its processing time. Same is true of your Telle thread. Oh i thought that threads had to be ended to work. Now i know they don't. An is_model_available loop should do just that: loop. Not jump back in the event that it's false. Lol i didn't even know that is_model_available should be loop. If you're going to use a model to spawn a car or an actor, you need to discard that model once you're finished using it. Likewise, if you no longer need the code to track a car or actor you've created, you need to remove_references to that object. Both of these add to crash free code by not overloading memory. You mean with this opcode 01C3: remove_references_to_car $GroveCar01? As always, this is not meant to be harsh, but to help. I realize it's a lot, but you seem like somebody who has a real future in coding, so probably best to get into good habits straightaway, eh? Harsh? I didn't see it like that. BTW: got the save to work. :CSPkup0213: $Pickupsave01 = create_pickup #PICKUPSAVE type 3 at 2499.146 -1666.746 13.34858 :Chsave0001: wait 500 ms00D6: if 00214: pickup $Pickupsave01 picked_up004D: jump_if_false ££Chsave:Save_Game03D8: show_save_screen0007: @10 = 2488.5620007: @11 = -1666.8640007: @12 = 12.875700A1: put_actor $PLAYER_ACTOR at @10 @11 @12016A: fade 1 (back) 1000 ms0213: $Pickupsave01 = create_pickup #PICKUPSAVE type 3 at 2499.146 -1666.746 13.348580002: jump ££CSPkup I guess cuz i was making a new pickup every loop it didn't work. One step closer to making better code Share this post Link to post Share on other sites
random_download 0 Posted May 18, 2006 It does work if you don't do an is_save_done loop, but it is good practice to do so as it is how the engine expects it to be handled. You can put random "if 0" commands all over the place and the code will still run, but it is not the "proper" way to do things. Also, the code you just posted looks good except that after you have saved it will recreate the pickup twice Share this post Link to post Share on other sites
Kamazy 0 Posted May 18, 2006 (edited) it will recreate the pickup twice Dm i missed that. THX [edit] You can put random "if 0" commands all over the place and the code will still run, but it is not the "proper" way to do things. my save code has only 1 "if 0" in the loop. And i'm not 100% sure what a is_save_done does as the game and scripts is paused then you'r saving. So, what is is_save_done suposed to do? [edit] @Demarest you need to discard that model once you're finished using it remove_references <---- This one release_model <---------- or this one remove_references is what you say but release_model tells engine to release resources if model isnt used acording to http://sa-db.webtools4you.net/?search=model&show=all So i'm kinda canfused. Both work. remove_references doesn't allow me to spawn cars on top of each other if i don't drive it first. (usualy when i telleport again a car gets spawned inside the old car. So, this is good. remove_model doesn't seem to do anything to how the script works. Hmm... i might use both of them. Here's the newest telle code\/ :Telle03A4: name_thread 'Telle'0001: wait 500 ms00D6: if 000e1: is_key_pressed 0 8004D: jump_if_false ££Telle016A: fade 0 () 1000 ms0247: request_model 4110001: wait 1000 ms0007: @10 = 2488.5620007: @11 = -1666.8640007: @12 = 12.875700A1: put_actor $PLAYER_ACTOR at @10 @11 @12:Tlprt0001: wait 10 ms00D6: if 00248: is_model_available 411004D: jump_if_false ££Tlprt00A5: $GroveCar01 = create_car 411 at 2499.146 -1666.746 13.3485801C3: remove_references_to_car $GroveCar010249: release_model $GroveCar01016A: fade 1 () 1000 ms 0002: jump ££Telle How many misstake does it have. [edit] i tryed this and it made my GTA:SA freee right after loading done. :MLOAD0247: request_model 28:Cskin00D6: if 00248: is_model_available 28004D: jump_if_false ££Cskin09c7: change_player_model $PLAYER_ACTOR 28 It's not done but it should change the player model to model 28 (ped). So what's wrong? And can any1 point me to the GTA:SA crash killer. I'm not 100% sure thats the name but it's the tool that turns off SA then you press F11 or some other F#. [edit] ok found crash killer. http://downloads.gtarumble.co.uk/index.php?act=view&id=3 good tool for people who are experimenting with scripting. Edited May 18, 2006 by Kamazy Share this post Link to post Share on other sites
random_download 0 Posted May 18, 2006 (edited) release_model should be like: "release_model 411". When you use request_model it loads the model into memory, using release_model frees that memory up again. remove_references makes the car just like any random car, ie. if you walk far enough away it will disappear. As for your code, "0249: release_model $GroveCar01" should be "0249: release_model 411", but other than that it looks fine. my save code has only 1 "if 0" in the loop. And i'm not 100% sure what a is_save_done does as the game and scripts is paused then you'r saving. So, what is is_save_done suposed to do? Your if opcodes are fine, I was just using it as an example. You should use is_save_done because the game might not actually freeze during the show_save_screen, which would result in problems. is_save_done just makes sure that you don't get any crashes, but also because it is what was done in original code. For example, the name_thread opcode doesn't actually do anything and there is no need for it but people still use it as it immitates the original code. It's not done but it should change the player model to model 28 (ped). So what's wrong? When the opcode references the "player" use $player_char, when it is "actor" use $player_actor (or another actor if that is what you are doing). Most of the opcodes that use $player_char were removed in SA anyway, so you shouldn't come across many of these. Edited May 18, 2006 by random_download Share this post Link to post Share on other sites