Please login or register.

Login with username, password and session length
Advanced search  

News:

This forum provides RSS feed. To query recent posts use this url. More...


Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.

Messages - Daniel

Pages: 1 ... 7 8 [9]
121
Technical forum / Responses Window
« on: April 13, 2004, 04:51:43 PM »
Hi All,

I made a sliding inventory bar at the bottom of the screen and I wanted to do the same thing for the dialog bar. The problem is that I searched the documentation and couldn't find any way of obtaining a reference to the responses window like there is for the inventory window (the GetInventoryWindow() method). I need this window in order to play with it's on-screen position.

My final goal is that each time the GetResponse() method is called, the responses (icon-based) will slide up from the bottom of the screen.

Did I miss something? Isn't there a GetResponsesWindow() anywhere?

122
Technical forum / Re:Hello & Crash Problem
« on: April 12, 2004, 01:49:03 PM »
Regarding the "walk-behinds", well, if the way I suggested has serious negative repercussions at runtime, I guess it's beginning to look less appealing even to me. I wasn't aware of the two issues you brought up and I'm certainly no expert in the ability of the z-buffer method to use semi-transparent objects or in the performance problems of the way I suggested of doing things, but I'll take your word on that. It would seem your arguments are somewhat stronger than mine so forget about this all issue...

About the crash, I did go back to a minimal configuration and then started to add things one by one. The problem now is that there is more than one catalyst to the crash. In fact, I've so far detected three different things in my code that upon commenting them out (each one by itself), the crash disappears. So if each one of these three actually works by itself but has difficulty working in conjunction with the other two, logic dictates that there is nothing wrong with each one of them in itself. And since the three I'm referring seem virtually unrelated to each other, it must be that one of them is messing with the memory of another. If that's the case, and since I'm working inside the script-sandbox and thus not allocating/deallocating/accessing any memory directly, it must be the engine doing that. Am I correct in this assumption?

The three things I'm referring to are:

1. I use Game.LoadEntity() to load an "Options" button at the beginning of game.script.
2. At least three responses are visible during a conversation I'm conducting.
3. The inventory contains five items. Nothing more and nothing less. Exactly five.

If all the above come to happen, when I click on the first response during the mentioned conversation, the game crashes. If I click any of the other responses, everything's ok.

Bottom line is that regarding your kind offer of running my test-case yourself under your debugger, Mnemonic, if, given the behavior I described, you think I'm correct in my deduction that it could be that I surfaced an engine bug, I think you should indeed look into it. If, on the other hand, you think the problem could still be in the script realm and therefore my responsibility, then I won't bother you with it. I think you have enough to do as it is without debugging games of every newbie that comes into the forum...

123
Technical forum / Re:Hello & Crash Problem
« on: April 12, 2004, 01:10:22 AM »
Hi MMR and Mnemonic and thanks a lot for the super-quick responses!

Regarding the wme.log file, I didn't mention it before because the problems I'm referring to are really beyond its scope, but I do know it very well by now and I use it myself with the Game.LOG() method. You're correct regarding this file appropriately logging problems such as missing/misspelled files and in such cases it logs everything needed to repair the problem.

In the specific case I'm referring, it logs no such info. The engine crashes even without properly closing the file. The last entry in the file is the "Data initialized in x ms" and the normal closing lines:

Shutting down...
Shutting down scripting engine
********** DEBUG LOG CLOSED ********************************************

are *not* there at all.

I did notice the file wme_crash.txt is created in such cases. The thing is that although I used to crack copy protections when I was younger (and dumber...) and I knew the 80x86 instruction-set and registers very well back then, these days (more than ten years later) a dump of the registers and a stack trace of a module I never saw its source code, right after an access violation crash, really tells me absolutely nothing... I guess this file was intended for you, Mnemonic, for debugging the engine and not for the rest of us debugging the games.

As for the "walk-behinds", I still think there's not much difference in painting them, compared to cutting out parts of the background and placing them into scene as separate objects. Or were you talking about something else?

I was talking about exactly that. All I'm saying is that if something is already there, there is no point in putting it there again. Just like you use region entities for hotspots and not sprite entities (with the same image that is already drawn on the background), I think you should use region entities and not sprite entities for the "walk-behinds" as well. If needed, they might have an additional property or something for stating what they really are. And, of course, they will be affected by the z-order specified in the node view. I'm just against having to maintain the same image twice. Suppose I decide to change the color of something in the background image and I forget I'm also using that part of the background as a sprite entity for the walk-behind mechanism. Here is a bug waiting to happen. I know this rule from the world of writing code: Never hold copies of the same piece of code in more than one place. Always make a function of that piece of code and call it from wherever you need it. That way, if you need to change something in that code, you change it only in one single place.

That said, I'm not implying that my logic is, in any way, better than yours (or anybody else's, for that matter). This is just the way I think the "walk-behind" mechanism should be implemented, but I'd still love this engine even if it stays just the way it is. And except this small issue, the SceneEdit tool is way better than the one used in AGS, in my opinion.


124
Technical forum / Hello & Crash Problem
« on: April 11, 2004, 07:33:26 PM »
Hi there all forum members.

I started using WME about a month ago after seeing a post from Marek at his own forum at adventuregamers.com regarding this engine. Till then I had been testing AGS for about two months. Since AGS is a very good and flexible engine I wouldn't normally be seeking to replace it but I had a very big problem with its code management system. It has one global script, one global header and one script per location/room/scene. That's it. I've been writing code for years now and I know that managing your code successfully in large-scale projects is absolutely critical. I've been only testing it and already I became lost in all the functions I coded into these few files. What would it be like with a full-scale game?

Another thing is that the scripts in AGS are not simple text files but instead they are saved in binary form together with the rest of the game/locations data. This way it is very difficult to keep them under any kind of source control software as is customary with big projects having multiple people working on them.

Last thing, it was extremely painful for me to go back to the old pre-object-oriented days. A bunch of functions crammed together in a few files is not my idea of good coding practice anymore...

As it is, I tried WME after reading Marek's post and fell in love with it. It's object-oriented and I can manage my code in virtually any way I like. And the source files are, as they should always be, text based.

There are a few things that AGS accomplishes better than WME (e.g. the walk-behinds in the scenes - can't something be done about it?) but overall, WME is, by far, my choice.

One thing bothers me, though, and that's the stability of the engine. I managed to crash the engine quite a lot with my tests. Most of the time it was my fault, of course, but still, the engine just crashed without any clear explanation of the problem. I had to start guessing that some control's definitions crash the engine if the text alignment of the control is written with double quotation marks or not (i.e. left as opposed to "left" or vice versa) and this is only one small example.

Most of the time I manage to solve all these things eventually but I'm stuck now with a weird crash when my game loads a certain entity (with LoadEntity), my inventory has at least five items (doesn't matter which), and my dialog with a certain NPC has at least three responses. If all that is true, when I choose the first (and only the first) response during the conversation with the above-mentioned NPC, the engine crashes. Go look for the source of the problem now with no debugger and no programs like BoundsChecker or Purify. I'm sure many of you are thinking that I'm making this up but I'm not, really. It's true that all the things I mentioned as leading to the problem are virtually unrelated to each other at all, but in the low level, if any of them has a bug and it writes onto the memory space of another (which is really common when coding in C++, for instance), then bang, it blows up in your face.

Now I'm not sure this is a memory buffer overrun bug in the engine or just yet another stupid mistake made by yours truly, but if the game crashes instead of giving a clear error, how am I supposed to find the problem?

Am I the only one with this kind of problem? Does anyone have any experience with such problems and can guide me in ways of dealing with them?

Last note, I know it's my first post here and all I've done is criticizing the engine. Well, just for the record, I think that in spite of its temporary shortcomings, WME might as well be the best engine out there for adventure games and Mnemonic has done quite an elegant piece of work here and thus earned my deepest respect. I know and understand very well that this engine is a work-in-progress and as such, bugs are an inherent part of it. Software needs time and a lot of versions to become ripe somewhere in the future.

How's that for a first post? I planned to just say hello and maybe ask some question and look what happened...

Pages: 1 ... 7 8 [9]

Page created in 0.024 seconds with 23 queries.