Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- //From my Amnesia Rebirth Tutorial Series
- //Episode 14 Enemies Pt.4! Guarding, Enthralled and Wander!
- //https://www.youtube.com/playlist?list=PL4KkjlmOwLwwMVqedCNpi6caUxhgyf8Qr
- //-----------------------------------------------------------
- //Should the ghoul smell around for the player
- Ghoul_SetSmellingActive("ghoul_hallway", false);
- //enemyName (String)- name of enemy as it appears in the level editor.
- //enable (bool)- whether or not you want to set the ghoul to smell for the player (true or false).
- /////////////////////////////////////////////
- //Guarding functions
- /////////////////////////////////////////////
- //Setup the guard mode
- Ghoul_ModeGuard_Setup("ghoul_hallway", "arabic_fort_door_exit_1", "basket_1", "", "", "", eGhoulSpeed_FastWalk);
- //enemyName (String)- name of enemy as it appears in the level editor.
- //lookAtEntity (String)- name of entity that the ghoul should look at (as it appears in your level editor).
- //standAtEntity (String)- name of the entity that the ghoul should stand at (as it appears in your level editor).
- //idleAnimation (String)- name of animation that should play when the ghoul is idle near the entity.
- //idleSound (String)- name of the sound you want to play when the ghoul is idle.
- //disturbAnimation (String)- name of the animation you want to play when the ghoul'f guarding is disturbed.
- //ghoulSpeed (eGhoulSpeed)- the speed at which the ghoul should move while guarding.
- //Set the mode to be in the guard state
- Ghoul_Mode_Set("ghoul_hallway", eGhoulMode_Guard, false);
- //ghoulName (String)- name of ghoul as it appears in your level editor.
- //ghoulMode (eGhoulMode)- the mode we want the ghoul to be in eGhoulMode_Guard for a guard state.
- //forceModeChange (bool)- should the ghoul immediately switch into the new state or should he do it at the next best opportunity.
- /////////////////////////////////////////////
- //Enthralled functions
- /////////////////////////////////////////////
- //Setup the enthralled mode
- Ghoul_ModeEnthralled_Setup("ghoul_hallway", "basket_1", "basket_1", "idle_stand");
- //ghoulName (String)- name of ghoul as it appears in your level editor.
- //lookAtEntity (String)- name of entity that the ghoul should look at (as it appears in your level editor).
- //standAtEntity (String)- name of the entity that the ghoul should stand at (as it appears in your level editor).
- //idleAnimation (String)- name of animation that should play when the ghoul is idle near the entity.
- //Set the mode to be in the guard state
- Ghoul_Mode_Set("ghoul_hallway", eGhoulMode_Enthralled false);
- //ghoulName (String)- name of ghoul as it appears in your level editor.
- //ghoulMode (eGhoulMode)- the mode we want the ghoul to be in eGhoulMode_Enthralled for a enthralled state.
- //forceModeChange (bool)- should the ghoul immediately switch into the new state or should he do it at the next best opportunity.
- /////////////////////////////////////////////
- //Random wander area functions
- //Note: you can use a vector with the
- //coordinates or specify an entities coordinates
- /////////////////////////////////////////////
- //Setup the random wander area mode...
- Ghoul_ModeRandomWanderArea_Setup("ghoul_hallway", cVector3f(15.5, 0, 1.101), 0, 5);
- //You can also use if you want to specify an entities coordinates instead
- Ghoul_ModeRandomWanderArea_Setup("ghoul_hallway", Map_GetEntity("basket_1").GetPosition(), 0, 5);
- //ghoulName (String)- name of ghoul as it appears in your level editor.
- //position3D (cVector3f)- the x,y and z coordinate vector to use. This will be the origin point that the ghoul will wander around.
- //minRadius (float)- the minimum distance from the coordinates provided that the ghoul should start wandering.
- //maxRadius (float)- the maximum distance from the coordinates provided that the ghoul should start wandering.
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement