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  
Ify24

Main.scm qquestion

Recommended Posts

Ify24

So guys, I have a problem.

I wanted to make a thread in main.scm file.

So I putted a create_thread @NEW_FIRE where are other create_thread opcodes

about a 950 line.

 

And I wrote my script at the very bottom of main.scm.

here is the code, I think that everything is ok whit script:

 

 

:NEW_FIREthread 'NEW_FIRE'Model.Load(#COMET)Model.Load(#M4)Model.Load(#SEASPAR)Model.Load(#ARMY):NEW_FIRE_101wait 0 msif andModel.Available(#COMET)Model.Available(#M4)Model.Available(#SEASPAR)Model.Available(#ARMY)jf @NEW_FIRE_101Car.Create([email protected], #COMET, -277.5659, -2186.366, 28.7265)Car.Angle([email protected]) = 18.787017B: set_actor $PLAYER_ACTOR weapon 31 ammo_to 500Car.Create($ACTOR_CAR, #SEASPAR, -291.1282, -2237.6138, 29.4922)Actor.Create([email protected], Cop, #ARMY, -298.472, -2227.5327, 29.5872)01B2: give_actor [email protected] weapon 31 ammo 800 0430: put_actor [email protected] into_car $ACTOR_CAR passenger_seat 0Model.Destroy(#COMET)Model.Destroy(#M4)Model.Destroy(#SEASPAR)Model.Destroy(#ARMY)end_thread

 

 

And I started a new game and my game chraches....

Can somebody help me!

Share this post


Link to post
Share on other sites
Michael.Knight1

Use This is Coding in Your Main.SCM

 

 

000950 create_thread @NEW_FIRE_

 

 

 

:NEW_FIREthread 'NEW_FIRE'Model.Load(#COMET)Model.Load(#M4)Model.Load(#SEASPAR)Model.Load(#ARMY):NEW_FIRE_101wait 0 msif andModel.Available(#COMET)Model.Available(#M4)Model.Available(#SEASPAR)Model.Available(#ARMY)jf @NEW_FIRE_101Car.Create([email protected], #COMET, -277.5659, -2186.366, 28.7265)Car.Angle([email protected]) = 18.787017B: set_actor $PLAYER_ACTOR weapon 31 ammo_to 500Car.Create($ACTOR_CAR, #SEASPAR, -291.1282, -2237.6138, 29.4922)Actor.Create([email protected], Cop, #ARMY, -298.472, -2227.5327, 29.5872)01B2: give_actor [email protected] weapon 31 ammo 800 0430: put_actor [email protected] into_car $ACTOR_CAR passenger_seat 0Model.Destroy(#COMET)Model.Destroy(#M4)Model.Destroy(#SEASPAR)Model.Destroy(#ARMY)end_thread

 

 

 

 

Thanks biggrin.gif

Edited by Michael.Knight1

Share this post


Link to post
Share on other sites
Ify24

Ahhhh, come on. Read my post... I used that opcodes and I putted the

create_thread @NEW_FIRE

where are the rest of create_thread 's

and I putted my thread at very bottom of main.scm...

 

I did that................. And When I started my game it chrashes.

Share this post


Link to post
Share on other sites
LINK/2012

I'm not sure about it what I will say, but, there is any external script before your NEW_FIRE? If yes, try to put the NEW_FIRE at the end of some mission code or at the end of the main thread.

Share this post


Link to post
Share on other sites
Node

I don't know if this applies to all threads but maybe another thread is using the handles you're using in the "NEW_FIRE" Thread

 

Example:

 

In your created thread the car gets created on the handle "[email protected]" well maybe another thread that rockstar made is using that same handle, therefor making the game crash, Just rename it too $Mycar or something

Share this post


Link to post
Share on other sites
Michael.Knight1

Hey Man I Use Your Opcode in My Main.Scm

and My Game is Not Be Crashed

???????? confused.gif

Share this post


Link to post
Share on other sites
Ify24

Hey guys...

When I opened my compiled main.scm script,

there was now anymore my create_thread @NEW_FIRE where

other create_thread 's are

and at very bottom there wasn't my thread... Threre were just opcodes like this

 

0000: NOP

0000: NOP

0000: NOP

0000: NOP

0000: NOP

0000: NOP

0000: NOP.......

 

Anyone help !

Share this post


Link to post
Share on other sites
Bad.boy!

Try this:

 

 

:NEW_FIREthread 'NEW_FIRE':NEW_FIRE_1Model.Load(#COMET)Model.Load(#M4)Model.Load(#SEASPAR)Model.Load(#ARMY)

 

 

All scripts in the main.scm have ":xxx" after "thread 'xxx'"

Share this post


Link to post
Share on other sites
Ify24

I did that... Look at my first post....

 

Anyone help ?

 

Oh yeah, and when I compiled my main.scm after modding error appeard:

 

IMG file error ..... or something like that... Is this a problem ??

 

Please help.

Share this post


Link to post
Share on other sites
Ify24

 

Script.img is used when GTA San Andreas is running and game must be shut down.

 

http://gtag.gtagaming.com/forums/index.php...readed&pid=3362

http://gtag.gtagaming.com/forums/index.php...ds&showfile=109

With this you can compile script.img while game is running.

So did this 'chrashed' my main.scm ??

 

Ok, I installed that sanny builder patch and now its ok for IMG file, but it is stil crashing...

 

 

here is my create_thread @NEW_FIRE:

 

 

create_thread @ODDVEH create_thread @R3 create_thread @GYM create_thread @SHOOT create_thread @BLOODR create_thread @HOTR create_thread @KICKS create_thread @PSAVE1 create_thread @FLOW create_thread @HELP create_thread @COLLS create_thread @CRANES create_thread @BUY_PRO create_thread @VALET_L create_thread @ADPLANE create_thread @TRAINSL create_thread @IMPND_L create_thread @OPENUP create_thread @TRI create_thread @NEW_FIRE create_thread_wb @NONAME_2 create_thread_wb @NONAME_3 create_thread_wb @NONAME_4 create_thread_wb @NONAME_5 create_thread_wb @NONAME_6 create_thread_wb @NONAME_7 create_thread_wb @APCHECK create_thread_wb @GFINIT create_thread_wb @NONAME_8 create_thread_wb @NONAME_9 create_thread_wb @HJ create_thread_wb @CELLFON 

 

 

and this is the code at very bottom of my main.scm:

 

 

:HOTDOGV_716jump @HOTDOGV_77 end_thread [b]thread 'NEW_FIRE' Model.Load(#NRG500):NEW_FIRE_24wait 0 if   Model.Available(#NRG500)jf @NEW_FIRE_24 $MY_CAR = Car.Create(#NRG500, 2258.521, -1261.734, 23.9718)Car.Angle($MY_CAR) = 270.4507Model.Destroy(#NRG500)end_thread [/b]

 

 

I lest hotgogv part of thread for you to see that it is at very bottom of the file.

And where it says

 

thread 'NEW_FIRE'

 

before that line i wrote:

 

:NEW_FIRE

 

but after compiling it dessapeard (why?)....

 

What's wrong ?

Please help.

 

Edited by Ify24

Share this post


Link to post
Share on other sites
Frank.s

Someone already told you, stop putting your thread at the end of the main.txt, put it where other threads go.

Share this post


Link to post
Share on other sites
Ify24
Someone already told you, stop putting your thread at the end of the main.txt, put it where other threads go.

Where are other threads go, mister ?

Share this post


Link to post
Share on other sites
LINK/2012
I'm not sure about it what I will say, but, there is any external script before your NEW_FIRE? If yes, try to put the NEW_FIRE at the end of some mission code or at the end of the main thread.

Share this post


Link to post
Share on other sites
Bad.boy!

Try to put it after :TRI, and the start like this

 

 

:NEW_FIREthread 'NEW_FIRE' :NEW_FIRE_1wait 0if00EC:   actor $PLAYER_ACTOR sphere 0 near_point 2258.521 -1261.734 radius 80.0 80.0jf @NEW_FIRE_1Model.Load(#NRG500):NEW_FIRE_2wait 0if Model.Available(#NRG500)jf @NEW_FIRE_2$MY_CAR = Car.Create(#NRG500, 2258.521, -1261.734, 23.9718)Car.Angle($MY_CAR) = 270.4507Model.Destroy(#NRG500)end_thread

 

 

And you spawn the car miles away from the player, check if the player is near first.

Edited by Bad.boy!

Share this post


Link to post
Share on other sites
Ify24

Guys, I have a new problem now..

When I wanted to compile my main.scm, I got an error about that label entext_226 isn't found, and it was in external script.... After that I got a new error that label WOF wasn't found (in external script too).... Same main.scm and before I diddn't have problems whit it...

I deleted it and copied a new one (backup) and the same problem...

I didnt have this problem beofre... What should I do now ?

Share this post


Link to post
Share on other sites
Bad.boy!

I had that problem some time ago, the problem isn't wof but there is something wrong with your script.

Script works for me btw, you can also try to build it in the 1st mission instead of the bike. Or you can use mine (try to compile)

link

Share this post


Link to post
Share on other sites
Frank.s

The only way entext_226 could be missing is if you deleted entext_226.

 

Start again and paste your thread into a script that you haven't already broken.

 

Are you using a stripped complete + extern scripts main.txt?

Share this post


Link to post
Share on other sites
Ify24

@Bad.Boy, When I tryed compiled your main.scm file (I didn't edit anything, just opened the main.scm and compile) I got an error :

 

Label "ENTEX_130" not found.

 

 

I am wondering why... Does the patch for Sanny Builder (for script.img to use when gme is running) have a bug ?

 

Please Help.

Share this post


Link to post
Share on other sites
Michael.Knight1

You have not left only one solution is to put The Script To Cleo.cs

 

{$VERSION 3.1.0027}{$CLEO .cs}//-------------MAIN---------------thread 'NEW_FIRE'Model.Load(#COMET)Model.Load(#M4)Model.Load(#SEASPAR)Model.Load(#ARMY):NEW_FIRE_101wait 0 msif andModel.Available(#COMET)Model.Available(#M4)Model.Available(#SEASPAR)Model.Available(#ARMY)jf @NEW_FIRE_101Car.Create([email protected], #COMET, -277.5659, -2186.366, 28.7265)Car.Angle([email protected]) = 18.787017B: set_actor $PLAYER_ACTOR weapon 31 ammo_to 500Car.Create($ACTOR_CAR, #SEASPAR, -291.1282, -2237.6138, 29.4922)Actor.Create([email protected], Cop, #ARMY, -298.472, -2227.5327, 29.5872)01B2: give_actor [email protected] weapon 31 ammo 800 0430: put_actor [email protected] into_car $ACTOR_CAR passenger_seat 0Model.Destroy(#COMET)Model.Destroy(#M4)Model.Destroy(#SEASPAR)Model.Destroy(#ARMY)end_thread

 

 

 

Share this post


Link to post
Share on other sites
LINK/2012

Use

0A93: end_custom_thread

Instead of

end_thread

in a .cs

Share this post


Link to post
Share on other sites
Michael.Knight1
Use

0A93: end_custom_thread

Instead of

end_thread

in a .cs

oh , Yes I forgot

 

in Cleo.cs Use

 

0A93: end_custom_thread

 

 

Share this post


Link to post
Share on other sites
Bad.boy!

@Michael.Knight1 The whole point of this topic is that he wants to put it in main.scm, and don't post something just to confirm someonelse's post

@Ify24 Why do you have to compile when the game is running?

Share this post


Link to post
Share on other sites
Michael.Knight1
@Michael.Knight1 The whole point of this topic is that he wants to put it in main.scm, and don't post something just to confirm someonelse's post

@Ify24 Why do you have to compile when the game is running?

Man in I Put in My Man.Scm I do not see any problem ??

Share this post


Link to post
Share on other sites
Ify24

@Michael.Knight1 Learn english. My english is bad, but nobody can't undesrstand you, man...

 

I removed the patch for Sanny Builder and I don't compile a main.scm with game running and I still get an error about that labels aren't found... Or Sanny Builder is reading and translating something wrong and then thinks that there is a problem and show the problem, but acctually there isn't a problem........

 

I will try to re-install Sanny Builder

Share this post


Link to post
Share on other sites
fastman92
@Bad.Boy, When I tryed compiled your main.scm file (I didn't edit anything, just opened the main.scm and compile) I got an error :

 

Label "ENTEX_130" not found.

 

 

I am wondering why... Does the patch for Sanny Builder (for script.img to use when gme is running) have a bug ?

 

Please Help.

Soewhere there is reference to ENTEX_130 which doesn`t exist.

Search for @ENTEX_130

Share this post


Link to post
Share on other sites
Ify24

Guys, I got it !!! My original backup wasn't so original...

And Bad.Boy's main.scm file wasn't compiling good for me too...

 

So I downloaded another main.scm file and there wasn't an error message...

 

Yey, my main.scm is healthy and ready for modding biggrin.gif

 

Thanks everybody for help.

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  

  • 2 Users Currently Viewing
    0 members, 0 Anonymous, 2 Guests

×
×
  • Create New...

Important Information

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