• Listen to a special audio message from Bill Roper to the Hive Workshop community (Bill is a former Vice President of Blizzard Entertainment, Producer, Designer, Musician, Voice Actor) 🔗Click here to hear his message!
  • Read Evilhog's interview with Gregory Alper, the original composer of the music for WarCraft: Orcs & Humans 🔗Click here to read the full interview.

[Solved] Detecting Cinematic Mode

Status
Not open for further replies.
Level 5
Joined
Jun 12, 2016
Messages
74
Hi guys, I messed up, I made 2 maps already, going to the 3rd now and in the middle of this I decided to make a camera fixed in the hero for my campaign, it works wonders but now I have make it stop working in cinematics, so to fix every single cinematic and damn it's a lot of cinematics, I wonder if there's a way to detect if the player is in cinematic mode.
 
Last edited:
Should look roughly like this:

  • Activate Cinematic Mode
    • Events
      • Player - Player 1 (Red) types a chat message containing 1 as An exact match
    • Conditions
    • Actions
      • Cinematic - Turn cinematic mode On for (All players)
      • Set CinematicMode = True
  • Deactivate Cinematic Mode
    • Events
      • Player - Player 1 (Red) types a chat message containing 2 as An exact match
    • Conditions
    • Actions
      • Cinematic - Turn cinematic mode Off for (All players)
      • Set CinematicMode = False

  • Check For Cinematic Mode
    • Events
      • Time - Every 0.00 seconds of game time
    • Conditions
      • CinematicMode Equal to True
    • Actions
      • Trigger - Run (This trigger) (ignoring conditions)


Don't use this exact trigger as it will crash the game when you activate cinematic mode, but there you see the required settings to detect if a player is in cinematic mode or not.
 
Level 5
Joined
Jun 12, 2016
Messages
74
I know guys, that is the hard way, the thing is I have almost 20 quests in the map 2, each have a 'replay cinematic' button that's a shorter cinematic, each have almost like 2~4 steps of cinematics and there are dialogs that sends to different cinematics, and there are the main story cinematics... I'm afraid I'm gonna mess up if I gonna have to look into almost 100 cinematics and set 2 boolean variables one at the start one at the end to every single one individualy. I wish it had a way to detect it automaticaly.

I guess I was lucky to only worry about the map 2 bcs map 1 is introduction map and I did just like you guys said, and map3 is in it's beggining.
 
Last edited:
Level 45
Joined
Feb 27, 2007
Messages
5,578
Use a vJASS hook to set it automatically then. Depending on which GUI function you use it will be CinematicModeBJ() or CinematicModeExBJ(). You will still have to create the boolean variable InCinematic in the variable editor.

JASS:
library TrackCinematic
function CineFlag takes boolean flag, force who returns nothing
  set udg_InCinematic = flag
endfunction

function CineFlagEx takes boolean flag, force who, real dur returns nothing
  set udg_InCinematic = flag
endfunction

hook CinematicModeBJ CineFlag
hook CinematicModeExBJ CineFlagEx
endlibrary

Not sure how this interacts with players pressing esc to skip a cinematic. You will have to test that.
 
Last edited:
Level 5
Joined
Jun 12, 2016
Messages
74
Use a vJASS hook to set it automatically then. Depending on which GUI function you use it will be CinematicModeBJ() or CinematicModeExBJ(). You will still have to create the boolean variable InCinematic in the variable editor.

JASS:
function CineFlag takes boolean flag, force who
  set udg_InCinematic = flag
endfunction

function CineFlagEx takes boolean flag, force who, real dur
  set udg_InCinematic = flag
endfunction

hook CinematicModeBJ CineFlag
hook CinematicModeExBJ CineFlagEx

Not sure how this interacts with players pressing esc to skip a cinematic. You will have to test that.

Hmm, how do you do that, exacly? I don't know vJass and I have a boolean variable "Cinematic_On".

Will it detect each time I use "Cinematic mode On/Off" action and put it on that boolean variable?
 
Status
Not open for further replies.
Top