Jump to content

Making a creature "talk"


scarycave

Recommended Posts

Oh BTW Converting the angles returned by get angle for use with the trig functions is completely unnecessary. All you got to do is flip the axes, (sin = x axis, cox = y in this case)

Method from wiki:

if ( GetAngleZ < 90 )
set TrigAngleZ to 90 - GetAngleZ
else
set TrigAngleZ to 450 - GetAngleZ

endifif

 

so assume 120 degrees: old way

450-120= 330; Cos 330 = 0.866 (applied to x axis); Sin 330 = -0.5 (applied to y axis)

 

or my way

Cos 120 = -0.5 ( apply instead to y axis): Sin 120 = 0.866 (apply instead to x axis)

 

no need to convert the angles and the calculations work out the same.

Link to comment
Share on other sites

  • Replies 47
  • Created
  • Last Reply

Top Posters In This Topic

Glad to hear its working out for you. I'm just about at the finish line myself, I just need to get these pesky Mp3 files to work...sound is one of the reasons I wanted to make something like this in the first place.

Also have you tried talking to your creature on a stair-case yet? I've been getting some camera issues, the NPC seems to fall through the stairs. I don't know if you'll have this probelm since your using a menu, but it couldn't hurt to check it out.

Link to comment
Share on other sites

  • 2 weeks later...

I was playing around with the INI files, about "disabling" the zoom in. I think it might be worthwhile to look into it - however, one thing I absolutely want to have with this mod is accesability and simplicity.

Telling everyone to set their Zoom in to 12 so it stops seems like a really restrictive move. I was curious if theirs anyway to have the INI changed via coding.

 

Something like this:

 

Begin OnLoad

Set StandardINI to "ZoomIni"

End

 

Begin GameMode -

 

IF "not talking" == false

Set "ZoomIni" to StandardInI

Endif

 

if "talking" == true

Set "ZoomIni" to 12

endif

 

End

 

It would get the value when the game is loaded as a variable.

It would use the variable to set the ini value to its default (when it was loaded) when not in conversation.

It would set the value to cancel the zoom-in when talking.

 

Since the system I have has to steps:

 

IsTalking == 1 - to set up the character.

IsTalking == 2 - to clean everything up and resetting to 0.

 

I could easily use code to let this work with other mods that need to disable the zooming function.

So I could have the player not zoom in on the dog, but zoom in on the Lich.

 

The big IF though, is that the Ini can be changed via scripting in the first place....which I have severe doubts that this is possible.

Link to comment
Share on other sites

I haven't had much luck with the ini...but I have managed to get mp3's working! I used an online converter to convert the sounds into the right format.

Since I'm having a lot of trouble with the dog stuff positioning - I'm going to be working on a skeleton when I get the chance, look in to giving him his own dialogue stuff like that, maybe release it in a few weeks as a companion and demonstration.

Link to comment
Share on other sites

I had all sorts of problems with positioning with mine. Both the creature and the NPC would slide all over the place until the dialog started and yes, there were times when the NPC fell through the floor as well. But when the NPC didn't fall through the floor, they insisted on being at ground level, Scaling them down to be tiny just made my PC look at the creature's feet. Unfortunately, real world matters have kept me from working on mine much lately, so I haven't been making much progress.

Before I got frustrated by the speed issues, I was trying to scale the NPC so that their face was the same height as the creature's and offsetting their position so that the faces would overlap. I think I had to toggle the collision off for both of them or it wouldn't work. but after waiting for a final re-positioning once the dialog started, the camera would zoom in on the creature's face perfectly.

Link to comment
Share on other sites

  • 2 weeks later...

I just made a break through! So far, I've been testing with Sir Edmund (a skeleton) and a wolf, Sir Edmund is working fine, since he's the same size. The wolf however, had problems, due to its idles being on all fours, requiring a lot of trigonometry code, and scaling which both could lead to the speaker getting stuck on stairs or appear in the wrong spot while swimming...until now. I used some stuff I learned from the Blood the dog mod to pick idles depending on script variables, so I played with a few animations, none were working out. Then I found it.

 

You see, the dog/wolf has a few unused animations - one I used for Blood's being pet animation, one of them is called "sandup" - which makes the dog stand up on its hind legs! Making it the perfect height, meaning I no longer need

trigonometry or scaling the speaker character.

 

Progress.

http://i.imgur.com/4AV7BIx.jpg

Link to comment
Share on other sites

  • 2 weeks later...

Well, it didn't turn out as well as I'd hoped with the standing thing, I wanted to say that it didn't look goofy as hell, but yeah.

I got a bit carried away there...however, I found something useful that should really help. I used a wolf mesh as the skeleton, and the game has no idea what its looking at, and says, "whatever", and pans over the body. It eliminates the close-up!

 

I've also been studying the Daedric quest scripts, and I found an interesting command known as "say", which forces an actor to say commands, and has a toggle to ignore distance. With it, and some scripting, I was able to get a dog to pull up a subtitle - "growl..." every-time it went into combat.

For folks like Edmund, the skeleton knight I'm working on, I can get a bit more creative (since he can speak) with it.

Link to comment
Share on other sites

  • Recently Browsing   0 members

    • No registered users viewing this page.

×
×
  • Create New...