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

[EO] NPC Say


Golf
 Share

Recommended Posts

**Eclipse NPC Say System**

I searched on forum and i can't find this system so i decided to make it ![:)](http://www.touchofdeathforums.com/community/public/style_emoticons/<#EMO_DIR#>/smile.png)

NPC Say system allows you to see what is NPC saying every few seconds(adjustable)

it looks like this ![:rolleyes:](http://www.touchofdeathforums.com/community/public/style_emoticons/<#EMO_DIR#>/rolleyes.gif)

![](http://s18.postimg.org/j24bj4iat/image.png)

So lets start

**Client Side**

Serach for this in modText

```

Public Sub DrawNpcName(ByVal Index As Long)

```

In this sub search for

```

'Draw NPC name

Call DrawText(TexthDC, TextX, TextY, Name, color)

```

Replace it with

```

Dim SAY As String

SAY = Trim$(Npc(npcNum).AttackSay)

If Not SAY = vbNullString Then

If GetTickCount Mod 8000 < 4000 Then

Call DrawText(TexthDC, TextX, TextY, SAY, color)

Else

Call DrawText(TexthDC, TextX, TextY, Name, color)

End If

Else

Call DrawText(TexthDC, TextX, TextY, Name, color)

End if

```

Now launch the game , go to admin panel , NPC and then type something you want to (NPC)say in say textbox

Simple!

>! Just replace If GetTickCount Mod 8000 < 4000 Then with
>! If GetTickCount Mod 5000 < 2500 Then
>! or other

>! Problem 1
>! NPC is saying |||||||||||||||||||||||||||||||||||||||||||||||||||
>! Just type NPC name in say textbox

>! Idea - Golf
>! Made by Golf
>! Thanks to
>! Sherwin
Link to comment
Share on other sites

One Information!

Every NPC need to say something (if not NPC will say |||||||||||||||||||||||||||||||||||||||||||||||||||||||||| something like that)

I'm working on it ![:)](http://www.touchofdeathforums.com/community/public/style_emoticons/<#EMO_DIR#>/smile.png)
Link to comment
Share on other sites

Logical Solution very simple for this

> One Information!
>
> Every NPC need to say something (if not NPC will say |||||||||||||||||||||||||||||||||||||||||||||||||||||||||| something like that)
>
> I'm working on it ![:)](http://www.touchofdeathforums.com/community/public/style_emoticons/<#EMO_DIR#>/smile.png)

NPC name is Pirate

Just type Pirate in say textbox and nothing will be changed!
Link to comment
Share on other sites

> One Information!
>
> Every NPC need to say something (if not NPC will say |||||||||||||||||||||||||||||||||||||||||||||||||||||||||| something like that)
>
> I'm working on it ![:)](http://www.touchofdeathforums.com/community/public/style_emoticons/<#EMO_DIR#>/smile.png)

Easy Fixed

replace

```

' Show (Draw) name and NPC Say

Dim SAY As String

SAY = Trim$(Npc(npcNum).AttackSay)

'You can change time (on Forum)

If GetTickCount Mod 8000 < 4000 Then

Call DrawText(TexthDC, TextX, TextY, SAY, color)

Else

Call DrawText(TexthDC, TextX, TextY, Name, color)

End If

```

with

```

' Show (Draw) name and NPC Say

Dim SAY As String

If Not Npc(npcNum).AttackSay = vbNullstring Then

SAY = Trim$(Npc(npcNum).AttackSay)

Else

SAY = vbNullString

End If

'You can change time (on Forum)

If Not SAY = vbNullString Then

If GetTickCount Mod 8000 < 4000 Then

Call DrawText(TexthDC, TextX, TextY, SAY, color)

Else

Call DrawText(TexthDC, TextX, TextY, Name, color)

End If

End If

```
Link to comment
Share on other sites

> Easy Fixed
>
> replace
>
> ' Show (Draw) name and NPC Say
>
> Dim SAY As String
>
> SAY = Trim$(Npc(npcNum).AttackSay)
>
> 'You can change time (on Forum)
>
> If GetTickCount Mod 8000 < 4000 Then
>
> Call DrawText(TexthDC, TextX, TextY, SAY, color)
>
> Else
>
> Call DrawText(TexthDC, TextX, TextY, Name, color)
>
> End If
>
> with
>
> ' Show (Draw) name and NPC Say
>
> Dim SAY As String
>
> If Not Npc(npcNum).AttackSay = vbNullstring Then
>
> SAY = Trim$(Npc(npcNum).AttackSay)
>
> Else
>
> SAY = vbNullString
>
> End If
>
> 'You can change time (on Forum)
>
> If Not SAY = vbNullString Then
>
> If GetTickCount Mod 8000 < 4000 Then
>
> Call DrawText(TexthDC, TextX, TextY, SAY, color)
>
> Else
>
> Call DrawText(TexthDC, TextX, TextY, Name, color)
>
> End If
>
> End If

Tested not working
Link to comment
Share on other sites

> Logical Solution very simple for this
>
> **Quote**
>
> [background=rgb(247, 247, 247)]One Information!
>
> Every NPC need to say something (if not NPC will say |||||||||||||||||||||||||||||||||||||||||||||||||||||||||| something like that)
>
> I'm working on it ![:)](http://www.touchofdeathforums.com/community/public/style_emoticons/<#EMO_DIR#>/smile.png)[/background]
>
> NPC name is Pirate
>
> Just type Pirate in say textbox and nothing will be changed!

Solution :/
Link to comment
Share on other sites

replace your entire tutorial with this

Serach for this in modText

```

Public Sub DrawNpcName(ByVal Index As Long)

```

In this sub search for

```

'Draw NPC name

Call DrawText(TexthDC, TextX, TextY, Name, color)

```

Add Below

```

Dim SAY As String

SAY = Trim$(Npc(npcNum).AttackSay)

If Not Say = vbNullString Then

If GetTickCount Mod 8000 < 4000 Then

Call DrawText(TexthDC, TextX, TextY - 15, SAY, color)

End If

End If

```
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...