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

[Solved] Tool


Zzbrandon
 Share

Recommended Posts

Alright. Give me some time and I'll get it.

EDIT:

Alright! Go into client, and look for ResourceRec. Add there

```

[color]EQUIPMENTNAME[/color]Required as long

```

Copy and paste as many times as you have item slots (excluding weapon) and rename EQUIPMENTNAME with the name of the equipment slot.

***DO THE SAME IN SERVER***

Go to frmEditor_Resource and make space for more scrollbars and labels. Make as many new scrollbars as new ResourceRecs that you made and rename them to scrlEQUIPMENTNAMEReq. Rename appropriately.

Make the same number of labels, rename them to lbbEQUIPMENTNAME. Now change the caption to```
[color]EQUIPMENTNAME[/color] required: None
```

Now double click on each new scrollbar and put there this.

```

Dim name As String

' If debug mode, handle error then exit out

If Options.Debug = 1 Then On Error GoTo errorhandler

Select Case scrl###EQUIPMENTNAME.value

Case 0

name = "None"

Case 1

name = "Hatchet"

Case 2

name = "Rod"

Case 3

name = "Pickaxe"

End Select

###lblEQUIPMENTNAME.Caption = "###EQUIPMENTNAME Required: " & name

Resource(EditorIndex).###EQUIPMENTNAME###Required = scrl###EQUIPMENTNAME###Req.value

' Error handler

Exit Sub

errorhandler:

HandleError "scrl###EQUIPMENTNAME_Change", "frmEditor_Resource", Err.Number, Err.Description, Err.Source, Err.HelpContext

Err.Clear

Exit Sub

```

Now go to ResourceEditorInit and look for```

.scrlAnimation.value = Resource(EditorIndex).Animation

```

Under it put there```

.scrl###EQUIPMENTNAME###Req.value = Resource(EditorIndex).###RESOURCENAME###Required

```

Save and compile.

Go to server and look for```

If Item(GetPlayerEquipment(index, Weapon)).Data3 = Resource(Resource_index).ToolRequired Then

```

Add under it```

If Item(GetPlayerEquipment(index, ###EQUIPMENTNAME)).Data3 = Resource(Resource_index).###EQUIPMENTNAME###Required Then

```

Close it off after```

SendActionMsg GetPlayerMap(index), Trim$(Resource(Resource_index).EmptyMessage), BrightRed, 1, (GetPlayerX(index) * 32), (GetPlayerY(index) * 32)

End If

End If

```

With an appropriate number of "end if"s

Save, and compile. Let me know if you have any questions.
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...