Jump to content
Search In
  • More options...
Find results that contain...
Find results in...

How do you script talking?


jakeob22
 Share

Recommended Posts

I dont know how to script it so that if you press "enter" next to my character it makes them talk. I want them to give you a quest that you can do. So can anybody help me make sombody that you can talk to that gives you a quest. And after I make that guy how do I script the rest of the quest?
Link to comment
Share on other sites

Sorry, forgot the colors, thanks for the help Frogurt Friday - мсичġġєт…  You also need to change the case accordingly. So let's say this is my script.

Case 1
Call PlayerMsg (index, "Hi my name is bob", BLACK)

Case 1
Call PlayerMsg (index, "Hi my name is bob", BLACK)

WRONG! Here's the right way.

Case 1
Call PlayerMsg (index, "Hi my name is bob", BLACK)

Case 2
Call PlayerMsg (index, "Hi my name is bob", BLACK)

The difference is the cases. You would have to keep going up for each new script.
Link to comment
Share on other sites

@The:

> Sorry, forgot the colors, thanks for the help Frogurt Friday - мсичġġєт…  You also need to change the case accordingly. So let's say this is my script.
>
> Case 1
> Call PlayerMsg (index, "Hi my name is bob", BLACK)
>
> Case 1
> Call PlayerMsg (index, "Hi my name is bob", BLACK)
>
> WRONG! Here's the right way.
>
> Case 1
> Call PlayerMsg (index, "Hi my name is bob", BLACK)
>
> Case 2
> Call PlayerMsg (index, "Hi my name is bob", BLACK)
>
> The difference is the cases. You would have to keep going up for each new script.

If someone doesn't know that yet, then I recommend him/her to read [these](http://www.touchofdeathforums.com/smf/index.php/topic,48978.0.html).

Regards,
  Godlord.
Link to comment
Share on other sites

I went to character behavior and put it as scripted. Then I put the script at number one. I targeted my character and hit ctrl and it kind of showed me walking into him. The thing I typed was:

Sub ScriptedNPC(index, Script)
Select Case Script
    Case 0
        Call PlayerMsg(index, "NPCz Work", 15)
    Case 1
        Call PlayerMsg(index, "Shawn: Hi! Welcome to my house!", RED)
End Select
End Sub
Link to comment
Share on other sites

> Sub ScriptedNPC(Index, Script)
>     Select Case Script
>         Case 0
>             Call PlayerMsg(Index, "NPCz Work", WHITE)
>             Exit Sub
>
>         Case 1
>             Call PlayerMsg(Index, "Shawn: Hi! Welcome to my house!", BRIGHTGREEN)
>             Exit Sub
>     End Select
> End Sub

Fixed that.

Regards,
  Godlord.
Link to comment
Share on other sites

@jakeob22:

> I targeted with the code you gave me and hit ctrl. It just kind of looked like I was walking in to him. I need help to get the message at the bottom when I hit ctrl when targeting. Any ideas?

That's vague, rephrase please. Explain clearly what the problem is and what you want.

Regards,
  Godlord.
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...