lroumen Posted July 28, 2010 Share Posted July 28, 2010 I am trying to move the party to a new area through a cutscene (shamelessly copied from the pocket plane cutscene), but it does not seem to go very well. I set the Global LRTEST to 1 (via item spell) and wait until the cutscene ends. - LRTEST is changed to 2 correctly - Cutscene starts - Controls are gone - Fade out works - Fade in works - and here I find out that the changing of the area did not work. Trying a vanilla area does not work either. It is probably something elementary, but at the moment I cannot seem to spot my error. Thanks in advance. IF Global("LRTEST","GLOBAL",1) THEN RESPONSE #100 SetGlobal("LRTEST","GLOBAL",2) ClearAllActions() StartCutSceneMode() CutSceneId(Player1) Wait(3) FadeToColor([40.0],0) Wait(2) LeaveAreaLUAPanic("LRTEST","",[60.60],1) LeaveAreaLUA("LRTEST","",[60.60],1) ActionOverride(Player2,LeaveAreaLUA("LRTEST","",[60.80],1)) ActionOverride(Player3,LeaveAreaLUA("LRTEST","",[80.60],1)) ActionOverride(Player4,LeaveAreaLUA("LRTEST","",[80.80],1)) ActionOverride(Player5,LeaveAreaLUA("LRTEST","",[100.60],1)) ActionOverride(Player6,LeaveAreaLUA("LRTEST","",[100.80],1)) Wait(1) FadeFromColor([40.0],0) EndCutSceneMode() END Link to comment
Avenger Posted July 28, 2010 Share Posted July 28, 2010 Hmm, i didn't know you can merge a cutscene and regular script code. (most likely you cannot) IIRC, the pocketplane code is pure cutscene. Cutscene code: if true() then response #100 cutsceneid(player1) ... .. end Link to comment
lroumen Posted July 28, 2010 Author Share Posted July 28, 2010 I assumed that I could. Maybe I was thinking too opportunistic. I figured that True() or Global() were just regular script checks, so why would they behave differently? In theory, the global I set is even a True() if you go with an hasvalue() type of interpretation. Or could it be that StartCutSceneMode() needs to be run in separate scripts? Edit: But that makes little sense since the other parts of the cutscene do work (fading, losing contol the menu, etc). I guess I could disconnect the cutscene from the block and make it a separate script and then call the cutscene from a block with the global check. Kind of messy if it is not possible to do it in one go. Link to comment
Avenger Posted July 28, 2010 Share Posted July 28, 2010 I think the main problem with your approach is: Cutscene ID must be the first action in the block. You just need to cut your script into two: After StartCutSceneMode(), do a StartCutScene("mycut") In MyCut you add the rest (according to the cutscene rules). You can also forget the cutscene business, and do this in regular script. Don't forget to move player1 Link to comment
lroumen Posted July 28, 2010 Author Share Posted July 28, 2010 Thanks for the tip. Actually, I tried it in a regular script first, but I couldn't get the LeaveAreaLUA to work. That's when I started to look into the cutscene I remembered from the pocket plane ability. (I first looked into the switch area effect first which pointed me to the cutscene cut250a?, anyway...). I'm starting to think that the LeaveAreaLUA action is only possible on the object when the CutSceneId has been correctly defined (as you mentioned, the first action in the block). For NPCs you would just use EscapeArea, set a global and based on the value create the NPC in another area/point anyway. I'm not sure if those thoughts are correct though. It would be nice if this requirement for the CutSceneId was added to the iesdp. Link to comment
Avenger Posted July 28, 2010 Share Posted July 28, 2010 Actually, it is already mentioned in the IESDP forum (just igi didn't port it to IESDP site): http://forums.gibberlings3.net/index.php?s...mp;#entry154115 Link to comment
lroumen Posted July 28, 2010 Author Share Posted July 28, 2010 I stand corrected. I use the site rather than the forum, so I missed that. Link to comment
devSin Posted July 28, 2010 Share Posted July 28, 2010 All nonsense. It will work fine if this is from an area script or whatever. ActionOverride(Player1) the first two LeaveArea() calls, and have Player1 also perform the final three calls (this area script may still be running after transitioning, but no need to risk it). IF Global("LRTEST","GLOBAL",1) THEN RESPONSE #100 SetGlobal("LRTEST","GLOBAL",2) ClearAllActions() StartCutSceneMode() // CutSceneId(Player1) this is garbage outside a true cutscene script Wait(3) FadeToColor([40.0],0) Wait(2) ActionOverride(Player1,LeaveAreaLUAPanic("LRTEST","",[60.60],1)) ActionOverride(Player1,LeaveAreaLUA("LRTEST","",[60.60],1)) ActionOverride(Player2,LeaveAreaLUA("LRTEST","",[60.80],1)) ActionOverride(Player3,LeaveAreaLUA("LRTEST","",[80.60],1)) ActionOverride(Player4,LeaveAreaLUA("LRTEST","",[80.80],1)) ActionOverride(Player5,LeaveAreaLUA("LRTEST","",[100.60],1)) ActionOverride(Player6,LeaveAreaLUA("LRTEST","",[100.80],1)) // Now that we're in a new area, we may not still be running // So just add to protagonist's queue ActionOverride(Player1,Wait(1)) ActionOverride(Player1,FadeFromColor([40.0],0)) ActionOverride(Player1,EndCutSceneMode()) END should work. Link to comment
lroumen Posted July 29, 2010 Author Share Posted July 29, 2010 Indeed, this did the trick as well. I also got it to work if I made the separate cutscene file. So what would be the determining factor here? If you use CutSceneId, you need to have it as the first action in a separate cutscene script, but if you don't define it you can use CutSceneMode in any script? Link to comment
Avenger Posted July 29, 2010 Share Posted July 29, 2010 Cutscenes simply spare the ActionOverride stuff. I think the full cutscene mechanism is written in that thread i linked previously. In your first script (it was not running as Player1), thus no LeaveArea targeted Player1. You needed to specify Player1 either by a cutsceneID or an ActionOverride. DevSin: yeah, all nonsense. Maybe next time say something like: 'This is fine, but you can actually do this without a cutscene script'. Link to comment
lroumen Posted July 29, 2010 Author Share Posted July 29, 2010 Sure, the thread does explain the details but in layman terms it is not competely obvious what action you should take, hence my question as a way to reassure myself that I understood what was going on. I actually had CutSceneId(Player1) defined, but since I did not know that it would not do anything, Player1 was not teleported (I actually even tried with the action override by the way and that still did nothing). Since I did not know that CutSceneId(X) should be first action, I could not find out what was going wrong. Link to comment
devSin Posted July 29, 2010 Share Posted July 29, 2010 Maybe next time say something like: 'This is fine, but you can actually do this without a cutscene script'.Are you saying I was too abrupt, or did you read the first post as being a cutscene script (the way I read it, it didn't appear to be a dedicated cutscene script at all, which is why I simply pointed out that it was fine save the missing ActionOverride()s for Player1 and for the small enhancement to ensure the trailing actions don't get dropped)? I.e., my response was that you don't have to jump through a bunch of hoops or follow Taimon's discussion of the exact function (or non-function as it were) of the CutsceneID() action in StartCutscene() scripts (pretty much all nonsense for somebody who just wants to write their mod): the original script is fine except for A and B. Link to comment
Recommended Posts
Archived
This topic is now archived and is closed to further replies.