Menu

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.

Show posts Menu

Messages - ZakMcKracken

#1
Completed Game Announcements / Re: The Castle
Thu 29/08/2019 11:01:21
Quote from: Carles on Wed 28/08/2019 18:03:50
In Steam it has been positively received. All reviews are good. I invite you, if you have played, to write one even if it is bad  :P

We are discussing your game (and exchanging gameplay information as well) in a dedicated topic on the Thimbleweed Parkâ,,¢ forum.
Thimbleweed Park is the latest adventure game released by Ron Gilbert, David Fox and Gary Winnick -- you should be familiar with them :-)

If you want to join in, you are welcome of course!
https://forums.thimbleweedpark.com/t/the-castle-game-inspired-by-maniac-mansion
#2
Completed Game Announcements / Re: The Castle
Wed 28/08/2019 08:26:36
Hello,

I just came here to congratulate to the author of The Castle.
I'm playing it, it really brings back memories to the first Maniac Mansion, you did a good job.

I think your game will become more popular than you can imagine. Am I wrong, dear Nor Treblig? ;-)

SEE YA!
#3
Quote from: Cluey on Mon 30/01/2006 12:32:16
Whoa, the graphics remind me so much of CMI.  Good job.
Hello Cluey,
we were inspired from Monkey Island saga, of course. Thank you for your comment!

Regards
#4
Hello,

I'm here with my friend Vale.

Quote from: ildu on Wed 25/01/2006 22:24:03
Looks awesome. Are you distributing this to any environment protection organizations? And how long a game are you going for? The progress percentages promise quite a lot.
Thank you very much, ildu. Our intention is to distribute our game through environmental organization. If you want to watch, please visite our site (http://www.woaky.com), "Distribution" section.
The game is quite long, it has about 30 rooms and many puzzles, of different difficult to solve, and there are some nice cutscenes.

Please wait until we are able to release a playable demo (april - may 2006).

Regards
#5
Here we are...

site of Woaky project open!

Please take a look on the story of this adventure in progress:
http://www.woaky.com

comments and suggestion are always welcome of course (even correction of english errors)!

Thank you
Woaky project staff
#6
Vale,

when you programmed in C/C++, you never put brackets after a return :-)
It's a common rule!
You ashamed!  ;D

(me and Vale are friends, this is not a flame)

Thank you AGS crew!
#7
Hello SSH,

thank you very much for your help. I downloaded source code of your game, you are great!
First of all, because you produced 2 distinct modules, and second... it works perfectly!

Thank you everybody.

Regards.
#8
Thank you very much, Gilbot.

I defined a DynamicSprite* variable outside my functions, and used CreateFromScreenShot and CreateFromSaveGame to set and load screenshots.

Then I set that variable to null, so the allocated memory can be freed.

Now it works.

Well, I just test it and as soon as possible I'll make a tutorial, to create a Save/Load GUI with screenshots using AGS 2.7

Regards
#9
Hello,

wow, Gilbot, what a speedy!! :D  I just came in to add further information to my case.

When I compile the original code with AGS 2.7, the game crashes when attempting to execute the following line:
Code: ags

if (sgs_struct[i].spr != SGS_EMPTY_SPRITE) DeleteSprite(sgs_struct[i].spr); //SGS_EMPTY_SPRITE is defined as 139, which is a sprite in the library with a picture saying "Empty slot"

with the message "Attempted to free a static sprite that was not loaded by the script".
Same code, in AGS 2.62, works fine.



In conclusion, the differences betweeen 2.62 and 2.7 (executing the same code):

Code: ags

SaveGameSlot(100, "temp"); // Save current game in temp slot
sgs_struct[0].spr=LoadSaveSlotScreenshot(100, SGS_WIDTH, SGS_HEIGHT); // load up screenshot
DeleteSaveSlot(100); // Delete temporary slot
...
SetButtonPic(SAVELOAD, button, 1, sgs_struct[0].spr); // change selected button to have current game screenshot
...
int i=0;
while(i<=6) 
  {
  if (sgs_struct[i].spr != SGS_EMPTY_SPRITE) DeleteSprite(sgs_struct[i].spr);
  i=i+1;
  }


...with AGS 2.62 everything is allright:
  • Loads a sprite number into sgs_struct[0].spr
  • Sets the image when I first click on the button
  • Deletes the sprite from sgs_struct[0].spr

    ...with AGS 2.7 something is wrong:
  • sgs_struct[0].spr is 0
  • There is no image in the button
  • When attempting to delete sgs_struct[0].spr (which value is 0), it crashes with the error "Attempted to free a static sprite that was not loaded by the script".

    Hope this could be useful.

    Thank you everybody!
    Regards
#10
Hello everybody,

Now I have understand, but there is just one more thing that puzzles me.

In AGS 2.62, the following lines...
Code: ags

SaveGameSlot(100, "temp"); // Save current game in temp slot
sgs_struct[0].spr=LoadSaveSlotScreenshot(100, SGS_WIDTH, SGS_HEIGHT); // load up screenshot
DeleteSaveSlot(100); // Delete temporary slot

...work fine: in sgs_struct[0].spr there is a value.
In fact, the subsequent instruction:
Code: ags

SetButtonPic(SAVELOAD, button, 1, sgs_struct[0].spr); // change selected button to have current game screenshot

works fine as well: in my button, I see the picture.

Same code, compiled with AGS 2.7: when I click on the button, it shows me anything, and the game crashes. It seems it can't load the sprite from the temporary saved game slot.
The option "Save screenshot in save game" is checked.

Well, I changed the above lines as follow:
Code: ags

SaveGameSlot(100, "temp"); // Save current game in temp slot
DynamicSprite* spr = DynamicSprite.CreateFromSaveGame(100, SGS_WIDTH, SGS_HEIGHT);
sgs_struct[0].spr=spr.Graphic;
spr.Delete();
DeleteSaveSlot(100); // Delete temporary slot

...and when the code is executed in the game, it crashes with the error: "null pointer referenced", and the line number indicates the assignment: "sgs_struct[0].spr=spr.Graphic;".

I checked again the option "Save screenshot in save game"... and it's turned on.

I could suppose there is a bug in SaveGameSlot function, but I don't think so: if I run the game with the original lines of code (that is using LoadSaveSlotScreenshot), the game crashes the first time I try to save, but if I run the game again, and try to save, I see a picture in a slot. So, I assume that a sprite as been saved with the slot.

I don't know... it seems like the slot 100 is unpleasant to AGS :-)
Can someone try to see if SaveGameSlot(100, "temp") saves the screenshot correctly?

Thank you
#11
Hello Monkey,

no, no, I am trying to translate into the new object-oriented style. So, every clue is welcome  :)

I use the old style just to better understand the concepts and logic, but my final goal is to make a game enterely object-based.

Regards
#12
Hello Pumaman,

you are right, mistery solved. It was the "Enforce object-based scripting" option!

Thank you.
#13
Hello monkey,

thank you for your support.
Unfortunately, the compiler says "ID is not a member of spr". I tryed to write it in lowercase, too.

Anyway, I attempted a workaround.
I loaded AGS 2.62 in a separate directory, and created the Save/Load GUI according to the tutorial.
Everything works fine  :=
So, I saved everything, then I loaded AGS 2.7, and loaded my game with the new GUI.

The room conversion has been applied, as usual, and when I look into the Global Script to see if something has changed, I surprisingly notice that everything was untouched!  :o
There are "LoadSaveSlotScreenshot" function calls, and... they works! The compiler compiles the game, and when I test it, it works. The screenshots appear.

I can't figure out why, yesterday, the compiler told me "undefined symbol LoadSaveSlotScreenshot'"...

Well, to be honest, there is a little thing that doesn't work: the very first time I save a game, it crashes indicating that I attempted to delete a sprite that was not allocated.
But the game saves correctly in its slot.
Then, every time I run the game, and save, everything is right.

Maybe it could be useful to change all obsolete functions into the new logic; if I succeed in, I'll post the changes.

Regards
#14
Hello,

I'm creating a new Save/Load GUI with screenshots.
Since I haven't created one before, I looked for a good tutorial, and found this one:
http://www.twin-design.com/agsezine/9/tutorial.cfm
(this is Scripting Tutorial By Andrew McCormack)

It says the tutorial will present how to make a load/save game dialog that uses the new "save games with screenshots" feature of AGS v2.6 onward.

Well... I'm using AGS 2.7, I did the tutorial step-by-step, but when I save the game, the compiler stops with message "undefined symbol LoadSaveSlotScreenshot'":
Code: ags

function sgs_getslots()
{
int i=1;
while(i<=6) 
	{
	if (GetSaveSlotDescription(i, sgs_struct[i].t)) 
		{
		sgs_struct[i].spr=LoadSaveSlotScreenshot(i, SGS_WIDTH, SGS_HEIGHT);
		} 
	else
		{
		StrCopy(sgs_struct[i].t, "");
		sgs_struct[i].spr=SGS_EMPTY_SPRITE;
		}
	SetLabelText(SAVELOAD, 6+i, sgs_struct[i].t); 
	SetLabelColor(SAVELOAD, 6+i, SGS_LABEL_COLOUR); 
	SetButtonPic(SAVELOAD, i, 1, sgs_struct[i].spr);
	i=i+1;
	}
Wait(1); 
SaveGameSlot(100, "temp"); 
sgs_struct[0].spr=LoadSaveSlotScreenshot(100, SGS_WIDTH, SGS_HEIGHT); 
DeleteSaveSlot(100); 
}


Well, the help file says that LoadSaveSlotScreenshot is obsolete, and suggests to use DynamicSprite.CreateFromSaveGame

I tried, but with no success. I changed the int to DynamicSprite*, but it doesn't compile.

Can someone clarify the concepts?
I think the tutorial is very very good, maybe it could be more useful fix the tutorial to make it compatible with AGS 2.7

Thank you.
SMF spam blocked by CleanTalk