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. Gameplay
      2. Missions
      3. Help & Support
    2. Red Dead Online

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

      1. Recruitment
    2. Events

    1. GTA Online

      1. Arena War
      2. After Hours
      3. Find Lobbies & Players
      4. Guides & Strategies
      5. Vehicles
      6. Content Creator
      7. Help & Support
    2. Grand Theft Auto Series

    3. GTA Next

    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 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 Mods
    10. GTA Vice City

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

      1. Guides & Strategies
      2. Help & Support
      3. GTA 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  
jemahuk1

Questions!

Recommended Posts

PatrickW

 

What is wrong with IF--JF ? It's never caused me any problems.

I guess you misread smile.gif.. There nothing wrong with if-jf. It's the most basic conditional jump.

 

But jemahuk1 used a if-jump combination, which doesn't make much sense, and Dutchy3010 responded to that:

 

BTW, if-jump isn't a good structure itself...

Share this post


Link to post
Share on other sites
james227uk
What is wrong with IF--JF ? It's never caused me any problems.

I guess you misread smile.gif.. There nothing wrong with if-jf. It's the most basic conditional jump.

 

But jemahuk1 used a if-jump combination, which doesn't make much sense, and Dutchy3010 responded to that:

 

BTW, if-jump isn't a good structure itself...

lol yeah. Thanks for the correction smile.gif

Share this post


Link to post
Share on other sites
12jango

 

actor.SetImmunities([email protected], 1, 1, 1, 1, 1)actor.EmulateFromPlayer()actor.RemoveReferences()actor.Stopped()

 

 

 

Just a few questions :

 

1. Actor.Setimmunities, I don't know what're the meaning of that 1,1,1,1,1. What're they?

 

2. EmulateFromPlayer, for what? And how to use it?

 

3. RemoveReferences, what's that?

 

4. Actor.stopped, how to use it & for what?

 

 

Thanks.

Share this post


Link to post
Share on other sites
Deji
actor.SetImmunities([email protected], 1, 1, 1, 1, 1)actor.EmulateFromPlayer()actor.RemoveReferences()actor.Stopped()

 

 

 

Just a few questions :

 

1. Actor.Setimmunities, I don't know what're the meaning of that 1,1,1,1,1. What're they?

 

2. EmulateFromPlayer, for what? And how to use it?

 

3. RemoveReferences, what's that?

 

4. Actor.stopped, how to use it & for what?

 

 

Thanks.

I don't know why people are learning the function.function() thing, or w/e it's called... But I encourage all people new to coding to use the opcodes instead!

 

 

 

actor.SetImmunities([email protected], 1, 1, 1, 1, 1)actor.EmulateFromPlayer()actor.RemoveReferences()actor.Stopped()

 

 

Is the same as...

 

 

02AB: set_actor [email protected] immunities BP 0 FP 0 EP 1 CP 1 MP 0???????01C2: remove_references_to_actor [email protected]:   actor $PLAYER_ACTOR stopped

 

 

 

The first one is what the actor is immune to.

 

BP = Bulletproof.

FP = Fireproof

EP = Can't remember... Not every-thing proof wink.gif

CP = Collision Proof

MP = Can't remember.

 

 

The second line, I don't know... I've never heard of anything to do with emulate besides from...

 

 

0974: unknown_emulate_wasted // +12 hours and clear weapons

 

 

Which basically does the same thing that would happen if you were sent to hospital.

 

 

The third line, removes the references from a character... Meaning that you can't use the character anymore and it's not taking up memory. You should always do this when finished with the actor. This particular code, unlike destroy_actor - Makes the actor start to wander around like a ped.

 

 

The fourth one checks if the actor has stopped. It's a condition.

 

 

if02A0:   actor $PLAYER_ACTOR stoppedthen0662: NOP "ACTOR IS STOPPED AND SOMETHING CAN HAPPEN BECAUSE HE ISN'T MOVING!else0662: NOP "ACTOR IS MOVING (WALKING, RUNNING) SOMETHING DIFFERENT CAN (OR CAN'T) HAPPEN.end

 

Share this post


Link to post
Share on other sites
PatrickW
2. EmulateFromPlayer, for what? And how to use it?

This is a shorthand for opcode 01F5, It's normally used only once in the beginning of the main.scm. It is used to fill the $PLAYER_ACTOR variable with a emulated version of the player $PLAYER_CHAR. After that you can't do anything sensible with it, as far as I know.

Share this post


Link to post
Share on other sites
trickstar34

@Deji

Because, a lot of modders have high level experience and prefer to use classes and objects. That is the whole reason Seemann made them. The reason they are exactly the same is because he decided to make objects for basic achievements that will be used the most and the more advanced things that don't belong in a major class as opcodes. Intelligent moves on any language designers part to use this.

 

@PatrickW

I can think of something you can use, but it will take me a while, but I have made an idea, just got to study it's exact use.

 

EDIT: Anybody got any ideas how to spawn an actor exactly the same as your CJ, but you don't control him and he is just like a usual spawned actor. I'm thinking of a way to test out what I thought of.

 

Also, anybody got the line number that it is on in the v1 script? I can't find it.

Only thing I find is this.

 

01F5: $PLAYER_ACTOR = get_player_actor $PLAYER_CHAR 

 

Edited by trickstar34

Share this post


Link to post
Share on other sites
Deji
@Deji

Because, a lot of modders have high level experience and prefer to use classes and objects. That is the whole reason Seemann made them. The reason they are exactly the same is because he decided to make objects for basic achievements that will be used the most and the more advanced things that don't belong in a major class as opcodes. Intelligent moves on any language designers part to use this.

That's the thing though... It's great and I'd use it... But there are dozens more opcodes that this doesn't support. So until this function is finished, I find it easier to have lot's of simmilar lines of code than classes and objects mixed in with opcodes and other high-level constructs mixed in with low-level ones...

 

I'd love to simply be able to use C++ style coding in it and it would still compile as opcodes, but it'd take someone ages to make a compiler to do that so I'm sticking with the thing that is fully completed.

Share this post


Link to post
Share on other sites
jemahuk1

 

05E2: AS_actor [email protected] kill_actor $PLAYER_ACTOR

 

 

This opcode surely make the actor attacks player, but why does the actor put their hands up when we aim to them, then walk away from player?

Share this post


Link to post
Share on other sites
jemahuk1
Thats something you have to look up, you have to know which world that interior is in, then the coords, you have to really research the main.scm for that, I will give my Explore Liberty City mod as an example.

 

 

select_interior 1 0860: link_actor $PLAYER_ACTOR to_interior 1 04E4: unknown_refresh_game_renderer_at -811.999 457.027 0A0B: set_rendering_origin_at_3D_coord -811.999 457.027 1356.622 angle 82.0Actor.PutAt($PLAYER_ACTOR, -811.999, 457.027, 1356.622)

 

 

0 is the regular world where you free rome.

Hey, I still confused,

link actor to interior 1---->this number shows the interior code, right?If so, how can I know the interior numbers (like pizza restaurant)

 

Share this post


Link to post
Share on other sites
ZAZ

Hey, I still confused,

link actor to interior 1---->this number shows the interior code, right?If so, how can I know the interior numbers (like pizza restaurant)

look in Sanny Builder Help: SCM Documentation: GTA SA: GTA SA Interior

Share this post


Link to post
Share on other sites
solomsolomol

OMG dude , how much of a noob can you be ? i learned scripting just from the tutorials that come with sanny builder , and then all i needed was the opcode search , so just use it and stop trolling around , you asked like 50 questions so far !

Share this post


Link to post
Share on other sites
jemahuk1

Hi, do you know how to spawn actors near the player? (So, wherever you go, they will spawn near you)

Share this post


Link to post
Share on other sites
solomsolomol
Hi, do you know how to spawn actors near the player? (So, wherever you go, they will spawn near you)

yeah of course :

 

USE THE f*ckING OPCODE SEARCH AND STOP BEING SUCH A NOOB !!

 

Share this post


Link to post
Share on other sites
james227uk
Hi, do you know how to spawn actors near the player? (So, wherever you go, they will spawn near you)

yeah of course :

 

USE THE f*ckING OPCODE SEARCH AND STOP BEING SUCH A NOOB !!

 

Well said.

Share this post


Link to post
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
Sign in to follow this  

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

×

Important Information

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