how to "Face(X)" the PC, if I do not know where he should look at |
The Black Wyrm's Lair Terms of Use | Help Search Members Calendar |
how to "Face(X)" the PC, if I do not know where he should look at |
May 21 2005, 12:08 AM
Post
#1
|
|
Forum Member Posts: 1366 Joined: 22-August 04 From: Germany |
Hi,
I have the following problem: If an NPC initiates dialogue with the PC, she will turn to him after the talk is finished. If I start a cutscene out of this dialogue, where the NPC cures her wounds for example while saying some nice things, he is doing this while she is turning her back on him - if he approached from the wrong side for the talk. For coding I neither know in which area this talk appears nor where NPC and PC are facing at that moment. Question: Is it possible to do "MoveToPoint" and "Face" in a way relative to the PC's position? If yes, how would it be coded? Does anyone have another idea as to how this problem could be solved? (It really looks stupid if the NPC is talking to the PC's back...) Thanks! |
|
|
May 21 2005, 12:17 AM
Post
#2
|
|
GOD Retired team member Posts: 1728 Joined: 14-July 04 From: Ireland |
If you are doing a cutscene you can have people approach from whichever direction you want!
So the person starting the dialog approaches from the North and the person listening Faces North...problem solved! MovetoPoint(whatever) Face (Whatever)...person being spoken too Face(whatever direction speaker is facing oppposite)! |
|
|
May 21 2005, 12:43 AM
Post
#3
|
|
Forum Member Posts: 1366 Joined: 22-August 04 From: Germany |
But if I do not know where the persons are standing when the cutscene starts? Maybe the person approaching comes from South... Which I do not know? And I can't give coordinates either, as I do not know in which area it will take place?
Maybe I did not understand what you where saying? |
|
|
May 21 2005, 03:52 AM
Post
#4
|
|
Forum Member Posts: 53 Joined: 22-March 05 |
FaceObject(O:Object)
|
|
|
May 21 2005, 08:07 AM
Post
#5
|
|
Forum Member Posts: 1366 Joined: 22-August 04 From: Germany |
Sometimes the answer is so simple! Thank you, devSin, cutscene looks great now.
|
|
|
May 21 2005, 12:34 PM
Post
#6
|
|
GOD Retired team member Posts: 1728 Joined: 14-July 04 From: Ireland |
Apart from FaceObject (which is a lot better than just Face) my point was that if you have a character in a cutscene there is never a stage when you have no control. As the author of the cutscene you can create characters wherever you wish and have them movetopoint, face etc any place or direction you wish.
In what circumstance would you not know from which direction someone would come? Unless you were using CreateCreatureOffscreen (or whatever the correct format of this command is). However you would still be able to control where this creature moves to and which way they face, no? Anyway, yes FaceObject() is so much better. |
|
|
May 21 2005, 12:50 PM
Post
#7
|
|
Forum Member Posts: 1366 Joined: 22-August 04 From: Germany |
In this case it was a cutscene between the PC and an already in party NPC, so I do not have control as to where I could spawn them etc.
FaceObject is perfect in that case. |
|
|
Feb 27 2008, 08:33 PM
Post
#8
|
|
Forum Member Posts: 1366 Joined: 22-August 04 From: Germany |
|
|
|
Feb 27 2008, 10:48 PM
Post
#9
|
|
Forum Member Posts: 53 Joined: 22-March 05 |
If you don't know where the PC is going to be, you could always do something stupid like have your NPC ReallyForceSpell(Player1,FAKE_SPELL_DOES_NOTHING) Wait(1) StartDialog("DLG",Player1). Spellcasting should have the character zip around to face the target (you have to create the fake spell, though). (There are probably other actions that cause the actor to face the target without causing stupid feedback, but I can't come up with any off hand and don't want to look at BG IDS files right now, sorry.)
|
|
|
Feb 28 2008, 07:10 AM
Post
#10
|
|
Forum Member Posts: 1366 Joined: 22-August 04 From: Germany |
That's a good idea, thank you! If you happen to see something that leads to a facing of the "target" without a visible action I would be grateful if you'd let me know. (I also take numbers. )
|
|
|
Feb 28 2008, 07:28 AM
Post
#11
|
|
Forum Member Posts: 112 Joined: 8-September 05 From: Moscow, Russia |
FaceObject would be the solution, but another one is the solution we implement in RE:
CODE ActionOverride("ppsaem3",MoveBetweenAreas("ARRE01",[472.307],3)) LeaveAreaLUAPanic("ARRE01","",[440.323],10) LeaveAreaLUA("ARRE01","",[440.323],10) ... Wait(1) This way, Saemon and PC turn to each other(3 and 10), and Wait(1) before the start of the dialogue ensures they do. -------------------- |
|
|
Feb 28 2008, 05:53 PM
Post
#12
|
|
Forum Member Posts: 1366 Joined: 22-August 04 From: Germany |
If you can transfer, or even spawn the NPCs, then this is an option, yes. It wasn't for me in this case, though.
|
|
|
Lo-Fi Version | Time is now: 18th May 2024 - 11:47 PM |