rollajj 0 Posted June 27, 2005 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! Quote Share this post Link to post Share on other sites
Y_Less 1 Posted June 27, 2005 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. Quote Share this post Link to post Share on other sites
rollajj 0 Posted June 27, 2005 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? Quote Share this post Link to post Share on other sites
MrTi 0 Posted June 27, 2005 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. Quote Share this post Link to post Share on other sites
rollajj 0 Posted June 28, 2005 (edited) 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 . Edited June 28, 2005 by rollajj Quote Share this post Link to post Share on other sites
MrTi 0 Posted June 28, 2005 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 Quote Share this post Link to post Share on other sites
demonj0e 0 Posted June 28, 2005 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? Quote Share this post Link to post Share on other sites
rollajj 0 Posted June 28, 2005 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! Quote Share this post Link to post Share on other sites
MrTi 0 Posted June 29, 2005 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 Quote Share this post Link to post Share on other sites
rollajj 0 Posted June 30, 2005 (edited) 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. ) 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 Edited June 30, 2005 by rollajj Quote Share this post Link to post Share on other sites
ThAtSgOtTaHuRt 0 Posted June 30, 2005 (edited) does anyone know the default "03FD: set player $PLAYER_CHAR handling responsiveness" thanks, TGH *EDIT* NEVERMIND - its 1.0 Edited June 30, 2005 by ThAtSgOtTaHuRt Quote Share this post Link to post Share on other sites
GangsterAngel 0 Posted June 30, 2005 Do you guys know a way to get CJ to smoke and not smoke , via a ingame menu? Quote Share this post Link to post Share on other sites
Thesord 0 Posted June 30, 2005 (edited) GangsterAngel, that would have to be done using a far more advanced method, such as memory editing and other functions. Edited June 30, 2005 by Thesord Quote Share this post Link to post Share on other sites
Roald 1 Posted July 1, 2005 Will this make CJ smoke constantly, or by pressing a certain putting to make him start/stop smoking? Quote Share this post Link to post Share on other sites
demonj0e 0 Posted July 1, 2005 (edited) 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 July 1, 2005 by demonj0e Quote Share this post Link to post Share on other sites
rollajj 0 Posted July 1, 2005 Nah, I ripped it mostly from a drunk mod for vice so its ok 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. Quote Share this post Link to post Share on other sites
demonj0e 0 Posted July 2, 2005 rollajj could u send me ure main.scm ill have alook for ya my msn is [email protected] Quote Share this post Link to post Share on other sites
Roald 1 Posted July 2, 2005 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. Quote Share this post Link to post Share on other sites
demonj0e 0 Posted July 2, 2005 (edited) 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 July 2, 2005 by demonj0e Quote Share this post Link to post Share on other sites
rollajj 0 Posted July 2, 2005 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 Quote Share this post Link to post Share on other sites
demonj0e 0 Posted July 3, 2005 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 aint there ment to be a glow aswell for the cigar? Quote Share this post Link to post Share on other sites
rollajj 0 Posted July 3, 2005 (edited) I've released an initial release in the mod showroom. Thanks for all your replys and support. Edited July 3, 2005 by rollajj Quote Share this post Link to post Share on other sites
rollajj 0 Posted July 5, 2005 (edited) 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 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!! made a spelling mistake cj_bear_bottle Edited July 6, 2005 by rollajj Quote Share this post Link to post Share on other sites
rollajj 0 Posted July 8, 2005 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... Quote Share this post Link to post Share on other sites
rollajj 0 Posted July 9, 2005 (edited) 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 July 9, 2005 by rollajj Quote Share this post Link to post Share on other sites
skez 0 Posted July 13, 2005 it doesn't work for me not the original and not that by Demonj0e!! what is wrong? Quote Share this post Link to post Share on other sites
Y_Less 1 Posted July 15, 2005 In what way doesn't it work? Please try be a little more descriptive. Quote Share this post Link to post Share on other sites