Darwinbots Forum
Code center => Darwinbots Program Source Code => Topic started by: Botsareus on April 19, 2005, 04:36:23 PM
-
I found 2 overflow errors one I fixed , the other is a different story.
It turns out that when you run somthing in vb it runs is with the [you]same compilation rules as it does if you make exe file [/you], therefor you guys (PY, NUM) have to go to Options > compile > , turn Advanced optimizations off , then turn favor pentum pro (for the hell of it) on
Here is the trouble codes I pinpointed that cause the overflows"
the call for repruduction , the "per" part can get intager overflows.
Reproduce rep(t), rob(rep(t)).mem(repro) + rob(rep(t)).mem(mrepro) 'causes oveflows
and finaly
Private Function customcequa(n As Integer) As Boolean
'usage: 10 20 30 ~= is are 10 and 20 within 30 percent of each other?
Dim a As Integer
Dim b As Integer
Dim c As Integer
Dim d As Integer
d = readst(n)
b = readst(n)
a = readst(n)
c = a / 100 * d
'Here I am getting NEGATIVE values for c that cause integer oveflow
customcequa = (a - c <= B) And (a + c * 1# >= B)
End Function
Note that I did not change the code for ANY of this models.
Note that I am waiting again on a virsion, and got rid of my mutation fixes hoping that its already added to the virsion you guys have. Lets start a new topic to with a list of stuff that needs to be done to mutation. In the mean time read this; try to comprehend it, and good luck with what ever you are working on.
-
One more error , really annoing , when I Properly exit the Darwin Bots program it crashes, This has something to do with the quary unload code in the Mdi parent form.
-
You can only exit DarwinBots from the VB screen by clicking the stop button. It is kind of annoying but not difficult to get around.
-
Aright, I've fixed the two problems you've said. Both are
Does the crashing program happen everytime you exit? I don't think anyone's ever found something like that. It's weird how sometimes we get specific bugs that are only on some people's systems. There's definately not a universiality to VB.
-
Num, what was happening in the top problem? (I could not figure it out at all)
-
I captolized my I letters here I hope...
-
Does the crashing program happen everytime you exit?
This is only when running from code.
If I run the sim then click the little X like you normally do, VB crashes completely. I have to go back into the code window and stop it from there.
It has always done this for me. Happens on all of my PCs (four different systems now). I just assumed that it did for everybody.
-
thx PY..., Num you there?
-
Wow guys, I can exit the program normally even when running through VB front end.
Bots, the problem was that its passing integer + integer to integer. So for incredibly stupid values for repro and mrepro (like 32000 each), it'll overflow.
-
ic , lol , thx Num.. thats what its for that "per", I mean clue people whats "per" .. anyway,
Num: Yes Program crashes on crapy prossesors big time when you exit, maybe its the vedio card , I have no clue...
Maybe its the OS?
we need to fix it in the code, we won't tell everyone to: "go get a DELL"
-
I am running a top of the range Dell, a 2.8 gig Compaq Presario and a 4 year old E-Machine i700 with a Celeron chip. It crashes exactly the same way on all 3 of them. :(
-
we need to fix it in the code, we won't tell everyone to: "go get a DELL"
Lol, I AM running a Dell. I think we've found the problem.
-
I'm running in 98. Maybe that matters...
-
Possibly but I doubt it.
My Dell is running 2000 (daughter product of NT)
My E-Machine is running ME (daughter of 98) though it has run XP professional
My (daughter's) Presario is using XP home edition
It crashed on every computer and every operating system in exactly the same way.
-
I'm running VB 6.0.8169. Is that what you all are running?
-
HA! , I figured out a way to fix that one already :laugh:
We make a new .bas based exe program that does wm_distroy on the first microsoft fatal error window it sees, Now before DB closes it does shell on this exe program.. we call it Patch.exe
-
I think that's cheating, lol.
-
Mine is 6.0.8169 too
-
Well I'm stumped. If anyone figures this one out (why it works for me and not for them), you get something cool.