Jump to content
    1. Welcome to GTAForums!

    1. GTANet.com

    1. GTA Online

      1. Los Santos Drug Wars
      2. Updates
      3. Find Lobbies & Players
      4. Guides & Strategies
      5. Vehicles
      6. Content Creator
      7. Help & Support
    2. Red Dead Online

      1. Blood Money
      2. Frontier Pursuits
      3. Find Lobbies & Outlaws
      4. Help & Support
    3. Crews

    1. Grand Theft Auto Series

      1. Bugs*
      2. St. Andrews Cathedral
    2. GTA VI

    3. GTA V

      1. Guides & Strategies
      2. Help & Support
    4. GTA IV

      1. The Lost and Damned
      2. The Ballad of Gay Tony
      3. Guides & Strategies
      4. Help & Support
    5. GTA San Andreas

      1. Classic GTA SA
      2. Guides & Strategies
      3. Help & Support
    6. GTA Vice City

      1. Classic GTA VC
      2. Guides & Strategies
      3. Help & Support
    7. GTA III

      1. Classic GTA III
      2. Guides & Strategies
      3. Help & Support
    8. Portable Games

      1. GTA Chinatown Wars
      2. GTA Vice City Stories
      3. GTA Liberty City Stories
    9. Top-Down Games

      1. GTA Advance
      2. GTA 2
      3. GTA
    1. Red Dead Redemption 2

      1. PC
      2. Help & Support
    2. Red Dead Redemption

    1. GTA Mods

      1. GTA V
      2. GTA IV
      3. GTA III, VC & SA
      4. Tutorials
    2. Red Dead Mods

      1. Documentation
    3. Mod Showroom

      1. Scripts & Plugins
      2. Maps
      3. Total Conversions
      4. Vehicles
      5. Textures
      6. Characters
      7. Tools
      8. Other
      9. Workshop
    4. Featured Mods

      1. Design Your Own Mission
      2. OpenIV
      3. GTA: Underground
      4. GTA: Liberty City
      5. GTA: State of Liberty
    1. Rockstar Games

    2. Rockstar Collectors

    1. Off-Topic

      1. General Chat
      2. Gaming
      3. Technology
      4. Movies & TV
      5. Music
      6. Sports
      7. Vehicles
    2. Expression

      1. Graphics / Visual Arts
      2. GFX Requests & Tutorials
      3. Writers' Discussion
      4. Debates & Discussion
    1. Announcements

    2. Support

    3. Suggestions

[CLEO] Turn On Turn Off


BiieL
 Share

Recommended Posts

Hi men, i'm new my english sucks too, i have "made" a smoke code, to when i press a Key create smoke in player, but i'm never did a cleo script but i Script PAWN, so if anyone can help me to do the "Turn on and turn off" on this smoke mod:

 

 

// 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 'SINE' [email protected] = 0.0 :SINE_21wait 0 if   Player.Defined($PLAYER_CHAR)else_jump @SINE_21 if 0AB0:   key_pressed 32 else_jump @SINE_21 02F6: [email protected] = cosine [email protected] // (float) [email protected] *= 0.0 02F7: [email protected] = sine [email protected] // (float) [email protected] *= 0.0 [email protected] *= -2.0 04C4: store_coords_to [email protected] [email protected] [email protected] from_actor $PLAYER_ACTOR with_offset [email protected] [email protected] 0.2 095C: create_smoke_at [email protected] [email protected] [email protected] velocity 0.0 0.0 0.0 RGBA 0.1 0.6 0.0 1.0 size 0.2 last_factor 0.5 095C: create_smoke_at [email protected] [email protected] [email protected] velocity 0.0 0.0 0.0 RGBA 0.0 0.0 0.9 1.0 size 0.1 last_factor 0.2 [email protected] += 0.0 if  [email protected] > 354.0 else_jump @SINE_21 [email protected] = 0.0 jump @SINE_21 

 

 

now with this script, when the player press Space create a smoke in the ass, i wanna with a key turn on and turn off, and if possible put the smoke on the foot (right or left, or two)

if anyone script cleo and Pawn explain to me like Pawn scripts

 

Thanks

 

EDIT:

 

here the preview

 

 

 

user posted image

Edited by BiieL
Link to comment
Share on other sites

 

02F6: [email protected] = cosine [email protected] // (float)[email protected] *= 0.002F7: [email protected] = sine [email protected] // (float)[email protected] *= [email protected] *= -2.0[...][email protected] += [email protected] > 354.0else_jump @[email protected] = 0.0

 

Why do you put that?

 

1. If you multiply a num with 0 you will get 0

2. [email protected] will never be 354.0

Link to comment
Share on other sites

i have taked this code from the cleo tutorials and edited the RGBA color, so i never edited Cleo so i didn't know if i could delete this part ...

Link to comment
Share on other sites

i have taked this code from the cleo tutorials and edited the RGBA color, so i never edited Cleo so i didn't know if i could delete this part ...

yes, you deleted and changed something

copy the script again from the tut

Link to comment
Share on other sites

maybe you can just attach the smoke particle to the actor?

it will make things a bit easier...though im not sure if ALL particles can be attached to it...

then you can just use

 

064C: make_particle [email protected] visible 

 

and

 

064E: stop_particle [email protected] 

 

at key press...

Link to comment
Share on other sites

hhh, is there no way to attach ANY particle to an actor?

i know SOME particles are impossible to attach to an OBJECT...so maybe there are only some particles

 

thread 'SINE' :SINE_21wait 0 if  Player.Defined($PLAYER_CHAR)else_jump @SINE_21 if 0AB0:   key_pressed 32 else_jump @SINE_21 wait 500repeatwait 004C4: store_coords_to [email protected] [email protected] [email protected] from_actor $PLAYER_ACTOR with_offset 0.2 -0.1 -3.0//no need for sine and cosine here, these are offset coords, not world coords... 04C4: store_coords_to [email protected] [email protected] [email protected] from_actor $PLAYER_ACTOR with_offset 0.2 -0.1 -3.0095C: create_smoke_at [email protected] [email protected] [email protected] velocity 0.0 0.0 0.0 RGBA 0.1 0.6 0.0 1.0 size 0.2 last_factor 0.5 095C: create_smoke_at [email protected] [email protected] [email protected] velocity 0.0 0.0 0.0 RGBA 0.0 0.0 0.9 1.0 size 0.1 last_factor 0.2 // i didnt want to change things there, but i thought you wanted it exactly like the other...right? well just change the paremeters...until 0ab0: 32wait 1000jump @SINE_21 

 

 

Link to comment
Share on other sites

There's not much relation between CLEO and PAWN, besides through SAMP... but PAWN has much less features than CLEO..

 

 

{$CLEO .cs}//-------------MAIN---------------0000::SINEwait 0   0256:   player 0 defined    // really, not needed.. but w/e...else_jump @SINE   0AB0:   key_pressed 0x20else_jump @SINE0247: load_model 3003while 8248:   not model 3003 available   wait 0end0107: [email protected] = create_object 3003 at 0.0 0.0 0.00107: [email protected] = create_object 3003 at 0.0 0.0 0.0// Edit the below "offset" values, if needed.. which will change the position of the smoke from the chars foot.070A: AS_actor $PLAYER_ACTOR attach_to_object [email protected] offset 0.0 0.0 0.0 on_bone 9 16 perform_animation "NULL" IFP_file "NULL" time 1    // right foot070A: AS_actor $PLAYER_ACTOR attach_to_object [email protected] offset 0.0 0.0 0.0 on_bone 10 16 perform_animation "NULL" IFP_file "NULL" time 1   // left foot// Deji's secret "make attached object invisible" code.. shhh!077E: get_active_interior_to [email protected]   8039:    not [email protected] == 1else_jump @Hide_20566: link_object [email protected] to_interior 10566: link_object [email protected] to_interior 1jump @FootSmoke0566: link_object [email protected] to_interior 20566: link_object [email protected] to_interior 2:FootSmokewhile 0AB0:  key_pressed 0x20   wait 0  // increase time slightly if you need less thick smoke or something..   01BB: store_object [email protected] position_to [email protected] [email protected] [email protected]   01BB: store_object [email protected] position_to [email protected] [email protected] [email protected]   095C: create_smoke_at [email protected] [email protected] [email protected] velocity 0.0 0.0 0.0 RGBA 0.1 0.6 0.0 1.0 size 0.2 last_factor 0.5 // left foot   095C: create_smoke_at [email protected] [email protected] [email protected] velocity 0.0 0.0 0.0 RGBA 0.0 0.0 0.9 1.0 size 0.1 last_factor 0.2 // right footend0682: detach_object [email protected] 0.0 0.0 0.0 collision_detection 00108: destroy_object [email protected] @SINE

 

Link to comment
Share on other sites

give a error so i have edited ... so it's compiled but it's need to stay pressing the key and it's creating only in right foot ...

look what's now !

 

{$CLEO .cs}//-------------MAIN---------------0000::SINEwait 0  0256:   player 0 defined    // really, not needed.. but w/e...else_jump @SINE  0AB0:   key_pressed 32else_jump @SINE0247: load_model 3003while 8248:   not model 3003 available  wait 0end0107: [email protected] = create_object 3003 at 0.0 0.0 0.00107: [email protected] = create_object 3003 at 0.0 0.0 0.0// Edit the below "offset" values, if needed.. which will change the position of the smoke from the chars foot.070A: AS_actor $PLAYER_ACTOR attach_to_object [email protected] offset 0.0 0.0 0.0 on_bone 9 16 perform_animation "NULL" IFP_file "NULL" time 1    // right foot070A: AS_actor $PLAYER_ACTOR attach_to_object [email protected] offset 0.0 0.0 0.0 on_bone 10 16 perform_animation "NULL" IFP_file "NULL" time 1   // left foot// Deji's secret "make attached object invisible" code.. shhh!077E: get_active_interior_to [email protected]  8039:    not [email protected] == 1else_jump @Hide_20566: link_object [email protected] to_interior 10566: link_object [email protected] to_interior 1jump @FootSmoke0566: link_object [email protected] to_interior 20566: link_object [email protected] to_interior 2:FootSmokewhile 0AB0:  key_pressed 32  wait 0  // increase time slightly if you need less thick smoke or something..  01BB: store_object [email protected] position_to [email protected] [email protected] [email protected]  01BB: store_object [email protected] position_to [email protected] [email protected] [email protected]  095C: create_smoke_at [email protected] [email protected] [email protected] velocity 0.0 0.0 0.0 RGBA 0.1 0.6 0.0 1.0 size 0.2 last_factor 0.5 // left foot  095C: create_smoke_at [email protected] [email protected] [email protected] velocity 0.0 0.0 0.0 RGBA 0.0 0.0 0.9 1.0 size 0.1 last_factor 0.2 // right footend:Hide_20682: detach_object [email protected] 0.0 0.0 0.0 collision_detection 00108: destroy_object [email protected] @SINE

 

 

i don't really like script cleo because cleo don't have "{" and "}"

 

 

men, and if is it possible:

Get the player anim and if anim is from parachute.ifp do that actions with turn on and turn off ...

Edited by BiieL
Link to comment
Share on other sites

"flag" is just another way of saying "we_dont_know_what_it_does_so_we_are_gonna_just_call_it_flag". We're trying to get rid of as many of these for the database and replace them with their proper names.

 

RGBA doesn't work for particles. on_bone isn't directly supported, but as with the code I posted above.. you can attach an object on any bone and then attach a particle to the object.

Link to comment
Share on other sites

oh, this is good, but i wanna make a smoke colorful and with turn on and off

 

i have made the smoke and on_bone, but now i wanna turn on and off

because now to see the smoke it's needed press and hold a key

 

 

but if you know if have any colorful, black, or blue-green particle like a smoke tell me

Edited by BiieL
Link to comment
Share on other sites

You can adjust the RGBA for that. If you want it red then set RGBA to 255.0 0.0 0.0 255.0

 

RGBA stands for Red, Green, Blue, Alpha.

 

Alpha is visibility/transparancy. If its 0 then you won't be able to see it. You can make the smoke thick by making Alpha higher.

 

Understood? tounge.gif

Link to comment
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • 1 User Currently Viewing
    0 members, 0 Anonymous, 1 Guest

×
×
  • Create New...

Important Information

By using GTAForums.com, you agree to our Terms of Use and Privacy Policy.