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 - dubealex

Pages: 1 2
16
Okay, I am currently trying to find a solution for this, maybe the only way is via code blocks, but I'm posting this in case somebody already have a solution:

First of all:
I have no problem when using the game attribute of type list directly, of course. My problem is when I create a behavior attribute of type game attribute, so the user can choose a game attribute he created that is of type list to store the IDs.

The situation:
I need a game attribute to store permanent changes for some actors, values are state ID varying from 1 to 7. So the game attribute is a list. I create a behavior attribute of type Game Attribute. Now, I need to be able to use that behavior attribute in the LIST blocks, but I can't, since stencyl don't see it as a list.

If there would be a "Anything as list" or a "Threat as list" block, all this would be easy.
I tried creating a hidden behavior attribute of type list, and storing the behavior attribute of type game attribute in it, but it is the same problem that stencyl don't see this attribute as a list and I can't make it see it as one.

A solution?:
Any ways to make a behavior attribute of type Game Attribute be seen as a list ?


17
Ask a Question / Re: Gravity
« on: July 17, 2011, 04:37:50 pm »
I have a working gravity reversing features in my game Blockz.

But it's really not an easy task, since you have to manually modify all the behavior that takes into account X, Y position and velocity. I had to edit all moving, walking, and jumping behaviors, plus all my custom behaviors I created to interact with block.

I can't really explain A to Z how to acomplish it, don't have the time or the will to do so right now, maybe later. But here some hints:

- create a game attribute for the gravity, change it when you change gravity
- Change the gravoty of the scene
- Create a region, and make actors in that region rotate
- Add all the Ifs you need in all the behaviors that manages moving around and positions.
- You need to reveer X,Y and Positive and negative accordingly.

You can play a demo of blockz, you can see a gravity reversing feature in effect in the second level.

to play it.:
http://www.stencyl.com/game/play/3700

18
Thanks, I get it now, and it did work by setting it as "local" and attaching to the scene. Now actors from the scene can use that block in their behavior.

19
I never created custom blocks yet, and I'm trying to make one for this, and I'm going to try make more custom blocks in the future. But once I put the code "removeRegion" into the custom block, it says undefined method, which is weird since it works within my other behavior in a code block.

I attached screenshots below.
The code generated by the custom block is:

Code: [Select]
public static function Remove_Region(__region:Region):void
{
    removeRegion(__region.ID);
}

And this is made as a global custom block so I can use it anywhere.
Anything wrong ?

20
Thanks alot, it works, I forgot to see them as object and using the dot to get to their properties... thanks again !

21
Hi.
There's 2 of my custom behavior in which I create region from where I would need to remove those regions once they aren't needed anymore, unless you tell me I can have many regions floating there in the scene without any performance hit.

I was able to found the code to create circular region from the API doc, which is:
Code: [Select]
createCircularRegion(x, y, radius);
But I did not spot any "easy" way to actually removing a region after I created it. The only thing I found in the API doc about that is this:
Code: [Select]
removeRegion () method
public function removeRegion(ID:int):void

Parameters
ID:int

Found in GameState.

If it is the way I'm supposed to remove a region, how am I supposed to get the ID for the region I created ? Is there a "getID by objectName" thing ?

Anyway, any help is appreciated, thanks.

22
Windows / Mac / Flash / HTML5 / Re: Blockz
« on: June 27, 2011, 02:21:03 pm »
For the checkpoint thing, it's already done, but there're won't be any on the tutorial levels.

FOr the holding block on your head, do you mean it doesn't work or that it falls off ? Cause I tested it a lot, and it worked very well all the time, you hold SHIFT while moving, if you jump, you need to stay steady or the change in speed will affect the block and it will fall (gravity thing).

As for the controls, it is the best I could find, so that you can hold the mouse at the same time as you move and do stuff with the character.


23
Windows / Mac / Flash / HTML5 / Blockz
« on: June 26, 2011, 12:03:50 pm »
A work in progress, 2 tutorial level done.

About the game:
It's a puzzler game revolving around blocks, but set in an action platformer environment, so you solve puzzle, but also jump from place to place and kill ennemies as you go. There's alot of different type of blocks and skills you can use throughout the game, and you will find power-ups and be able to buy items such as bombs with coins hidden in each levels. In a nutshell: This game will rock !

You can play it here:
http://www.stencyl.com/game/play/3700

Updates:
I fixed a bug with collision in small places, I was able to reproduce the bug at the beggining of level 1-2 when you could not push the 2 block column anymore. This is now fixed, and as a result, the game was also updated to make block fall more easily into small holes, even at full speed.

So...

*Bug with block collision in small spaces fixed. i.e: Problem with block column at the start of level 1-2 is fixed
*Block now fall easily into small holes, even when you are going fast, no need to slow to a crawl anymore to make those fall in

24
I was aware of the fact we sometimes need to close and re-open stencyl to "clear" the sandbox or something for some changes to take effect, I saw it when making some behvaiors in the past, so restarting stencyl don't work.

Also, I tried the debug screen, and no error pop-up.

I created a new project from scratch and imported only the canon and the bullet, created from scratch two blocks without any behaviors, created a simple scene without any behaviors, and the problem still occur. The exact same way, so it ain't my behaviors set in other actors or the scene.

I uploaded the game folder, so you can test it and see what happens. I'm sure it isn't normal.

Refer to my first post to know what a blue and red blocks are supposed to be used for (i.e Red static, blue affected by gravity).

http://creationasylum.net/games/test_debug.zip

25
Well, that settings should not be disabling collision, when another actor act on it, it blocks it, the collision works. I think it's an error in stencyl, maybe a design error, that 2 object with that setting cannot collide, since, IMO, that setting is doing its job when a normal phycis object collide with a cannot be pushed object, collision do works.

Maybe someone in the stencyl team could confirm the issue, so that I won't work long hours working on it, if it could be fixed in future release. If it aint a bug, I wonder what it is.


26
The Problem in a nutshell:
I have a problem with collisions, and so far, with everything I tried, it seems to be a problem with 2 actors being set to "Cannot be pushed", and one is moving into another, and they don't collide. But if I set any of the two to "Normal" physic setting, the collision works.

The situation:
- I have a canon who is firing a bullet.
- I have a bullet actor that is created by the canon, a velocity is set, and it travels
- The bullet have "Cannot be pushed" setting in physics, and have the right collision group to
collide with blocks, from the blocks collision group

- I have 2 blocks, one blue, and one red.
- Both blocks are identical except for 1 setting: The physic setting about "Normal" and "Cannot be pushed". They have same behaviors, same collision grid, same size, same collision group, etc

- The blue block physics is set to normal, so it fall when what's underneath is destroyed.
* The blue block gets hit by the bullet fine

- The red block physics is set to "Cannot be pushed", so it is static in the game worls, and the player
cannot move it around
* The red block doesn't collide with the bullet. The bullet passes right through it.

What I Did:
When I change 1 simple setting on the red block, it works. When I set the red block to physics "Normal", it get hit by the bullet just as the blue block. As soon as I set it to "Cannot be pushed", it stop working.

I tried changing the bullets settings, but if the bullet is on any other settings except "Cannot be pushed", it doesn't travels at all in the game screen, and I don't want the player to have an impact on the bullet, I want the bullet to have an impact on the player, so that "Cannot be pushed" need to stay on both actor: The red block and the bullet.

I also tried disabling all the behaviors from the bullet and red block, still the same problem.

I think there is a problem with 2 actor being "Cannot be pushed"... They should still collide, they just won't receive momentum from anything in the game world, at least that's what I understood from the test I made and what is written in stencyl.


Pages: 1 2