Beginners need help

Need help with using DizzyAGE then look here
Kalle Neumann
Your Backpack is Empty
Posts: 14
Joined: Sat Jan 18, 2020 5:16 pm

Beginners need help

Post by Kalle Neumann » Sat Jan 18, 2020 6:45 pm

Hello everybody,

I signed up here, hoping that someone can give me programming help with dizzyAGE.

Code: Select all


        }
        
	SamplePlay(FX_SUCCESS);
	Message1(0,4,"\"HERE IS YOUR KEY,DYLAN.\nBE MORE CAREFUL NEXT TIME\""); 
	MessagePop();
	Message2(8,2,"\"THANKS DIZZY!\nI PROMISE I WILL.\""); 
	MessagePop();
	InventorySub(idx);
	ObjSet(objidx,O_STATUS,2);
	ObjSet(objidx,O_X,2886);
	ObjSet(objidx,O_Y,504);
	ObjSet(objidx,O_TILE,188);  // happy
        }

I tried to copy the code from another game (thanks at this point for a password-free unpacking) :tup:
It works as far as well only with me dylan "... TILE, 188" is only shown half. it is cut off on the right. I tried another TILE - the same... :v2_dizzy_confused2:
I would be grateful for any solution.
Best regards from Germany
Kalle

Grandad
Hard Boiled Egg
Posts: 1543
Joined: Sat Aug 08, 2009 10:47 am
Location: Balham - gateway to the south

Re: Beginners need help

Post by Grandad » Sun Jan 19, 2020 8:44 am

Not sure what you're trying to achieve but assume that having given Dylan a key you're changing the 'picture' of Dylan from sad to happy.

If so, then you need to identify the tile you're moving before setting the new coordinates ...and check that the layer is correct as having a new tile appear that has a lower layer number than part of the scenery layer number, the new tile will be partly or wholly obscured by the scenery. Also, if moving a dynamic tile into the room you're currently in it's best to add an ObjPresent(idx) command or whatever the tile's tag is, to update the game.

However, it's a lot easier to have both pictures of dylan already on the map, and just disable the happy tile so that when the key is given you just have to use the commands:

ObjSet(ida, O_DISABLE, 1); ObjSet(idb, O_DISABLE, 0);

providing that at the start of the specific function you have set the tags ie
ida = ObjFind(400); //tile of Dylan sad
idb = ObjFind(401); //tile of Dtylan happy.

Also, a good idea is to have a look at Delta's videos of basic game construction - if they're still on this site. Are they Adam?

User avatar
Adz.M
Team Yolkfolk
Team Yolkfolk
Posts: 3050
Joined: Tue Jan 16, 2007 7:43 am
Location: Cornwall, UK
Contact:

Re: Beginners need help

Post by Adz.M » Sun Jan 19, 2020 4:31 pm

Welcome Kalle. :)
Grandad wrote:
Sun Jan 19, 2020 8:44 am
Also, a good idea is to have a look at Delta's videos of basic game construction - if they're still on this site. Are they Adam?
My knowledge on the engine is not too great, but the DizzyAGE site itself has an articles section to help first time programmers.
:egg: http://www.yolkfolk.com/dizzyage/articles.html

The "Videos" tab has a list of tutorials showing the coding basics of DizzyAGE.

Also the "Tech Demos" tab has the "Make Your Own Dizzy Game" step by step guide which I'm sure also covers character conversations.

I'm not sure which DizzyAGE games you tried to unpack, but most of Jamie Douglas' games can be unpacked for educational purposes.

Apologies if this isn't what you're after.
Image

Kalle Neumann
Your Backpack is Empty
Posts: 14
Joined: Sat Jan 18, 2020 5:16 pm

Re: Beginners need help

Post by Kalle Neumann » Sun Jan 19, 2020 8:28 pm

Thank you for the quick answers and a hello to you back :)
Not sure what you're trying to achieve but assume that having given Dylan a key you're changing the 'picture' of Dylan from sad to happy.
Not sure what you're trying to achieve but assume that having given Dylan a key you're changing the 'picture' of Dylan from sad to happy.

Yes, that was exactly what I wanted to achieve.
The code comes from the game "Mushroom Pie".
I took a closer look at this in the map editor and found that the Dylan tiles were stored there separately. That was also the mistake. I had taken Dylan from yolkfolk.tga.
Now it worked and I am thrilled.
Now I'm going to try your solution Grandad. Since I want to continue to speak to Dylan :v2_dizzy_confused2:
ObjSet(ida, O_DISABLE, 1); ObjSet(idb, O_DISABLE, 0);

providing that at the start of the specific function you have set the tags ie
ida = ObjFind(400); //tile of Dylan sad
idb = ObjFind(401); //tile of Dtylan happy.
Hello Adz.M. For some time now I have been browsing through the GS9 and Dizzy AGE books as well as this forum. Play various DizzyAGE games (which can be unpacked without passwords) to understand which solutions have been used.

Best regards
Kalle (not Adam) :v2_dizzy_confused3:

PS: Sorry, I have to admit that my programming skills are the same as my English skills. (google translate is my best friend)

Grandad
Hard Boiled Egg
Posts: 1543
Joined: Sat Aug 08, 2009 10:47 am
Location: Balham - gateway to the south

Re: Beginners need help

Post by Grandad » Mon Jan 20, 2020 10:11 am

Glad we were able to help Kalle.

When I made my very first game (the original Daisy goes Solo from 2009, not the 2018 version) I knew nothing about 'proper' programming, so in the Game.GS file I actually included written details of everything I did, including things that could go wrong, If it helps, download the game and unpack it.

I should warn you that at that time I knew nothing about 'tags' so every command is on the lines of ObjGet(ObjFind(xxx), rather than ObjGet(ida, etc.

Hope Google is up to translating it :v2_dizzy_cheers:

PS - Adam is AdzM's proper name.

Kalle Neumann
Your Backpack is Empty
Posts: 14
Joined: Sat Jan 18, 2020 5:16 pm

Re: Beginners need help

Post by Kalle Neumann » Mon Jan 20, 2020 8:45 pm

Hello everybody,
good evening grandad :v2_dizzy_cheers:
Google Translate was gracious and translated everything fine.
I played your game and it is very good and fun. I can not judge whether it is well and correctly programmed. It works and that's the main thing, isn't it?
In room "edge of the hill" I noticed that I could just take a hidden coin from the billy goat. was that what you intended?
I'm currently trying to create a similar puzzle, but unfortunately I can take my hidden coin beforehand without having solved the puzzle.
First I made it invisible. Did not work. Then hidden behind a black square which disappears after completing the puzzle. doesn't work either.
The aim is to knock over a barrel to find or take the coin behind it. :v2_dizzy_confused2:
I will try again and get in touch again with this or other problems.

Best regards
Kalle

Grandad
Hard Boiled Egg
Posts: 1543
Joined: Sat Aug 08, 2009 10:47 am
Location: Balham - gateway to the south

Re: Beginners need help

Post by Grandad » Tue Jan 21, 2020 10:56 am

Kalle, just give the coin an id number and set it as disabled (just like any other hidden object) but still give it a class of 'coin'

Then when the puzzle is solved add the line

ida = ObjFind(444) //id of disabled coin
ObjSet(ida, O_DISABLE, 0); //make the coin visible

You need the id number so that the engine knows what object to make visible and available. Once the coin is visible and active then it can be picked up as normal.

Kalle Neumann
Your Backpack is Empty
Posts: 14
Joined: Sat Jan 18, 2020 5:16 pm

Re: Beginners need help

Post by Kalle Neumann » Tue Jan 21, 2020 7:48 pm

Good evening everyone,
Hello Grandad, thank you for your active support :v2_dizzy_cheers:

I didn't get it straight away and wrote a novel here. until I saw the "disable" option in the editor that you mentioned. Blindness. :cool:
What is the difference between ida and idx? both seem to work.
The puzzle works now and I am very happy with it. now i have some time to continue playing your game. :tup:

Best Regards

Kalle

Grandad
Hard Boiled Egg
Posts: 1543
Joined: Sat Aug 08, 2009 10:47 am
Location: Balham - gateway to the south

Re: Beginners need help

Post by Grandad » Wed Jan 22, 2020 9:43 am

Kalle, There's no difference between 'ida' and 'idx' ...or whatever you want to call a tag. All that matters is that the tag identifies a specific object/brush in the function being used. Just remember that tags have to be identified in each separate function before using them in a command.

I like to use different tags as some of my functions can involve up to a dozen different objects being manipulated and find it easier to have different tags for each object when checking for errors. Also, it saves typing ObjGet(ObjFind(xxx), all the time and making your fingers tired :v2_dizzy_cool:

Some people only use 'idx' for object tags, but that's only convention. Do what works for you is what I say :tup:

Kalle Neumann
Your Backpack is Empty
Posts: 14
Joined: Sat Jan 18, 2020 5:16 pm

Re: Beginners need help

Post by Kalle Neumann » Thu Jan 23, 2020 7:56 pm

Hello everybody,
Good evening Grandad, :v2_dizzy_cheers:
ok, good to know and a good idea to keep an overview.
I saw a list of your games here in the forum and was surprised how many there are. :shocked: Hats off! :tup:
Which one have you been working on the longest?
I'm trying to remake in the original C64 style (call me an outsider BUT my first computer was a C64 and my first pirated version of Fantasy World Dizzy - my heart depends on it) :v2_dizzy_blush:
So, I will continue to tinker and try ... there is enough to do.

Best regards

Kalle

Post Reply