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

Run-Time Error 9 with Conv System


troglodite
 Share

Recommended Posts

Here we go again ![:P](http://www.touchofdeathforums.com/community/public/style_emoticons/<#EMO_DIR#>/tongue.png)

Im trying to add [that system](http://www.touchofdeathforums.com/community/index.php?/topic/120709-csde-to-eo-conversation-system-v11/), all is pasted, I choose to add the _**"****OPTIONAL STEP** instead of the last part_" (view page to understand plz)

But when I log into the game, a RTE appears: _Runtime error '9': Subscript out of range_

Debugged line (**CLIENT SIDE)**:```
ReDim Conv(Convnum).Conv(1 To .chatCount)
```
Any ideas? ![:(](http://www.touchofdeathforums.com/community/public/style_emoticons/<#EMO_DIR#>/sad.png)
Link to comment
Share on other sites

I did that to check it (I made a back up of the NPC folder) but the problem persist

I dont know WHY but I think its about the "S" list and "C" list in modEnumerations what is making me the problem,

because everytime I add new lines here, I have problems… ![:(](http://www.touchofdeathforums.com/community/public/style_emoticons/<#EMO_DIR#>/sad.png)

I want to fix it, but I cannot understand what is wrong; these lists ("S" and "C") are the same in Client and Server sides ¬_¬
Link to comment
Share on other sites

lol, you again xd

ok, that line, on which it errors, what part is the error? see it by hovering over the respective variables, in this case

Convnum and chatCount

when we know what part errors, we can look further ![:)](http://www.touchofdeathforums.com/community/public/style_emoticons/<#EMO_DIR#>/smile.png)

ps, i really hoped you would translate your game in english, think much people will play that game, its nice.
Link to comment
Share on other sites

> lol, you again xd
>
> ok, that line, on which it errors, what part is the error? see it by hovering over the respective variables, in this case
>
> Convnum and chatCount
>
> when we know what part errors, we can look further ![:)](http://www.touchofdeathforums.com/community/public/style_emoticons/<#EMO_DIR#>/smile.png)

Hello Dami ![:P](http://www.touchofdeathforums.com/community/public/style_emoticons/<#EMO_DIR#>/tongue.png)

The error comes from Client:

```

Private Sub HandleUpdateConv(ByVal Index As Long, ByRef Data() As Byte, ByVal StartAddr As Long, ByVal ExtraVar As Long)

Dim Convnum As Long

Dim Buffer As clsBuffer

Dim i As Long

Dim x As Long

Set Buffer = New clsBuffer

Buffer.WriteBytes Data()

Convnum = Buffer.ReadLong

With Conv(Convnum)

.Name = Buffer.ReadString

.chatCount = Buffer.ReadLong

ReDim Conv(Convnum).Conv(1 To .chatCount)

For i = 1 To .chatCount

.Conv(i).Conv = Buffer.ReadString

For x = 1 To 4

.Conv(i).rText(x) = Buffer.ReadString

.Conv(i).rTarget(x) = Buffer.ReadLong

Next

.Conv(i).Event = Buffer.ReadLong

.Conv(i).Data1 = Buffer.ReadLong

.Conv(i).Data2 = Buffer.ReadLong

.Conv(i).Data3 = Buffer.ReadLong

Next

End With

Set Buffer = Nothing

End Sub

```

Debugged line:

```

ReDim Conv(Convnum).Conv(1 To .chatCount)

```

> ps, i really hoped you would translate your game in english, think much people will play that game, its nice.

That would be so **NICE**, if there were some _codes_ to change the language of the whole game (ítems,titles of Maps,server-client messages and quest texts) using a "list" of languages from the menu for example (english/spanish) to selecting

With a code like this, I can translate everything with no problem, because I dont want to lose all the spanish texts

ps Zopto gave me a link to add event system to my engine, thats haves a conversation system, so maybe I´ll try to add event system instead of fix that…
Link to comment
Share on other sites

WELL, I choose other conversation system, it works correctly and I like it so much! thx to Zopto for give me [the link](http://www.touchofdeathforums.com/community/index.php?/topic/114914-eo-20-npc-speech-box-with-npc-face/page__hl__%2Bmassive+%2Bcredit+%2Bmurdoc%2C+%2Bthis+%2Bpretty+%2Bmuch+%2Bedit+%2Bquest+%2Bsystem+%2Bsubmitted)

I will change this topic to solve, isn't solved but it's better for organization…
Link to comment
Share on other sites

hmm, ok, so thats out of the way.

you are willing to make it english if you can switch between spanish and english huh?

that should be do-able, let me try some stuff, and ill PM you if i get something going ![:)](http://www.touchofdeathforums.com/community/public/style_emoticons/<#EMO_DIR#>/smile.png)
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...