JT_Mix Posted February 23, 2009 Share Posted February 23, 2009 Is it possible for you to deploy tire spikes with cleo? if so has anyone got the code? thanks Link to comment Share on other sites More sharing options...
ZAZ Posted February 23, 2009 Share Posted February 23, 2009 Is it possible for you to deploy tire spikes with cleo?if so has anyone got the code? thanks you mean TEMP_STINGER2 of mission Puncture Wounds ? I believe its not done as cleo. Its a bit of work. Needs to place the object TEMP_STINGER2 on street and check if a car is at same coord then deflate its tire 04FE: deflate_tire 1 on_car [email protected] CLEO MODS CLEO Script Tutorial Link to comment Share on other sites More sharing options...
PatrickW Posted February 24, 2009 Share Posted February 24, 2009 (edited) Some years ago I created such a mod for Vice City (Stinger Drop Mod), demonj0e converted it to San Andreas. It's not a cleo script though, and that might be a bit hard as it makes extensive use of small threads and I don't think CLEO-scripts allow that. Edited February 24, 2009 by PatrickW Link to comment Share on other sites More sharing options...
2pacproducer2 Posted February 24, 2009 Share Posted February 24, 2009 no, the script is pretty short, and using not so complicated speech. I think that could be writen as CLEO. Link to comment Share on other sites More sharing options...
PatrickW Posted February 24, 2009 Share Posted February 24, 2009 I'm not an expert in the limitations of CLEO-scripts, but I was under the impression that you couldn't start new threads from within them. Not based on experience, but on this text from the sannybuiulder CLEO helppages: One file – one thread. Each CLEO-script must be made as a single thread compiled in a single file. If you need more threads for your script, use the opcodes 004F or 0A92, depending of where is that additional thread located - in the main.scm or in a separate cs-file. But maybe an option would be to have the small "stringer-thread" in a seperate CLEO-file, and start that from the sniffer-thread with opcode 0A92. Certainly worth a try. Link to comment Share on other sites More sharing options...
PatrickW Posted February 24, 2009 Share Posted February 24, 2009 (edited) Stinger Drop Mod for San Andreas (CLEO3 version) Thanx to demonj0e for making the SA conversion of the original Stinger Drop Mod. stinger_drop.txt {$CLEO .cs}:stinger_sniff_thread03A4: name thread "ST_SNIF":stinger_sniff_loop0001: wait 100 ms00D6: if 00256: player $PLAYER_CHAR defined004D: jump_if_false @stinger_sniff_loop 00D6: if 100E1: key pressed 0 17 00DF: actor $PLAYER_ACTOR driving004D: jump_if_false @stinger_sniff_loop 03C0: [email protected] = actor $PLAYER_ACTOR car0407: create coordinate [email protected] [email protected] [email protected] from car [email protected] offset 0.0 -2.5 1.00174: [email protected] = car [email protected] z_angle0009: [email protected] += 90.0;; floating-point values02CE: [email protected] = ground z [email protected] [email protected] [email protected]: [email protected] += 0.10A92: create_custom_thread "stinger.s" [email protected] [email protected] [email protected] [email protected]: wait 500 ms0002: jump @stinger_sniff_loop stinger.txt {$CLEO .s}:Stinger_thread 0004: [email protected] = 0 029B: [email protected] = init_object 2899 at [email protected] [email protected] [email protected]: set object [email protected] z angle to [email protected]: remove_object_from_mission_cleanup_list [email protected]: [email protected] = [email protected]: [email protected] -= 3.0000B: [email protected] += 3.00007: [email protected] = [email protected]: [email protected] -= 3.0000B: [email protected] += 3.0 repeat 0001: wait 250 ms 0007: [email protected] = -1 053E: [email protected] = get_random_car_with_model -1 in_rectangle_cornerA [email protected] [email protected] cornerB [email protected] [email protected] if NOT [email protected] == -1;; integer values then 04FE: deflate_tire 0 on_car [email protected] 04FE: deflate_tire 1 on_car [email protected] 04FE: deflate_tire 2 on_car [email protected] 04FE: deflate_tire 3 on_car [email protected] enduntil [email protected] > 100000108: destroy object [email protected]: end_custom_thread Compile both files in your CLEO directory. Start a new game, and drop stingers with "FIRE" in any vehicle. Edited February 24, 2009 by PatrickW Link to comment Share on other sites More sharing options...
cj360 Posted February 24, 2009 Share Posted February 24, 2009 You can make sperate threads in cleo bc7 did it in his mod Where would I find the ID for#TEMP_STINGER2? I don't remember Link to comment Share on other sites More sharing options...
cj360 Posted February 24, 2009 Share Posted February 24, 2009 You beat me to it You can make sperate threads in cleo bc7 did it in his mod sry for double post Link to comment Share on other sites More sharing options...
JT_Mix Posted February 24, 2009 Author Share Posted February 24, 2009 crashes game. Link to comment Share on other sites More sharing options...
PatrickW Posted February 24, 2009 Share Posted February 24, 2009 (edited) You can make sperate threads in cleo bc7 did it in his mod Where would I find the ID for#TEMP_STINGER2? I don't remember The ID of the stinger can be found in the large table at the top of a standard main.scm. I guess not, afterall @JT_Mix: Did you try it with a default SA main.scm or with a modded one ? Edited February 24, 2009 by PatrickW Link to comment Share on other sites More sharing options...
ZAZ Posted February 24, 2009 Share Posted February 24, 2009 (edited) data\maps\leveldes\levelxre.ide : 2899, temp_stinger2, temp_stinger, 100, 128 029B: [email protected] = init_object 2899 at [email protected] [email protected] [email protected] Edited February 25, 2009 by ZAZ CLEO MODS CLEO Script Tutorial Link to comment Share on other sites More sharing options...
PatrickW Posted February 24, 2009 Share Posted February 24, 2009 I stand corrected. That is indeed the correct value. Edited it in my post above.. ZAZ: Link to comment Share on other sites More sharing options...
Seemann Posted February 25, 2009 Share Posted February 25, 2009 (edited) CLEO scripts only use global IDs of models. Use the Ctrl+Alt+H feature to convert a model name to ID and vice versa. Like this: Edited February 25, 2009 by Seemann Sanny Builder 3 • SA Memory Handling • OpenIV • gtamodding.com CLEO.li - The CLEO Library - Official site Link to comment Share on other sites More sharing options...
PatrickW Posted February 25, 2009 Share Posted February 25, 2009 Thanx for the tip, seeman Wouldn't it be possible to also support this "translation" for CLEO-scripts during compilation ? So that you can simply use the symbolic name "#TEMP_STINGER2" in CLEO-scripts also ? Link to comment Share on other sites More sharing options...
Seemann Posted February 25, 2009 Share Posted February 25, 2009 Yea, that would be useful, however I'm a supporter of that a scripter should know how the things work and why the code is compiled in a certain way. Anyway, added on the todo list. Sanny Builder 3 • SA Memory Handling • OpenIV • gtamodding.com CLEO.li - The CLEO Library - Official site Link to comment Share on other sites More sharing options...
ZAZ Posted February 25, 2009 Share Posted February 25, 2009 Yea, that would be useful, however I'm a supporter of that a scripter should know how the things work and why the code is compiled in a certain way. Anyway, added on the todo list. todo list. ?? you will release a new version ?? and for gta4, is there anything in work or will it stay by lua? or maybe a lua editer ? CLEO MODS CLEO Script Tutorial Link to comment Share on other sites More sharing options...
Seemann Posted February 25, 2009 Share Posted February 25, 2009 Sanny Builder and CLEO are far from completion. I still have in mind a lot of features to add for both. So, yea, new version will eventually come. As for GTA 4... let it be surprise! Sanny Builder 3 • SA Memory Handling • OpenIV • gtamodding.com CLEO.li - The CLEO Library - Official site Link to comment Share on other sites More sharing options...
coin-god Posted February 25, 2009 Share Posted February 25, 2009 Sanny Builder and CLEO are far from completion. I still have in mind a lot of features to add for both. So, yea, new version will eventually come. As for GTA 4... let it be surprise! Oh.. im impatient to see teh new stuff Link to comment 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