WIP – A Tower Defense Tutorial for Stencyl 2.0

publysher

  • Posts: 41
OK, I found the first problem. Your "make [self] spawn actor of type [type]" states that "Type" is an Actor Type – however, we are giving it Text; the result is that Stencyl tries to convert the text "A" to an actor type, but there is no such actor type.

I have updated part 6 – it now shows the "Create Custom Block" dialogs for every custom block.

- publysher
Awesome. Thanks. :) Is there any way to edit a custom block or do I have to delete and start again?

Yes, editing a custom block is possible, but it's tricky (@Stencyl girls & guys: this should be easier ;-) )

Go to the Palette and click on Custom – there you can see all your custom blocks. Find the block you want to edit and right-click on it. Now you get the option to edit your custom block.

publysher

  • Posts: 41
As for that block, I deleted the old one and created a new one, I now don't get the error but no enemies get spawned at all.

Deleting blocks also deletes the original calls to the block – so make sure your "make [self] spawn the enemies defined in [definition]" block still calls the "make [self] spawn enemy of type [type]" block.

CrimsonThunder

  • Posts: 96
OK, I found the first problem. Your "make [self] spawn actor of type [type]" states that "Type" is an Actor Type – however, we are giving it Text; the result is that Stencyl tries to convert the text "A" to an actor type, but there is no such actor type.

I have updated part 6 – it now shows the "Create Custom Block" dialogs for every custom block.

- publysher
Awesome. Thanks. :) Is there any way to edit a custom block or do I have to delete and start again?

Yes, editing a custom block is possible, but it's tricky (@Stencyl girls & guys: this should be easier ;-) )

Go to the Palette and click on Custom – there you can see all your custom blocks. Find the block you want to edit and right-click on it. Now you get the option to edit your custom block.
Wow, you know everything! :P
As for that block, I deleted the old one and created a new one, I now don't get the error but no enemies get spawned at all.

Deleting blocks also deletes the original calls to the block – so make sure your "make [self] spawn the enemies defined in [definition]" block still calls the "make [self] spawn enemy of type [type]" block.
It works! You're a legend. :D

Xietao

  • Posts: 725
I forgot a thing.
I had got the error with the same code as you code, I get the error.
Sorry for this English, I don't know which words I need to use  :-[
Free Time:
Monday, Wednesday, Friday: 13h
Tuesday, Thursday, Saturday, Sunday: 7h
Loving Linux...

Xietao

  • Posts: 725
But when use you copy code it works great! Why?
Free Time:
Monday, Wednesday, Friday: 13h
Tuesday, Thursday, Saturday, Sunday: 7h
Loving Linux...

publysher

  • Posts: 41
But when use you copy code it works great! Why?

Hi Xietao,

If copy works, there must be a tiny difference between your own code and mine – please re-check part 6 where I've added the "Create Custom Blocks" screenshots and check the exact version of your Block Fields.

As for your English: keep reading and posting, it's the best way to learn – that's how I did it :)

- publysher

CrimsonThunder

  • Posts: 96
But when use you copy code it works great! Why?
As Publysher said here:
OK, I found the first problem. Your "make [self] spawn actor of type [type]" states that "Type" is an Actor Type – however, we are giving it Text; the result is that Stencyl tries to convert the text "A" to an actor type, but there is no such actor type.

I have updated part 6 – it now shows the "Create Custom Block" dialogs for every custom block.

- publysher

One of the types had the properties, heres what it should be like:


And don't worry, your English is fine. :)

Xietao

  • Posts: 725
But when use you copy code it works great! Why?

Hi Xietao,

If copy works, there must be a tiny difference between your own code and mine – please re-check part 6 where I've added the "Create Custom Blocks" screenshots and check the exact version of your Block Fields.

As for your English: keep reading and posting, it's the best way to learn – that's how I did it :)

- publysher
Yes, it got the same at all.
Free Time:
Monday, Wednesday, Friday: 13h
Tuesday, Thursday, Saturday, Sunday: 7h
Loving Linux...

Xietao

  • Posts: 725
:o You changed you icon.
Free Time:
Monday, Wednesday, Friday: 13h
Tuesday, Thursday, Saturday, Sunday: 7h
Loving Linux...

publysher

  • Posts: 41
In that case: can you upload your game to StencylForge? I'll have a look at it.

Daedalon

  • Posts: 7
I have updated part 6 – it now shows the "Create Custom Block" dialogs for every custom block.

Excellent! I opened this thread today to ask for this very thing, but you guys beat me to it.

- I appreciate that not everyone would like to use StencylForge. However, I believe that StencylForge is actually one of the most powerful parts of the Stencyl experience. Therefore, I will no longer post Resources online as it's too much of a hassle for me.

In this case the tutorial could benefit from a short paragraph of marketing speech of why it's worth it to register to StencylForge if the reader hasn't done it already. Crash Courses 1 and 2 used only resources that were distriuted within Stencyl 2.0, so this hopefully-to-be Crash Course 3 is the natural place for many new Stencylers to even think about the whole amazing StencylForge for the first time. Something along these lines might do:

"In this part of the tutorial we start taking use of StencylForge, which is one of the best things about Stencyl. We use it to download a free tileset to make our game look more interesting without ever leaving the friendly user interface of Stencyl. You can later explore StencylForge to find more resources like music and graphics to use in your games and example games to play and learn from. If you don't have a Stencyl account already, Stencyl will ask if you want to make one when you attempt to download a resource. Making an account takes only one minute and having one is required for downloading resources from StencylForge. We'll be using StencylForge also in the following parts of the tutorial."

Thought this was superb. Love this tutorial!

CrimsonThunder

  • Posts: 96
Just completed tutorial 7, I've come across a very strange bug.. Everything goes great until I choose the tower and then the buttons slide across the screen instead of going back to the original position...

I've uploaded it to StencylForge (Tower Defense Game) I replaced the last version on there.

Edit: So I exported your version of Three Button Fan and Create Tower Behavior and it worked. But still would like to know what I did wrong.

« Last Edit: May 28, 2012, 09:30:59 pm by CrimsonThunder »

CrimsonThunder

  • Posts: 96
Also not sure if you've noticed yet, but if you let the enemies make it to the end some of them go back to a certain position and start the loop again. This could easily be fixed in a "kill actor when leaving the screen and minus ___ points" thing you'll probably add in, but just thought I'd mention it just in case.

This problem seems to happen a lot more in my game, but then again I'm having heaps of problems lol.

(screenshot is from your tutorial version 8 )

Xietao

  • Posts: 725
Also not sure if you've noticed yet, but if you let the enemies make it to the end some of them go back to a certain position and start the loop again. This could easily be fixed in a "kill actor when leaving the screen and minus ___ points" thing you'll probably add in, but just thought I'd mention it just in case.

This problem seems to happen a lot more in my game, but then again I'm having heaps of problems lol.

(screenshot is from your tutorial version 8 )
Do you check "Loop" Boolean?
Free Time:
Monday, Wednesday, Friday: 13h
Tuesday, Thursday, Saturday, Sunday: 7h
Loving Linux...