1. Win32 problems
- Posted by Davi Figueiredo <davitf at USA.NET> Dec 19, 1998
- 353 views
Hi everyone, I've been trying to create a game in Win32 and it's almost finished, but I've been having some problems: 1. About once every four or five times, the program crashes with the message "The instruction at bff64e46 referenced memory at ffffffff - The memory could not be read from" as soon as it starts (before showing the game window). I don't know what I can do to solve this, it's really annoying me. Does anyone know what is happening? I may post the code if it is needed. 2. How can I create a window without the title bar (like WinAmp and other programs)? My game would look better... I'm using Win32Lib to create this game. Regards and happy holidays if I don't post anything else till Christmas, Davi Figueiredo davitf at usa.net PS. About the encryption thread: I know I'm late again, when I read the latest messages about that subject I tought about writing some other unimportant comments, but it seems like it's finished now... anyway, I think EuServer's encryption is already strong. ____________________________________________________________________ Get free e-mail and a permanent address at http://www.amexmail.com/?A=1
2. Re: Win32 problems
- Posted by Hawke' <mdeland at GEOCITIES.COM> Dec 19, 1998
- 321 views
Davi Figueiredo wrote: > I've been trying to create a game in Win32 and it's almost finished, but I've > been having some problems: > 1. About once every four or five times, the program crashes with the message > "The instruction at bff64e46 referenced memory at ffffffff - The memory could > not be read from" as soon as it starts (before showing the game window). I > don't know what I can do to solve this, it's really annoying me. Does anyone > know what is happening? I may post the code if it is needed. you have coded a "programming oversight" as an undocumented feature into your game. :) also, it could be a bug in the version of win32lib.ew you are using as well. either way, it's bug hunt time, so break out the Raid... if you can segregate the code into code that does work and code that isn't working, and post the for sure broken code, i would think that some of us may be willing to take a gander and see if we can spot the pesky critter... > 2. How can I create a window without the title bar (like WinAmp and other > programs)? My game would look better... > I'm using Win32Lib to create this game. i may be trying/attempting the same thing myself, and if i figure it out, i'll let you know, and if you figure it out, let me know... k? --Hawke'
3. Re: Win32 problems
- Posted by David Cuny <dcuny at LANSET.COM> Dec 19, 1998
- 330 views
Davi Figueirendo wrote: > 1. About once every four or five times, the program crashes ... As Hawke suggested, try to isolate the instruction(s) that cause the error. I'll be glad to take a look at the code, especially if you can narrow it down a bit. > 2. How can I create a window without the title ... Use the last parameter in the create() function. For controls, this value is cumulative (they add on to whatever flags are already set), but for windows, they replace the default values. The flags that control the window styles start with WS_; you might try WS_POPUP. You can also add (or or_all) several attributes together. I may eventually define a number of default window styles for portability between Win32Lib/Dos32Lib. -- David Cuny
4. Re: Win32 problems
- Posted by Hawke' <mdeland at GEOCITIES.COM> Dec 19, 1998
- 320 views
David Cuny wrote: > The flags that control the window styles start with WS_; you might try > WS_POPUP. You can also add (or or_all) several attributes together. that worked like a champ! :) not only that, it didn't make an entry in my taskbar! (which is actually what *I* wanted, but davi, you may not want that...) (it will make it easier for me to run the server as a "process" instead of a "window" and i will thusly be able to start it 'hidden' with only a tray icon... the eventual goal of the gui for EUServer(etc) ) thankee david! :) --Hawke'
5. Re: Win32 problems
- Posted by Davi Figueiredo <davitf at USA.NET> Dec 19, 1998
- 323 views
- Last edited Dec 20, 1998
I believe the error in my program is because I am creating the menus immediately after creating the window. Here's what I did: constant MainWindow = create( Window, "The name of the game", 0, Default, Default, 64*length(GameToPlay)+2, high*64 + 64, constant -- Create menus File_Menu=create(Menu,"&File",MainWindow,0,0,0,0,0), File_NewGame=create(MenuItem,"&New game",File_Menu,0,0,0,0,0), File_Hint=create(MenuItem,"&Hint",File_Menu,0,0,0,0,0), File_Exit=create(MenuItem,"E&xit",File_Menu,0,0,0,0,0), Help_Menu=create(Menu,"&Help",MainWindow,0,0,0,0,0), Help_HowToPlay=create(MenuItem,"How to &play",Help_Menu,0,0,0,0,0), Help_About=create(MenuItem,"A&bout",Help_Menu,0,0,0,0,0) -- Create Text Box constant TextBox = When I removed all references to menus in my program (so it doesn't create them any more) the problem seems to have disappeared. I ran it about... don't know, 50 times, maybe more... and it didn't crash a single time. When I ran the old one, it crashed sometimes. What do you think, is this the problem? I could change the code to create the menus after the window is loaded, but I don't feel like doing so unless it's necessary... Changing the subject a little, I use setEnable to enable/disable a menu item. I found a very strange thing (at least for me): when I use setEnable(File_Hint,MF_DISABLED) the item becomes enabled and when I use setEnable(File_Hint,MF_ENABLED) it becomes disabled! Is it really supposed to be like that? Regards, Davi Figueiredo davitf at usa.net ____________________________________________________________________ Get free e-mail and a permanent address at http://www.amexmail.com/?A=1
6. Re: Win32 problems
- Posted by "Cuny, David" <David.Cuny at DSS.CA.GOV> Dec 21, 1998
- 345 views
Davi Figueiredo wrote: > I believe the error in my program is because I am creating > the menus immediately after creating the window. I suspect the problem has to do with the bug fix I posted the other day. Could you make the correction to create() and see if that takes care of it? > Changing the subject a little, I use setEnable to enable/disable > a menu item. I found a very strange thing (at least for me) ... setEnable expects a truth value (0 or non-zero), not MF_ENABLED or MF_DISABLED. Hope this helps! -- David Cuny
7. Re: Win32 problems
- Posted by Davi Figueiredo <davitf at USA.NET> Dec 21, 1998
- 336 views
- Last edited Dec 22, 1998
David Cuny wrote: > I suspect the problem has to do with the bug fix I posted the other day. >Could you make the correction to create() and see if that takes care of >it? I had already done it and it didn't work. Anyway, I think the bug fix was necessary to avoid another problem with the game (I use many scroll bars in the configuration program and such). That's why I included win32lib.e with the game. >setEnable expects a truth value (0 or non-zero), not MF_ENABLED or >MF_DISABLED. Thanks, now I see it. I will correct this soon in the game. I should have thought of that in the first place... >Hope this helps! It sure did! Sorry for not replying earlier, I hadn't seen your message in the listserv page... Regards, Davi Figueiredo asdavitf at usa.net ____________________________________________________________________ Get free e-mail and a permanent address at http://www.amexmail.com/?A=1
8. Re: Win32 problems
- Posted by David Cuny <dcuny at LANSET.COM> Dec 21, 1998
- 350 views
- Last edited Dec 22, 1998
Davi Figueiredo wrote: > ... That's why I included win32lib.e with the game. Win32Lib and Dos32Lib are in a constant state of flux; code that runs in one version quite often breaks in the next. I'd suggest *always* including the version of the libraries you are coding to. You might want to offer an EXE only version of your program for people who run across your web pages looking for games, but don't want to bother with downloading Euphoria. -- David Cuny