SRL Archive - C#/Visual Basic Help and Tutorials

Cooking exp Calculator


Cazax

2008-11-23 11:40:26

My first VB program :)
it does only support F2P foods.
hope you like it -

jakeyboy29

2008-11-23 11:41:40

You need to cook: 479705 Meat

working :D well done

Enchanted

2008-11-23 11:48:31

Runtime error "6" overflow.

When I put xp 0 - designated level 99.

Cazax

2008-11-23 11:58:49

From: Enchanted
Runtime error "6" overflow.

When I put xp 0 - designated level 99.


Works perfectly for me :confused:

gimillii1592

2008-11-23 12:56:35

Cool…ty
This is very helpful :]

jakeyboy29

2008-11-23 13:08:41

works great. no errors. maybe make a fighting one?

gimillii1592

2008-11-24 01:07:19

make a hunter one please
:]
or ill make that
lol

gimillii1592

2008-11-24 01:08:50

how about posting the source code?
that would be nice :]

Enchanted

2008-11-24 05:03:29

^ Double post ftl?..

Well, I tried again and it worked fine :)

This is just a suggestion but maybe make one with all the levels(that you want in.. :rolleyes:)

Best of luck, 3NCH4NT3D.

Laimonas171

2008-12-17 16:47:07

Source please. now it's useless app. i wanna see method of level/exp calculating.. u using case function? or whaT?

Cazax

2008-12-20 13:41:58

Ok, here is the sourcre:
[PHP]Public Function Floor(value As Double)

Floor = CDbl(CLng(value - 0.5))

End Function
Public Function experience(ByVal lvl As Integer)
Dim a As Long
Dim x As Integer
For x = 1 To lvl
a = a + Int(x + 300 * (2 ^ (x / 7)))
Next x
experience = Floor(a / 4)
End Function
Private Sub Command1_Click()
Dim EXP As Integer
Dim a As Long
Dim x As Integer
Select Case Combo1.Text
Case "Meat": EXP = 30
Case "Chicken": EXP = 30
Case "Crayfish": EXP = 30
Case "Shrimps": EXP = 30
Case "Anchovy": EXP = 30
Case "Bread": EXP = 40
Case "Sardine": EXP = 40
Case "Herring": EXP = 50
Case "Redberry Pie": EXP = 78
Case "Trout": EXP = 70
Case "Meat Pie": EXP = 110
Case "Pike": EXP = 80
Case "Stew": EXP = 117
Case "Salmon": EXP = 90
Case "Apple Pie": EXP = 130
Case "Tuna": EXP = 100
Case "Pizza": EXP = 143
Case "Wine": EXP = 200
Case "Cake": EXP = 180
Case "Lobster": EXP = 120
Case "Meat Pizza": EXP = 169
Case "Swordfish": EXP = 140
Case "Chocolate Cake": EXP = 210
Case "Anchovy Pizza": EXP = 182
End Select
Text3.Text = "You need to cook: " + Str(Round(((experience(Text2.Text) - Text1.Text) / EXP))) + " " + Combo1.Text

End Sub
[/PHP]
Feel free to leech.

Naum

2008-12-21 08:54:19

Cant you make this in SCAR aswell??

Imho GJ btw.

NiiX

2009-03-31 10:40:06

I am currently making a program that will work for all skills, should take about 1 or 2 weeks (I have a life and Construction isnt helping me alot..)