Quantcast
Jump to content
Search In
  • More options...
Find results that contain...
Find results in...
    1. Welcome to GTAForums!

    1. Red Dead Redemption 2

      1. PC
      2. Gameplay
      3. Missions
      4. Help & Support
    2. Red Dead Online

      1. Gameplay
      2. Find Lobbies & Outlaws
      3. Help & Support
      4. Frontier Pursuits
    1. Crews & Posses

      1. Recruitment
    2. Events

    1. GTA Online

      1. Diamond Casino & Resort
      2. DLC
      3. Find Lobbies & Players
      4. Guides & Strategies
      5. Vehicles
      6. Content Creator
      7. Help & Support
    2. Grand Theft Auto Series

    3. GTA 6

    4. GTA V

      1. PC
      2. Guides & Strategies
      3. Help & Support
    5. GTA IV

      1. Episodes from Liberty City
      2. Multiplayer
      3. Guides & Strategies
      4. Help & Support
      5. GTA IV Mods
    6. GTA Chinatown Wars

    7. GTA Vice City Stories

    8. GTA Liberty City Stories

    9. GTA San Andreas

      1. Guides & Strategies
      2. Help & Support
      3. GTA SA Mods
    10. GTA Vice City

      1. Guides & Strategies
      2. Help & Support
      3. GTA VC Mods
    11. GTA III

      1. Guides & Strategies
      2. Help & Support
      3. GTA III Mods
    12. Top Down Games

      1. GTA Advance
      2. GTA 2
      3. GTA
    13. Wiki

      1. Merchandising
    1. GTA Modding

      1. GTA V
      2. GTA IV
      3. GTA III, VC & SA
      4. Tutorials
    2. Mod Showroom

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

      1. DYOM
      2. OpenIV
      3. GTA: Underground
      4. GTA: Liberty City
      5. GTA: State of Liberty
    1. Red Dead Redemption

    2. Rockstar Games

    1. Off-Topic

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

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

    2. Forum Support

    3. Site Suggestions

Sign in to follow this  
koragg

The police won't chase me after I hit them

Recommended Posts

koragg

you're right.it isn't

Share this post


Link to post
Share on other sites
Ashwin.Star

try looping this opcode

 

:0wait 001F7: $2 0 jump @0

 

it just a crazy IDEA

Share this post


Link to post
Share on other sites
koragg

didn't work.

Share this post


Link to post
Share on other sites
koragg

i have a question about a script

can i make a certain script load an .MP3 file while executing ?

Share this post


Link to post
Share on other sites
Ashwin.Star

yes you can play a existing mp3 from cleo or main Script,

Share this post


Link to post
Share on other sites
koragg

but how can i make the script play my .MP3

Share this post


Link to post
Share on other sites
Ashwin.Star

Did you try to do that or just opened your mouth & asked ?

open sandy builder & search for related words like Mp3, play, etc

& use opcode description & your common sense to use them

Share this post


Link to post
Share on other sites
koragg

in sanny builder there's an explanation about CLEO 3 but I'm using CLEO 4.

How can I do it with CLEO 4 if it's possible?

Share this post


Link to post
Share on other sites
Joni2030

These is same codes i think!

Share this post


Link to post
Share on other sites
koragg

ok/i'll try again

Share this post


Link to post
Share on other sites
Ashwin.Star

i am sure Each new Version of Cleo also contain all opcodes of Last version,

Share this post


Link to post
Share on other sites
koragg

can someone tell me what am i doing wrong here, because the mp3 file plays, but only when i start a new game and not when pressing Shift (key 16) while in a car.HEELP !!

 

// 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 'CARJUMP'

0AAC: $HMP3 = load_mp3 "CLEO\PLAYLIST\TURBOBOOST.MP3"

 

:CARJUMP_46

wait 0

if and

Player.Defined($PLAYER_CHAR)

Actor.Driving($PLAYER_ACTOR)

0AAF: [email protected] = get_mp3_length $HMP3

84C8: not actor $PLAYER_ACTOR driving_flying_vehicle

0AB0: key_pressed 16

0AAD: set_mp3 $HMP3 perform_action 1

else_jump @CARJUMP_46

if

8AB0: not key_pressed 88

else_jump @CARJUMP_174

if

8AB0: not key_pressed 67

else_jump @CARJUMP_195

[email protected] = 0.15

$2657 = 18

04F7: status_text $2657 type 1 line 1 GXT '' // global_variable

059C: enable_status_text $2657 flashing 0 // global_variable

jump @CARJUMP_216

 

:CARJUMP_174

wait 0

[email protected] = 0.45

jump @CARJUMP_418

 

:CARJUMP_195

wait 0

[email protected] = 0.75

jump @CARJUMP_418

 

:CARJUMP_216

wait 0

0087: [email protected] = [email protected] // (float)

[email protected] *= 133.3333

0090: $2657 = float [email protected] to_integer

if

Actor.Driving($PLAYER_ACTOR)

else_jump @CARJUMP_614

if

8AB0: not key_pressed 9

else_jump @CARJUMP_330

if

0AB0: key_pressed 16

else_jump @CARJUMP_387

if

0.75 > [email protected]

else_jump @CARJUMP_216

[email protected] += 0.02

jump @CARJUMP_216

 

:CARJUMP_330

wait 100

if

Actor.Driving($PLAYER_ACTOR)

else_jump @CARJUMP_614

if

0AB0: key_pressed 16

else_jump @CARJUMP_387

if

0AB0: key_pressed 9

else_jump @CARJUMP_330

jump @CARJUMP_216

 

:CARJUMP_387

wait 0

0151: remove_status_text $2657

if

8AB0: not key_pressed 82

else_jump @CARJUMP_46

jump @CARJUMP_418

 

:CARJUMP_418

wait 0

03C0: [email protected] = actor $PLAYER_ACTOR car

if or

81F3: not car [email protected] in_air

04A7: actor $PLAYER_ACTOR driving_boat

else_jump @CARJUMP_46

0407: store_coords_to [email protected] [email protected] [email protected] from_car [email protected] with_offset 0.0 0.0 [email protected]

0407: store_coords_to [email protected] [email protected] [email protected] from_car [email protected] with_offset 0.0 0.0 0.0

0063: [email protected] -= [email protected] // (float)

0063: [email protected] -= [email protected] // (float)

0063: [email protected] -= [email protected] // (float)

07D5: set_car [email protected] velocity_in_direction_XYZ [email protected] [email protected] [email protected] rotation_velocitiesXY 0.0 0.0 unk 0.0

if

04A7: actor $PLAYER_ACTOR driving_boat

else_jump @CARJUMP_46

0087: [email protected] = [email protected] // (float)

[email protected] *= 5000.0

0092: [email protected] = float [email protected] to_integer

wait [email protected]

jump @CARJUMP_46

 

:CARJUMP_614

wait 0

0151: remove_status_text $2657

jump @CARJUMP_46

 

Share this post


Link to post
Share on other sites
Joni2030

Do you have the TURBOBOOST.mp3 ?

Share this post


Link to post
Share on other sites
koragg

yes of course

Share this post


Link to post
Share on other sites
koragg

i tried it again and it plays the .mp3 file but the only problem is that it plays it while holding SHIFT and not when only pressing it once and then releasing the SHIFT button.How can I fix this (play sound only when pushed the SHIFT and then let go)

Share this post


Link to post
Share on other sites
koragg

Can anyone tell me how to make the code below :

1. set the game speed to 0.36

2. play the .MP3 file TURBOBOOST.MP3 when the specified buttons are pushed

3. set the game speed to normal (when done playing the mp3)

 

// 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 'CARJUMP'

0AAC: $HMP3 = load_mp3 "CLEO\PLAYLIST\TURBOBOOST.MP3"

 

:CARJUMP_46

wait 0

if and

Player.Defined($PLAYER_CHAR)

Actor.Driving($PLAYER_ACTOR)

84C8: not actor $PLAYER_ACTOR driving_flying_vehicle

0AAF: [email protected] = get_mp3_length $HMP3

0AB0: key_pressed 16

else_jump @CARJUMP_46

if

8AB0: not key_pressed 88

0AAD: set_mp3 $HMP3 perform_action 1

else_jump @CARJUMP_181

if

8AB0: not key_pressed 67

0AAD: set_mp3 $HMP3 perform_action 1

else_jump @CARJUMP_202

[email protected] = 0.15

$2657 = 18

04F7: status_text $2657 type 1 line 1 GXT '' // global_variable

059C: enable_status_text $2657 flashing 0 // global_variable

jump @CARJUMP_223

 

:CARJUMP_181

wait 0

[email protected] = 0.45

jump @CARJUMP_460

 

:CARJUMP_202

wait 0

[email protected] = 0.75

jump @CARJUMP_460

 

:CARJUMP_223

wait 0

0087: [email protected] = [email protected] // (float)

[email protected] *= 133.3333

0090: $2657 = float [email protected] to_integer

if

Actor.Driving($PLAYER_ACTOR)

else_jump @CARJUMP_656

if

8AB0: not key_pressed 9

0AAD: set_mp3 $HMP3 perform_action 1

else_jump @CARJUMP_351

if

0AB0: key_pressed 16

0AAD: set_mp3 $HMP3 perform_action 1

else_jump @CARJUMP_422

if

0.75 > [email protected]

else_jump @CARJUMP_223

[email protected] += 0.02

jump @CARJUMP_223

 

:CARJUMP_351

wait 100

if

Actor.Driving($PLAYER_ACTOR)

else_jump @CARJUMP_656

if

0AB0: key_pressed 16

0AAD: set_mp3 $HMP3 perform_action 1

else_jump @CARJUMP_422

if

0AB0: key_pressed 9

0AAD: set_mp3 $HMP3 perform_action 1

else_jump @CARJUMP_351

jump @CARJUMP_223

 

:CARJUMP_422

wait 0

0151: remove_status_text $2657

if

8AB0: not key_pressed 82

0AAD: set_mp3 $HMP3 perform_action 1

else_jump @CARJUMP_46

jump @CARJUMP_460

 

:CARJUMP_460

wait 0

03C0: [email protected] = actor $PLAYER_ACTOR car

if or

81F3: not car [email protected] in_air

04A7: actor $PLAYER_ACTOR driving_boat

else_jump @CARJUMP_46

0407: store_coords_to [email protected] [email protected] [email protected] from_car [email protected] with_offset 0.0 0.0 [email protected]

0407: store_coords_to [email protected] [email protected] [email protected] from_car [email protected] with_offset 0.0 0.0 0.0

0063: [email protected] -= [email protected] // (float)

0063: [email protected] -= [email protected] // (float)

0063: [email protected] -= [email protected] // (float)

07D5: set_car [email protected] velocity_in_direction_XYZ [email protected] [email protected] [email protected] rotation_velocitiesXY 0.0 0.0 unk 0.0

if

04A7: actor $PLAYER_ACTOR driving_boat

else_jump @CARJUMP_46

0087: [email protected] = [email protected] // (float)

[email protected] *= 5000.0

0092: [email protected] = float [email protected] to_integer

wait [email protected]

jump @CARJUMP_46

 

:CARJUMP_656

wait 0

0151: remove_status_text $2657

jump @CARJUMP_46

 

Share this post


Link to post
Share on other sites
Jack

These opcodes:

 

0AAF: [email protected] = get_mp3_length $HMP30AAD: set_mp3 $HMP3 perform_action 1 

are not conditional checks and you shouldn't put them in a loop.

Also avoid using global variables (with $ sign) in CLEO scrypts - for example instead of $0 use [email protected] (local variable). The other thing is that your CLEO scrypt is not ended. Use this to end your scrypt:

 

0A93: end_custom_thread

 

Here's how should I try to make this happen (it's just a quick reply):

 

{$CLEO .cs}:Start0AAC: [email protected] = load_mp3 "CLEO\PLAYLIST\TURBOBOOST.MP3" :Checkwait 0 if andPlayer.Defined($PLAYER_CHAR)0449:   actor $PLAYER_ACTOR in_a_car Actor.Driving($PLAYER_ACTOR)84C8: not actor $PLAYER_ACTOR driving_flying_vehicle 0AB0: key_pressed 16 else_jump @Check0AAF: [email protected] = get_mp3_length [email protected]: set_mp3 [email protected] perform_action 1015D: set_gamespeed 0.36:Musicwait 0if 0019:   [email protected] > 60 // integer values (for example if mp3 lenght is 61 sec then put 60)else_jump @Music0AAE: release_mp3 [email protected]: set_gamespeed 1.0jump @Start0A93: end_custom_thread

 

I didn't test this but when you enter a car and press key 16 it should play an mp3 and set a game speed to 0.36. If an mp3 is over then the speed is normal again.

I'm not sure about 0019 - maybe I should have done a float check.

Edited by JACK JONES

Share this post


Link to post
Share on other sites
koragg

it plays the mp3 when i press key 16 and it sets the speed to 0.36 but it doesn't set the speed back to normal when the mp3 is over

Share this post


Link to post
Share on other sites
Jack

Put this:

 

0021:   [email protected] > 60.0

instead of 0019.

And did you put your own mp3 lenght value - mine is 61 seconds so I put 61-1=60.

Share this post


Link to post
Share on other sites
koragg

it says : "a jump to zero offset found" and i can't compile the script sad.gif

Share this post


Link to post
Share on other sites
Jack

Try jump @Check instead of jump @Start.

Share this post


Link to post
Share on other sites
koragg

now it loads only the mp3 and does nothing else

Share this post


Link to post
Share on other sites
Bad.boy!

 

it says : "a jump to zero offset found" and i can't compile the script  sad.gif

 

 

Try jump @Check instead of jump @Start.

 

The mp3 will only be played once if you do that, add "name_thread" or "0000:" at the start.

Share this post


Link to post
Share on other sites
Ashwin.Star

@Korrag

 

 

Can anyone tell me how to make the code below :

1. set the game speed to 0.36

2. play the .MP3 file TURBOBOOST.MP3 when the specified buttons are pushed

3. set the game speed to normal (when done playing the mp3)

if you wrote some code it doesn't mean it's not a a request now

 

By the way here is your Requested Script, Hope it works

 

 

{$cleo}thread 'Ashwin'0AAC: [email protected] = load_mp3 "CLEO\PLAYLIST\TURBOBOOST.MP3":0wait 0if andActor.Driving($3)84C8: not actor $3 driving_flying_vehicle0AB0: key_pressed 16jf @00AAD: set_mp3 [email protected] perform_action 1 015D: set_gamespeed 0.36wait 500:1wait 00AB9: get_mp3 [email protected] state_to [email protected] [email protected] == 0not Actor.Driving($3)8256:   not player $PLAYER_CHAR defined 0AB0: key_pressed 8jf @10AAD: set_mp3 [email protected] perform_action 0 015D: set_gamespeed 1.0wait 500jump @0

 

 

As the Script is not tested, It may contain some small Bugs.

Fix it yourself (if any)

 

You still need to know some basics

My advise is > you should take Dutchy's Tutorial first

 

@jj

 

The other thing is that your CLEO scrypt is not ended. Use this to end your scrypt:

He wants to play that File again & again,

Its not necessary that every script should END or to put That opcode in all scripts,

 

@Error

 

it says : "a jump to zero offset found" and i can't compile the script
Sounds like its your First Cleo script

 

Try jump @Check instead of jump @Start.
What a Joke lol.gif

 

The mp3 will only be played once if you do that, add "name_thread" or "0000:" at the start.
This will work

 

In this case all you have to do is

The Next thing after {$cleo} must be an opcode instead of label or something else

Thats all

Edited by Ashwin the new boy

Share this post


Link to post
Share on other sites
Jack

 

Try jump @Check instead of jump @Start.

What a Joke lol.gif

Yeah I know - very stupid - I realise myself - thanks for not puting those facepalm images.

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Sign in to follow this  

  • 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.