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

[EO 2.0] NPC Speech Box with NPC Face.


Broojo02
 Share

Recommended Posts

  • Replies 121
  • Created
  • Last Reply

Top Posters In This Topic

Yep sure, you've gotta open up the client.vbp file in the client folder, double click on the frmMain file in the project explorer on the right of the screen. Then click the PictureBox button on the left hand side of the screen (its the one that looks like a small desert scene), then click and drag on the frmMain form to create a new picture box in there. To make sure its on top of everything, click on the grey background near the top of the form.

To add a picture to the Picture Box you should click on it and look in the properties for it in the bottom left corner of the screen, there should be a picture option there, click on the "…" button to add a new picture.

Oh and you need VB6.
Link to comment
Share on other sites

@Broojo:

> Yep sure, you've gotta open up the client.vbp file in the client folder, double click on the frmMain file in the project explorer on the right of the screen. Then click the PictureBox button on the left hand side of the screen (its the one that looks like a small desert scene), then click and drag on the frmMain form to create a new picture box in there. To make sure its on top of everything, click on the grey background near the top of the form.
>
> To add a picture to the Picture Box you should click on it and look in the properties for it in the bottom left corner of the screen, there should be a picture option there, click on the "…" button to add a new picture.
>
> Oh and you need VB6.

thanks :) and yea i have VB6 after 3 days of searching for it XD and i only no how to do this with JAVA due to RSPS's from years ago.. but if you wouldn't mind sending me a PM or something explaining how to make click-able options in the text box? Because im making a PKA (Pk arena) and i dont want a warp tile to go in it i want to have you talk to the NPC and have him say "you wana go to pka?" and have the options "yes" and "no" "yes" being you get teled to pka "no" being textbox closes and you stay on map.
Link to comment
Share on other sites

@Broojo:

> Ok, I have updated the tutorial so that the speech box appears over the text box as requested, it now only uses 1 picture file. I have also added face support so you can see who is talking to you, how nice :)

WOW, very nice, dude ;)
Link to comment
Share on other sites

:sad: 
I'm already finished with the Client-Side(Server-Side 0%)
When I compile the client,a window appears on my VB6.
It says :
Compile error:

Method or data member not found
___________________________________
Then an arrow appears pointing at:

Sub TcpInit()
___________________________________
Then this is highlighted:
.Socket
(In frmMain.Socket.RemoteHost = Options.IP)
___________________________________
Please help me with this problem!
I searched Google and the forums.
(I have EO Runtimes installed)
(I use Visual Basic 6:Enterprise Edition)
Please send me a file or please help me solve this.

I am very desperate and this is the guide I've been waiting for!
:cheesy: TYVM!
Link to comment
Share on other sites

You have to do the work on the client and the server before compiling any of them, open them both up, do the work on each of them and then load up the server, then the client.

You just need to click the play button at the top of the screen.
Link to comment
Share on other sites

I keep getting RTE 9; Subscript out of range, although I've definitely put things in the right place.

When I Debug it, it's apparently to do with
```
  CopyMemory ByVal VarPtr(NPC(n)), ByVal VarPtr(NpcData(0)), NpcSize
```
But, I haven't edited it…If it matters, I'm using a copy of Eclipse Origins; that had Alatar's Quest System pre-sourced onto it. I've done it before on a vanilla-copy, so I think it's something that's part of Alatar's source.
Link to comment
Share on other sites

@Broojo:

> Maybe its a conflict but RTEs can usually be resolved by deleting files used in the game, if you can it might help to delete all the NPCs from the client and server.

Ah, that may explain it…Dur, got to redo the thing, I just took all the code out. x[

EDIT: Found the cause; I did the optional extend text-thingy, and forgot to do it Server-side as well
Link to comment
Share on other sites

Oh, and Broojo, I have a little question/suggestion combined.

I've taken this a bit further, so that you're character can't move when you're talking.
I've figured out how to stop the character, but I can't restart the movement.

If you can help me figure it out, then feel free to add it to the tutorial under the optional stuff.
Link in more detail here: [http://www.touchofdeathforums.com/smf/index.php/topic,71062.msg764053.html#msg764053](http://www.touchofdeathforums.com/smf/index.php/topic,71062.msg764053.html#msg764053)

BTW, it looks great :D

>! [![](http://www.freemmorpgmaker.com/files/imagehost/pics/fd0a6ca37ea7dfe178c0fa6c5f18789d.png)](http://www.freemmorpgmaker.com/files/imagehost/#fd0a6ca37ea7dfe178c0fa6c5f18789d.png)
Link to comment
Share on other sites

  • 2 weeks later...
I did everything step by step and can't get it to work, I'm not getting any errors, it's just not doing it, like I added all the pic boxes and the label and gave them the settings, and added all the code, but it's still showing the boring ole' text, I mean don't get me wrong I just downloaded EO today, wanting to get a refresh from Stable, as I haven't had internet in a good long while, but yea, any help would be much obliged :D
Link to comment
Share on other sites

You did add:
```
Private Sub HandleSpeechWindow(ByVal Index As Long, ByRef Data() As Byte, ByVal EditorIndex As Byte, ByVal StartAddr As Long, ByVal ExtraVar As Long)

Dim Buffer As clsBuffer
Dim msg As String
Dim npcNum As Long
Set Buffer = New clsBuffer
Buffer.WriteBytes Data()

msg = Buffer.ReadString
npcNum = Buffer.ReadLong

    If Not FileExist(App.Path & "\data files\graphics\faces\" & (Npc(npcNum).Sprite) & ".bmp", True) Then
        frmMain.picSpeechFace.Picture = LoadPicture(App.Path & "\data files\graphics\faces\" & "default.bmp")
    Else
        frmMain.picSpeechFace.Picture = LoadPicture(App.Path & "\data files\graphics\faces\" & (Npc(npcNum).Sprite) & ".bmp")
    End If

frmMain.picSpeech.Visible = True
frmMain.lblSpeech.Caption = "" & msg & ""
frmMain.lblSpeech.Visible = True
frmMain.picSpeechClose.Visible = True
frmMain.picSpeechFace.Visible = True

End Sub
```
Right?

It won't call and display the message if you've forgotten this…
Link to comment
Share on other sites

It might be that you have got the speech box below something or not in the right place. Its a common error to place a picture box inside something else like an another picbox without realising it. To make sure the newly added picbox is on top of everything you should start drawing it from the very top left of frmMain where the dotted grey border is, as this is the background of the form.
Link to comment
Share on other sites

I did, but the only real question i had, I mean I will figure it out eventually, but the sizes that u have they are enormous are they supposed to be that big like 1500x1500 for picSpeechFace…. just wondering if maybe i read that wrong or somethin
Link to comment
Share on other sites

@kira423:

> I did, but the only real question i had, I mean I will figure it out eventually, but the sizes that u have they are enormous are they supposed to be that big like 1500x1500 for picSpeechFace…. just wondering if maybe i read that wrong or somethin

VB6 uses twips to measure things.
http://www.unitconversion.org/typography/twips-to-pixels-y-conversion.html
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...