That's basically giving the player a LOT of extra xp.
If you have 10 spd, and you get 100 xp, that's 1000 exp, for a bonus of 500 xp, since you divide it by 2. Lol.
yea I fixed it lmao, I relaized that after I killed omehitng giving 5 exp :/
i got another question, See, I made it so that depending on the NPC's Speed and Your speed, the NPC can miss its attack on you, but 9/10 NPC attacks are missssed even if their Speed is higher then mine.. Heres the check code
[code]
Function CanNpcMiss(ByVal index As Long, NpcNum As Long) As Boolean
Dim i As Long, n As Long
CanNpcMiss = False
If Npc(NpcNum).SPEED >= GetPlayerSPEED(index) Then
CanNpcMiss = False
Else
n = Int(Rnd * 2)
If n = 1 Then
i = Int(GetPlayerSPEED(index))
n = Int(Rnd * Npc(NpcNum).SPEED) + 1
If n
Try changing:
n = Int(Rnd * 2)
To:
n = Int(Rnd * 2) + 1
See if that works.
Is Randomize Timer called anywhere in the source? Hopefully just once on form load.
Randomize Timer is more random then just Randomize.
[quote]Basically...
Randomize reseeds the pseudo random sequence generated by Rnd. Unfortunately (because it uses a two byte hash) it only has access to a small portion of the full sequence (1/256th of 2^24 possible entry points). Calling it more than once does not make the sequence more Random it increases the chances of a repeat sequences coming up.
As a side note, rather than calling Randomize at all you can use Rnd -number to reseed Rnd. This provides full access to the sequence and so gets more out of Rnd than reseeding with Randomize.
[code]Private Sub Form_Load()
Rnd -Now - Timer '