harsh luthra Posted November 20, 2012 Share Posted November 20, 2012 hey friends iam new to codding i want a tutorial in which i know how to create an intro {when game starts in main.scm iwant to make an intro in cleo mod at startup like in orignal game can anyone help me zaz is a god of scrippting can god of scriptting {zaz} can help me Link to comment Share on other sites More sharing options...
ZAZ Posted November 20, 2012 Share Posted November 20, 2012 hey friends iam new to codding i want a tutorial in which i know how to create an intro {when game starts in main.scm iwant to make an intro in cleo mod at startup like in orignal game can anyone help me zaz is a god of scrippting can god of scriptting {zaz} can help me If a Cleo intro showed be shown at New Game Start needs to modify the main.scm to disable the originaly intro or use a stripped main Then learn to write a scripted cutscene. If you don't have any knowledge in mission coding, then go HERE and learn first writing simple scripts. The basic method for scripted cutscenes or Intro: fade in load, create and arrange stuff enable widescreen set camera fade out try the simple example below press backspace to show player with mobile phone {$CLEO .cs}:CUTSCENE_Template03A4: name_thread 'CUTSCEN':CUTSCEN_11wait 0 if 0256: player $PLAYER_CHAR defined jf @CUTSCEN_11if0AB0: key_pressed 8 // press Backspacejf @CUTSCEN_110247: load_model #CELLPHONE:CUTSCEN_13wait 0if0248: model #CELLPHONE availablejf @CUTSCEN_1301B4: set_player $PLAYER_CHAR can_move 0 fade 0 1000wait 10000729: AS_actor $PLAYER_ACTOR hold_cellphone 1067C: put_camera_on_actor $PLAYER_ACTOR with_offset 0.0 1.5 0.6 rotation 0.0 0.2 0.6 0.0 2 02A3: enable_widescreen 1wait 250 fade 1 [email protected] = 0 // reset timer:CUTSCEN_25wait 0 if 0256: player $PLAYER_CHAR defined jf @CUTSCEN_25 if [email protected] > 5000// check timer if 5 seconds are passed 00E1: player 0 pressed_key 1400E1: player 0 pressed_key 1500E1: player 0 pressed_key 1700E1: player 0 pressed_key 6 jf @CUTSCEN_25jump @CUTSCEN_cleanup :CUTSCEN_cleanup0729: AS_actor $PLAYER_ACTOR hold_cellphone 0fade 0 500wait 50002A3: enable_widescreen 0 fade 1 1500 0373: set_camera_directly_behind_player02EB: restore_camera_with_jumpcut01B4: set_player $PLAYER_CHAR can_move 1jump @CUTSCEN_11 the variable [email protected] and [email protected] are reserved as internal timer try the little script below to understand press Backspace to reset timer {$CLEO .cs}thread 'timer'while truewait 003F0: enable_text_draw 1 045A: draw_text_1number 300.0 200.0 GXT 'NUMBER' number [email protected] // ~1~ if 0AB0: key_pressed 8 // press Backspace then [email protected] = 0 endend Example for a cutscene with talking actor Go into red marker in Grovestreet {$CLEO .cs}:CUTSCENE_Template03A4: name_thread 'CUTSCEN'[email protected] = 0:CUTSCEN_11wait 0 if 0256: player $PLAYER_CHAR defined jf @[email protected] == 0// check for a var to let the cutscene only run for one timejf @CUTSCEN_11if00FE: actor $PLAYER_ACTOR sphere 1 in_sphere 2480.134 -1665.475 13.3348 radius 3.5 3.5 5.5jf @CUTSCEN_1100BA: show_text_styled GXT 'LG_37' time 1000 style 2023C: load_special_actor 'TRUTH' as 1 // models 290-299 04ED: load_animation "GHANDS" :CUTSCEN_12wait 0 if and023D: special_actor 1 loaded 04EE: animation "GHANDS" loaded004D: jump_if_false @CUTSCEN_12 0247: load_model #spraycan:CUTSCEN_13wait 0if0248: model #spraycan availablejf @CUTSCEN_1301B4: set_player $PLAYER_CHAR can_move 0 fade 0 1000wait 1000009A: [email protected] = create_actor_pedtype 24 model #SPECIAL01 at 2477.5356 -1663.0228 13.3359060B: set_actor [email protected] decision_maker_to 3201B2: give_actor [email protected] weapon 41 ammo 9000 // Load the weapon model before using this02E2: set_actor [email protected] weapon_accuracy_to 1000639: AS_actor [email protected] rotate_to_actor $PLAYER_ACTOR 067C: put_camera_on_actor [email protected] with_offset 0.0 1.5 0.6 rotation 0.0 0.2 0.6 0.0 2 02A3: enable_widescreen 1wait 1500 fade 1 1500054C: use_GXT_table 'GARAGE1'[email protected] = 0 // reset [email protected] = 1:CUTSCEN_25wait 0 if 0256: player $PLAYER_CHAR defined jf @CUTSCEN_cleanup if [email protected] > 10000// check timer if 10 seconds are passed 00E1: player 0 pressed_key 1400E1: player 0 pressed_key 1500E1: player 0 pressed_key 1700E1: player 0 pressed_key 6 jf @CUTSCEN_31jump @CUTSCEN_cleanup :[email protected] == 1jf @CUTSCEN_330812: AS_actor [email protected] perform_animation "gsign1" IFP_file "GHANDS" 8.0 loopA 0 lockX 0 lockY 0 lockF 0 time -1 // versionB [email protected] = 16484gosub @CUTSCEN_dialoque_sound_SUB0967: actor [email protected] move_mouth_for 2000 ms00BC: show_text_highpriority GXT 'GAR1_NE' time 5000 flag [email protected] = 0 // reset [email protected] = 2jump @CUTSCEN_25:CUTSCEN_33if [email protected] == [email protected] > 3000jf @CUTSCEN_350812: AS_actor [email protected] perform_animation "IDLE_chat" IFP_file "ped" 8.0 loopA 0 lockX 0 lockY 0 lockF 0 time -1 // versionB [email protected] = 16486gosub @CUTSCEN_dialoque_sound_SUB0967: actor [email protected] move_mouth_for 3000 ms00BC: show_text_highpriority GXT 'GAR1_NG' time 5000 flag [email protected] = 0 // reset [email protected] = 3jump @CUTSCEN_25:CUTSCEN_35if [email protected] == [email protected] > 3000jf @CUTSCEN_370812: AS_actor [email protected] perform_animation "gsign1" IFP_file "GHANDS" 8.0 loopA 0 lockX 0 lockY 0 lockF 0 time -1 // versionB [email protected] = 16487gosub @CUTSCEN_dialoque_sound_SUB0967: actor [email protected] move_mouth_for 5000 ms00BC: show_text_highpriority GXT 'GAR1_NH' time 5000 flag [email protected] = 0 // reset [email protected] = 4jump @CUTSCEN_25:CUTSCEN_37if [email protected] == [email protected] > 5000jf @CUTSCEN_3904C4: create_coordinate [email protected] [email protected] [email protected] from_actor $PLAYER_ACTOR offset 0.0 0.0 0.90668: AS_actor [email protected] rotate_and_shoot_at [email protected] [email protected] [email protected] 1000 ms [email protected] = 0 // reset [email protected] = 5jump @CUTSCEN_25:CUTSCEN_39if [email protected] == [email protected] > 1000jf @CUTSCEN_25 [email protected] = 6jump @CUTSCEN_cleanup:CUTSCEN_cleanupfade 0 1000wait 100004EF: release_animation "GHANDS"02A3: enable_widescreen 0 0373: set_camera_directly_behind_player02EB: restore_camera_with_jumpcut009B: destroy_actor [email protected] 1 200001B4: set_player $PLAYER_CHAR can_move 1jump @CUTSCEN_11:CUTSCEN_dialoque_sound_SUB040D: unload_wav 103CF: load_wav [email protected] as 1:CUTSCEN_dialoque_sound_1wait 0if 03D0: wav 1 loadedjf @CUTSCEN_dialoque_sound_1 0949: link_wav 1 to_actor [email protected]: play_wav 1return Subdivide the main loop into sequences 1. check for a var value 2. check for timer value read the comments :CUTSCEN_25wait 0 if 0256: player $PLAYER_CHAR defined jf @CUTSCEN_cleanup :CUTSCEN_31// sequence [email protected] == 1 // check for var value of [email protected] to let the code pass to read the sequence codesjf @CUTSCEN_330812: AS_actor [email protected] perform_animation "gsign1" IFP_file "GHANDS" 8.0 loopA 0 lockX 0 lockY 0 lockF 0 time -1 // versionB [email protected] = 16484gosub @CUTSCEN_dialoque_sound_SUB0967: actor [email protected] move_mouth_for 2000 ms00BC: show_text_highpriority GXT 'GAR1_NE' time 5000 flag [email protected] = 0 // reset [email protected] = 2 // change var valuejump @CUTSCEN_25:CUTSCEN_33// sequence 2if [email protected] == 2 // check for var value of [email protected] to let the code pass to read the sequence [email protected] > 3000 // ckeck if 3 seconds are passed, since the previous sequence has been startedjf @CUTSCEN_350812: AS_actor [email protected] perform_animation "IDLE_chat" IFP_file "ped" 8.0 loopA 0 lockX 0 lockY 0 lockF 0 time -1 // versionB [email protected] = 16486gosub @CUTSCEN_dialoque_sound_SUB0967: actor [email protected] move_mouth_for 3000 ms00BC: show_text_highpriority GXT 'GAR1_NG' time 5000 flag [email protected] = 0 // reset [email protected] = 3 // change var valuejump @CUTSCEN_25:CUTSCEN_35// sequence 3if [email protected] == 3 // check for var value of [email protected] to let the code pass to read the sequence [email protected] > 3000 // ckeck if 3 seconds are passed, since the previous sequence has been startedjf @CUTSCEN_370812: AS_actor [email protected] perform_animation "gsign1" IFP_file "GHANDS" 8.0 loopA 0 lockX 0 lockY 0 lockF 0 time -1 // versionB [email protected] = 16487gosub @CUTSCEN_dialoque_sound_SUB0967: actor [email protected] move_mouth_for 5000 ms00BC: show_text_highpriority GXT 'GAR1_NH' time 5000 flag [email protected] = 0 // reset [email protected] = 4 // change var valuejump @CUTSCEN_25:CUTSCEN_37// sequence 4if [email protected] == 4 // check for var value of [email protected] to let the code pass to read the sequence [email protected] > 5000 // ckeck if 5 seconds are passed, since the previous sequence has been startedjf @CUTSCEN_3904C4: create_coordinate [email protected] [email protected] [email protected] from_actor $PLAYER_ACTOR offset 0.0 0.0 0.90668: AS_actor [email protected] rotate_and_shoot_at [email protected] [email protected] [email protected] 1000 ms [email protected] = 0 // reset [email protected] = 5 // change var valuejump @CUTSCEN_25:CUTSCEN_39// sequence 5if [email protected] == 5 // check for var value of [email protected] to let the code pass to read the sequence [email protected] > 1000 // ckeck if 1 seconds are passed, since the previous sequence has been startedjf @CUTSCEN_25 [email protected] = 6 // change var valuejump @CUTSCEN_cleanup CLEO MODS CLEO Script Tutorial Link to comment Share on other sites More sharing options...
harsh luthra Posted November 21, 2012 Author Share Posted November 21, 2012 EXACTLY I USE THE STRIPPED MAIN MADE BY ZAZ I AM TRYING TO MAKE PROTOTYPE PC GAME INTRO IN SA CAN YOU HELP ME I NOT KNOW MUCH ABOT CODDING IAM STARTED LEARNING PLESE CAN YOU HELP ME IN MAKING INTRO Link to comment Share on other sites More sharing options...
Node Posted November 21, 2012 Share Posted November 21, 2012 EXACTLY I USE THE STRIPPED MAIN MADE BY ZAZ I AM TRYING TO MAKE PROTOTYPE PC GAME INTRO IN SA CAN YOU HELP ME I NOT KNOW MUCH ABOT CODDING IAM STARTED LEARNING PLESE CAN YOU HELP ME IN MAKING INTRO ZAZ has already provided the information you need to start making cutscenes. If you carefully read the information given and use some common sense you can adapt this to your liking. Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now