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

rollajj

Get CJ high mod help (mostly done)

Recommended Posts

rollajj

I have most of the code done (which as you can see I used a drunk-code snippet as a template from a forum post for VC)

 

:DRUNK03A4: name thread 'DRUNK'0006:  @4 =  255  \\ integer values0006:  @5 =  6  \\ integer values:DRUNK30213: @2 = create_pickup  -201 type 3 at 2247.395 -1253.71  25.440280213: @3 = create_pickup  -201 type 3 at 351.7874 2499.732  16.07424:DRUNK40001: wait  500 ms00D6: if  00214: pickup @2 picked up004D: jump if false ££DRUNK400D6: if  00215: destroy pickup  @2016A: fade  0 ()  500 ms0001: wait  1000 ms03FD: set player $PLAYER_CHAR handling responsiveness  @5052C: set player $PLAYER_CHAR drunk visuals  @4015D: set gamespeed  .75016A: fade  1 (back)  500 ms0002: jump ££DRUNK3004E: end thread

 

 

i was thinking along the lines of 0245: set_actor $PLAYER_ACTOR walk_style_to "GANG1" but it did not get CJ to have the blunt that the gangs have (there are 2 gang animations gang1 and gang2, I assume one is blunt and one is bottle, I don't know which is which). It did nothing actaully.

 

So any help in changing the animation to have the blunt would be apreciated.

 

Thanks!

Share this post


Link to post
Share on other sites
Y_Less
The animations just make them look like they are walking with a blunt, the blunt itself is part of the gang members model, not added by code.

Share this post


Link to post
Share on other sites
rollajj

so there is no way to do this w/o editing the CJ model?

 

I just keep thinking back to the VC cheat where you can make tommy smoke, but that was hardcoded so I can't really see how they did that.

 

So I guess this is impossible with the SCM?

Share this post


Link to post
Share on other sites
MrTi

I was thinkin bout making a "get high" mod myself. Heres how to make CJ hold and smoke a blunt.

 

04ED: load_animation "smoking"0247: request model #CIGAR:blunt1 00D6: if  2184ED:   NOT load animation "SMOKING"8248:   NOT   model #CIGAR available004D: jump_if_false ££blunt20001: wait  0 ms0002: jump ££blunt1:blunt204C4: create_coordinate $x $y $z from_actor $PLAYER_ACTOR offset  0.0  0.0  0.00107: $blunt = create_object #CIGAR at  $x $y $z070A: unknown_action_sequence $PLAYER_ACTOR $blunt .04  .1 -.02  5  16 "NULL" "NULL" -1 0812: unknown_action_sequence $PLAYER_ACTOR "M_SMKSTND_LOOP" "SMOKING"  4.0  1  0  0  0 -1

 

 

this line

070A: unknown_action_sequence $PLAYER_ACTOR $blunt .04  .1 -.02  5  16 "NULL" "NULL" -1 

 

makes CJ hold the blunt.

 

this line

0812: unknown_action_sequence $PLAYER_ACTOR "M_SMKSTND_LOOP" "SMOKING"  4.0  1  0  0  0 -1

 

makes CJ smoke it, but you wont be able to move.

Share this post


Link to post
Share on other sites
rollajj

oh sweet thats awesome!

 

Its halfway to what I want because it has the blunt in his hand, and when hes just standing i want him to take a hit.

 

I'm getting to where I want it with some additions, but I was wondering, how do I exit the animation loop? Like I have it set up where it takes xyz, then waits and takes it again and saves in different variables and then if the first set matches the second then it starts the animation (therefore when cj is standing still). The problem is I can't move again once the animation starts, so it just keeps looping b/c I can't show that cj is moving because I can't move! Is there a way to turn off the animation on keypress or something? Or is there an easier route to my whole objective?

 

Thanks for your help!

 

ALSO:

 

evne when it is just the blunt and no animation, I can't enter cars or hop on bikes. Why is this?

 

BTW I'm not very experienced when it comes to coding (1 semester of pascal) thats why I'm asking these questions tounge.gif .

Edited by rollajj

Share this post


Link to post
Share on other sites
MrTi

the animation loop has a timer at the end, which is the very last integer (-1)

 

0812: unknown_action_sequence $PLAYER_ACTOR "M_SMKSTND_LOOP" "SMOKING"  4.0  1  0  0  0 -1

 

-1 means it will go on forever, so if u want it to stop, set it to 5000 for 5 secs or 10000 for 10 secs etc.

 

I think because you're holding the blunt, you're not able to get in a car and drive, so to get rid of the blunt, use this

0108: destroy_object $blunt

 

Share this post


Link to post
Share on other sites
demonj0e

wow guys this seems to be coming along nicly

will he be able to like pick oen up smoke it and then chuck it away or summin

 

and will there be all drunken effects?

Share this post


Link to post
Share on other sites
rollajj

Thanks for your input.

 

Is there an identifier or something I could use that tells the SCM when the player is requesting to enter a car? Perhaps I can delete the blunt while you get in the car, but recreate it and start the smoking animation while in the car because I see the gangs smoking in the car. I wonder if the controls would still work...

 

And the smoking animation, is there a way to interupt it when the player moves? Because that would be great so you don't just stand there when your taking a hit.

 

thanks for your help!

Share this post


Link to post
Share on other sites
MrTi

 

Thanks for your input.

 

Is there an identifier or something I could use that tells the SCM when the player is requesting to enter a car? Perhaps I can delete the blunt while you get in the car, but recreate it and start the smoking animation while in the car because I see the gangs smoking in the car. I wonder if the controls would still work...

 

And the smoking animation, is there a way to interupt it when the player moves? Because that would be great so you don't just stand there when your taking a hit.

 

thanks for your help!

u can try to use the keypress opcodes

00E1:   key pressed  0  15

so when u press the button to enter the car, it will destroy the blunt.

 

00D6: if  000E1:   key pressed  0  15; enter car004D: jump_if_false ££blunt0108: destroy_object $blunt

 

 

the only way i know how to interrupt the animation, is to play the animation again or another animation, and set the timer to 0. and then use the keypress opcodes again, so if u press any of the movement buttons, it will load the other animation with 0 seconds.

heres an example

00D6: if  2100E1:   key pressed  0  0; move left/right00E1:   key pressed  0  1; move forward/back004D: jump_if_false ££blunt0812: unknown_action_sequence $PLAYER_ACTOR "M_SMKSTND_LOOP" "SMOKING"  4.0  1  0  0  0  0

 

Share this post


Link to post
Share on other sites
rollajj

ok, if you could tell me how this keypress opcode works (and maybe tell me where you learned all your opcodes) I can figure this out.

 

The blunt deletes almost instantly, so maybe the wrong key is set up or I have it implimented wrong.

 

Anyways this time I just want to know how the keypress opcode works because then I can get to work on the blunt in car, etc. (and maybe you could point me in the direction of where you learned all you know about SCM opcodes, etc. smile.gifsmile.gif )

 

thank you for your help!!!

 

EDIT: I found the database of opcodes and have read through the keypress, although it seems to be for vice. Perhaps the key numbers have changed seeing as new keys were created (y and n for conversation for example). What does the first number do?

 

Also, where can I find the index of animations so I can find the smoking in car one. I can't find it anywhere else in the scm (although I did find smk_out and smk_in, maybe when the high wears off he can toss it away ..... ). I see the gangs smoking in the car, and smoke stand had legs through the bottom, and biking jsut looks silly tounge.gif

Edited by rollajj

Share this post


Link to post
Share on other sites
ThAtSgOtTaHuRt

does anyone know the default "03FD: set player $PLAYER_CHAR handling responsiveness"

 

thanks,

TGH

 

 

*EDIT*

 

NEVERMIND - its 1.0

Edited by ThAtSgOtTaHuRt

Share this post


Link to post
Share on other sites
GangsterAngel
Do you guys know a way to get CJ to smoke and not smoke , via a ingame menu?

Share this post


Link to post
Share on other sites
Thesord
GangsterAngel, that would have to be done using a far more advanced method, such as memory editing and other functions. Edited by Thesord

Share this post


Link to post
Share on other sites
Roald
Will this make CJ smoke constantly, or by pressing a certain putting to make him start/stop smoking?

Share this post


Link to post
Share on other sites
demonj0e

For Those Of You Anxious To Try This Out But Cannot Get This Working Ive Compiled It And Edited It a Little

 

It Will Spawn Weed In Ryders Back Yard Cuz He Is a Crack Head

Walk Into The Weed To Start The Effects Im Not sure How Long It Lats To sumtimes With me Its Quick sumtimes it goes on forever Just Try It Out

 

DOWNLOAD

 

rollajj If i Wasent Allwed To Do This Just Tell me And Ill Remove It

Edited by demonj0e

Share this post


Link to post
Share on other sites
rollajj

Nah, I ripped it mostly from a drunk mod for vice so its ok tounge.gif

 

Can anyone help with my current problem: The keypress opcode for SA? It doesn't want to recognize, I think the key numbers might have switched around or something. Read my previous post for full details.

Share this post


Link to post
Share on other sites
demonj0e

rollajj could u send me ure main.scm ill have alook for ya

my msn is [email protected]

Share this post


Link to post
Share on other sites
Roald
For Those Of You Anxious To Try This Out But Cannot Get This Working Ive Compiled It And Edited It a Little

 

It Will Spawn Weed In Ryders Back Yard Cuz He Is a Crack Head

Walk Into The Weed To Start The Effects Im Not sure How Long It Lats To sumtimes With me Its Quick sumtimes it goes on forever Just Try It Out

 

DOWNLOAD

 

rollajj If i Wasent Allwed To Do This Just Tell me And Ill Remove It

I though this was supposed to make CJ smoke, all it does is make him dizzy or something. dozingoff.gif

Share this post


Link to post
Share on other sites
demonj0e

woops my bad i forget to mention it dosent makehim smoke yet

still trying to get that working

 

also theres a new version that instead of weed plants it has a cigar

im looking for a beer bottle so i can make this a drunken mod and im aslo trying to make him walk drunk i got teh code but it aint working the game dont crash it just dont work

Edited by demonj0e

Share this post


Link to post
Share on other sites
rollajj

drunken mod, thats not going to be too different from High mod because R* modded the drunk code from VC to the high code that is in SA(drunkvisuals). The only difference is there is no white overlay (there might be other differences that I didn't notice).

 

AS for my mod progress, getting VERY close because I figured out the keypress opcode, at least for what I need it for. I'm preparing for a release, and this one will have CJ with the blunt smile.gif

Share this post


Link to post
Share on other sites
demonj0e

same here im very close to getting this done i have him with the blunt now and it stays in his hand he can walk around now but he dont smoke it

im gonna try now get the kdestroy blunt when key is pressed part so he can enter cars

 

heres an image of wat i got

 

 

user posted image

 

aint there ment to be a glow aswell for the cigar?

Share this post


Link to post
Share on other sites
rollajj

I've released an initial release in the mod showroom. Thanks for all your replys and support.

Edited by rollajj

Share this post


Link to post
Share on other sites
rollajj

Does anyone happen to know the name of the model of the bottle that the gangs hold on to and perhaps have the corresponding co-ordinates for linking it to their hands? That could save me some time smile.gif

 

or even jsut naother bottle that is of appropriate size, like I have a beer bottle that fits in CJ's hands, all I need is to find the model name of the gang bottle they hold and I can release my mod! I can't find it anywhere, please help!

 

 

EDIT: FOUND!! rahkstar2.gif made a spelling mistake smile.gif

 

cj_bear_bottle

Edited by rollajj

Share this post


Link to post
Share on other sites
rollajj

Does anybody know how to make an animation for $player_actor, which allows CJ still to move? I know its possible, it's just a matter of finding out how...

Share this post


Link to post
Share on other sites
rollajj

OK scrap that, I gave up on that (unless someone knows how to make the animation go and still move).

 

Right now I need to find the animation the gangs use while in car when they smoke (its no the same as when they stand). I can't find it. If someone can just drop the name of it and what file its from and I'll take it from there. Thanks in advance!

 

 

 

EDIT: Well after much searching, it is found.

 

smoke_in_car in PED

Edited by rollajj

Share this post


Link to post
Share on other sites
skez

it doesn't work for me sad.gif

not the original and not that by Demonj0e!!

what is wrong?

Share this post


Link to post
Share on other sites
Y_Less
In what way doesn't it work? Please try be a little more descriptive.

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.


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