Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

DarkBASIC Discussion / Ahhh! DB keeps crashing when i execute

Author
Message
MattindaHat
21
Years of Service
User Offline
Joined: 15th Dec 2002
Location:
Posted: 16th Dec 2002 03:28
After compiling and running my code for a few times, DB just freezes up and i have to reboot my computer over and over again. Can someone tell me what possibly is wrong? I run a very fast computer w/ a 64mb vid card. thanks
John H
Retired Moderator
21
Years of Service
User Offline
Joined: 14th Oct 2002
Location: Burlington, VT
Posted: 16th Dec 2002 04:17
Probably an error in your code. I have heard peoples DB doesnt crash with the cd NOT in it. If your CD is in the drive with DB running, try removing it.

If that doesnt work, you probably have an error in your code.

Good luck!
RPGamer

Current - RPG: Eternal Destiny : Help Wanted!
Upcoming- MMOFPS- Paintball Game: HELP WANTED!
Http://halbrosproductions.netfirms.com
MattindaHat
21
Years of Service
User Offline
Joined: 15th Dec 2002
Location:
Posted: 16th Dec 2002 04:24
no, its not that. i can run the same code the first few times and it works, but after that it just freezes up. it happens with or without the cd in.
John H
Retired Moderator
21
Years of Service
User Offline
Joined: 14th Oct 2002
Location: Burlington, VT
Posted: 17th Dec 2002 13:58
What else do you have running?

RPGamer

What are your comp specs?

Current - RPG: Eternal Destiny : Help Wanted!
Upcoming- MMOFPS- Paintball Game: HELP WANTED!
Http://halbrosproductions.netfirms.com
actarus
21
Years of Service
User Offline
Joined: 29th Aug 2002
Location: 32 Light Years away
Posted: 17th Dec 2002 14:15
Looks like a memory leak...

Solutions:

(sweet)Add some more RAM in that machine(/sweet)

(pain)Try re-booting between tryouts(/pain)

Just remember that you're standing on a planet that's evolving
And revolving at nine hundred miles an hour!
philippe
21
Years of Service
User Offline
Joined: 17th Dec 2002
Location:
Posted: 17th Dec 2002 20:29
before to stop your program , don't forget to clean the memory properly , for instance :

rem main program
disable escapekey()
do
....
if escapekey() then exit
loop

for i = 1 to 6553(
if object exist(i) then delete object i
if matrix exist(i) then delete matrix i

if image exist(i) then delete image i
if sprite exist(i) then delete sprite i
if mesh exist(i) then delete mesh i
next i
for i = 1 to 1014
if sound exist(i) then delete sound i
next i
for i = 1 to 32
if animation exist(i) then delete animation i
if file open(i) then close file i
if music exist(i) then delete music i
next i
for i = 1 to 31
if bitmap exist(i) then delete bitmap i
next i
for i = 1 to 7
if LIGHT EXIST(i) then delete light i
next i

EMPTY CHECKLIST

DELETE STATIC OBJECTS

sync off
backdrop off
cls
flush video memory


This code is effcient when there are no crash during the excution of the programm.

MattindaHat
21
Years of Service
User Offline
Joined: 15th Dec 2002
Location:
Posted: 19th Dec 2002 07:20
thanks. it doesnt crash anymore (except on rare occasions)

Login to post a reply

Server time is: 2024-03-02 17:09:45
Your offset time is: 2024-03-02 17:09:45