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  
megachaos17

Labels? in Gta 5 .csc scripts ?

Recommended Posts

megachaos17

im looking at some mod menus and im reading a bunch of "@label" with numbers at the end... so far the only thing i know is "PushString" which gives text or in other words.. "echos" the words you want on your menu if im correct.. and not only that i see "function 20 2 3" and a lot of "i get push" and "ipush"

what are these?

Share this post


Link to post
Share on other sites
sasuke78200

Hey, actually we don't support console modding plus we can't help since we haven't set yet a syntax for the scripting.

Each compiler has his own syntax.

Share this post


Link to post
Share on other sites
byteMe420

pushing an integer onto a stack maybe?

 

i usually represents an integer and push refers to putting values onto a stack which organizes data in a first in last out fashion... just google for better explanation

 

that i is probably being used in some function being called after the push

Edited by byteMe420

Share this post


Link to post
Share on other sites
2much4u

Those are all opcodes used in scripts. Many of them are used for pushing different things onto the stack. There are a ton of them but here's the description of the few you talked about in the op.

 

  • PushString is just pushing a string onto the stack. A single PushString will not display anything onscreen, a few natives are required for that.
  • iPush is pushing an integer onto the stack. There are a few different iPush opcodes which are for how many bytes the integer takes up but they all have the same function.
  • Function is for starting a function. The three numbers after it meanings are as following:
    • Function[1] Parameter count .
    • Function[2] Frame count, frames being like local variables in high level.
    • Function[3] Unknown to me. For creation of my own scripts I always keep it at 0
  • Return comes at the end of every function even if it doesn't actually return any values. It has two numbers after it and their meanings are as following:
    • Return[1] Parameter count. Should be the same number as Function[1]
    • Return[2] Number of values to take off the stack of the function and actually return.
  • Labels are used for calling functions and jumping around in code inside of functions.

 

Like sasuke said, the names of these opcodes vary depending on what decompiler/compiler you use. However they are all pretty similar.

Edited by 2much4u

Share this post


Link to post
Share on other sites
unknown modder

The label system is used to show where to go for branching instructions(Conditional and loops mainly) They aren't specifically defined in the script container, but decompilers can work out where they are looking at where branches go to. What disassembler are you using to look at the script, each one will likely have their own way of representing opcodes

Share this post


Link to post
Share on other sites
XBLToothPik

^^^^^^^^

 

You can see these being used in an open source program like GTA IV's SCOToolBox SCO Editor.

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.