Jump to content


Photo

Changing Enemy's Action/Position | Alarm and Commando Hostage


  • Please log in to reply
6 replies to this topic

#1 Baba_1977

Baba_1977
  • Members
  • 23 posts

Posted 17 June 2024 - 10:40 AM

I have the guide which has code for making enemy lay down / crouch / move from position A to position B but where to put that codes?

 

I got that guide from commandoshq.net Mods Zips that said tutorial. I need help that where to put that code to change enemy's action. 

 

Also how to make a commando hostage? Like of alarm goes on they shot the commando or we have specific time limit to save the commando or they kill him. Just like Castle Colditz.



#2 extrano1955

extrano1955

    title available

  • Members
  • 692 posts
  • Location:Spain

Posted 23 June 2024 - 05:10 PM

For a begginer I suggest to edit actions in .MIS. You can copy the code of a walking enemy and edit coordinates. For example in DATA/MISIONES/SB/SB.MIS The .TOKEN ALEfusgordo120

 

---------------------------

Code down = walking

--------------------------- 

(
                                                    IR_A_PUNTO 
                                                    [
                                                        .MODO ANDANDO 
                                                        .XYZ 
                                                        (
                                                            -1308.0 -1660.0 0
                                                        )
                                                        .ESC EXTERIOR 
                                                    ]
                                                )
-----------------------------
code down = wait
------------------------------
                                               (
                                                    ESPERAR 
                                                    [
                                                        .TIEMPO 300.0 
                                                    ]
                                                ) 
-------------------------------
code down = rotate to180ยบ
-------------------------------
(
                                                    ENCARARSE 
                                                    [
                                                        .ANGULO 180.0
                                                    ]
                                               )
-------------------------------
 
For advanced actions is better use .gsc file I add and example down:
 
----------------------------
        [
            .NOMBRE NAME_EXAMPLE
            .MIEMBROS 
            (
SOLDIER_001
            )  
            .SCRIPTS 
            (
                [
                    .NOMBRE SOLDIER_001
                    .CRISELBI 
                    (
                        BICHO SOLDIER_001
                    )
                    .FLAGS_REACTIVIDAD 
                    (
                        REACTIVO_VER_ENEMIGOS REACTIVO_OIR_SONIDOS 
                    )
                    .SIMPLE  1.0 
                    .ORDENES 
                    (
                        ! : LOOP 
                        ! IRAPOS 
                        (
                           283,0  -1205,9  0,00 EXTERIOR
                        )NORMAL ANDANDO 
                        ! SET_ANGULO 180
                        ! ESPERAR_TIEMPO  300
                        ! IRAPOS 
                        (
                           283,0  -1205,9  0,00 EXTERIOR
                        )NORMAL ANDANDO 
                        ! SET_ANGULO 180
                        ! ESPERAR_TIEMPO  300
                        ! GOTO LOOP 
                    )
                ]
                [
                    .NOMBRE 2SOLDIER_001
                    .CRISELBI 
                    (
                        BICHO SOLDIER_001
                    )
                    .FLAGS_REACTIVIDAD 
                    (
                        REACTIVO_VER_ENEMIGOS REACTIVO_OIR_SONIDOS 
                    )
                    .SIMPLE  1.0 
                    .ORDENES 
                    (
                        ! IRAPOS 
                        (
                           283,0  -1205,9  0,00 EXTERIOR
                        )NORMAL ANDANDO 
                        ! SET_ANGULO 180
                        ! DISPARA_MATA COMANDO
                        ! ESPERAR_INFINITO
                    )
                ]
            )
            .SCRIPT_DE_GRUPO 
            [
                .ORDENES 
                (
                    ! LANZAR_SCRIPT SOLDIER_001
                    ! ESPERAR_CONDICION 
                    (
                        EVENTO ALAM
                    )
                    ! LANZAR_SCRIPT 2SOLDIER_001
                )
            ]
        ]
 
---------------------------------------
In upper example NAME_EXAMPLE is the name of this code.
soldier_001 is the name of the soldier
Inside of .SCripts .NOMBRE SOLDIER_001 must match with  ! LANZAR_SCRIPT SOLDIER_001
Inside of .MIEMBROS all soldiers name must appear.
ALAM is the name of the event of alarm.
soldier_001 will do script  SOLDIER_001. He goes to a coordinate, look at angle, wait,  goes to a coordinate, look at angle, wait, repeat.
If ALAM he does 2SOLDIER_001; Goes to coordinate, look at angle, kill comando ( Green beret )
----------------------------
If you want add different actions I suggest to search soldiers doing the action you want to add and copy from other missions. now I will add some common actions code:
 
                        ! SET_ESTADO_LOGICO ARRODILLADO = stand down ( middle position )
                        ! SET_ESTADO_LOGICO AGACHADO = stand down ( full )
                        ! : LOOP = start loop
                        ! ESPERAR_TIEMPO 200 = wait
                        ! PON_ANIMSECUENCIA FUMAR_PRINCIPIO = start smoking
                        ! PON_ANIM_COSTUMBRISTA 800.0 FUMAR_MITAD = smoking 800 time
                        ! PON_ANIMSECUENCIA FUMAR_FINAL = end smoking
                        ! PON_ANIMSECUENCIA ECHAR_CHARLA = animation moving arm
                        ! PON_ANIMSECUENCIA HABLAR_1 = speak
                        ! PON_ANIMSECUENCIA HABLAR_2 = speak
                        ! PON_ANIMSECUENCIA HABLAR_3 = speak
                        ! PON_ANIMSECUENCIA HABLAR_4 = speak
                        ! PON_ANIMSECUENCIA HABLAR_5 = speak
                        ! PON_ANIMSECUENCIA BEBER_BOTELLA  = drinking
                        ! PON_ANIMSECUENCIA TAMBALEO_BORRACHO = beeing drunk
                        ! PON_ANIM_COSTUMBRISTA 100.0 PERIODICO_A_CICLICA = reading newspaper 
                        ! PONTE_A_ESCANEAR = move triangle of vision
                        ! PON_ANIM_COSTUMBRISTA 25.0 PERIODICO_B_CICLICA = reading newspaper 
                        ! DEJA_DE_ESCANEAR  = stop moving triangle of vision
                         ! GOTO LOOP = goes to start of loop
 
-------------------------
 
To make ALAM event you must create alarm code in .MIS you have to be sure paste all code I show down ( if it dont exist )
 
            .REACTS
            (
                [
                    .ESC EXTERIOR = the name of the map
                    .ZONA EXTERIOR = the name of the zone
                    .EVENTO ALAM = the name of the event
 
                ]
            )
            .DAR_ALARMA_AL_VER_ALIADO 1 
            .ALARMAS
            [
                .LISTA_ALARMAS
                (
                    [
                        .NOMBRE ALARMA01 
                        .TIEMPO 500
                    ]
                )
            ]
Insideo of .ZONAS ( ):
                [
                    .NOMBRE EXTERIOR = name of zone
                    .LISTA_MAPZON
                    (
                        [
                            .ESC EXTERIOR = name of map
                            .ZON EXTERIOR = name of zone
                        ]
                    )
                ]
Inside of .ZONASFLOTANTES ( ):
            [
                .NOMBRE EXTERIOR = name of zone
                .ESCENARIO EXTERIOR = name of map
                .TODO_EL_ESCENARIO 1
            ]
 
---------------------
 
I think that is all. oh, and never copy = """""""" it is not the code, it is my explanation
 
 


#3 extrano1955

extrano1955

    title available

  • Members
  • 692 posts
  • Location:Spain

Posted 23 June 2024 - 05:16 PM

An important thing in .gsc file:

 

                    .FLAGS_REACTIVIDAD 
                    (
                       REACTIVO_VER_ENEMIGOS REACTIVO_OIR_SONIDOS SALIR_DEL_SITIO ATENDER_CADAVERES 
                    )
 
Delete SALIR_DEL_SITIO ATENDER_CADAVERES If you want the enemy dont move when he watch dead body, cigs or wine
 
----------------------------
 
In .mis, to make commandos prisoner:
 
Inside of                             ComporUsuario 
                            [ :
 
                                .EMPIEZA_ATADO  1.0 = tied ( cant move him, and enemies dont attack until beeing rescued )
                                .EMPIEZA_INTERACTUABLE  1.0  ( you can select the commando before beeing rescued, If 0 no )
                                .EVENTO_AL_INTERACTUAR LICM ( the name of the event after rescue him


#4 Baba_1977

Baba_1977
  • Members
  • 23 posts

Posted 24 June 2024 - 01:59 PM

I guess I am too new to this. I dont even know what id GSC files. So probably I should do normal missiones for now.



#5 extrano1955

extrano1955

    title available

  • Members
  • 692 posts
  • Location:Spain

Posted 24 June 2024 - 04:57 PM

Step by step, you didnt even manage to do normal enemies and create empty map mission. You can join here and post questions

 

https://www.facebook...652709104988971

 

I am the owner of this group, eloy riptor



#6 Baba_1977

Baba_1977
  • Members
  • 23 posts

Posted 24 June 2024 - 07:32 PM

Creating empty maps and adding enemy, patrol and animations is done. Just I need some more help and I would be able to create simple and a bit complex missions.



#7 Baba_1977

Baba_1977
  • Members
  • 23 posts

Posted 24 June 2024 - 07:32 PM

I am Sunita Jaiswal I messaged you in messanger.






1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users