InDWrekt's Recent Forum Activity

  • The max function is used to pick the highest number in a set of numbers. In this case, there are only 2 options:

    2 + stars

    levelsat(CurrentLevel)

    The result is the value that is highest. If 2 + stars == 2 and levelsat(CurrentLevel) == 0 then the result of the function will be 2.

    Now, what do 2 + stars and levelsat(CurrentLevel) represent? After a quick read through, this is what I understand the values to mean:

    2 + stars: represents the animation frame to be stored in the array according to the number of stars earned in the level. You add 2 because there are a few frames before the frames with stars so if the player beat the level but didn't earn any stars, the frame to display will be the completed frame with no stars.

    levelsat: appears to be the name of the array storing the information for what frame to show but I don't see any other place this name is used. I think this should be replaced with the name of the array and may just be a typo.

    CurrentLevel: is a global variable representing which level you are on.

    levelsat(CurrentLevel): If my understanding of levelsat is correct, this means get the value of the array at the position matching CurrentLevel.

    Given the above, the condition max(2+star,levels.At(Currentlevel)) means:

    store the number of stars earned (plus the offset) if it is higher than the previous high score already stored in the array. So if a player previously earned 2 stars and this game only earns 1, the number of stars stored remains 2 but if they earn 3 this time, the number changes to 3.

  • You could simply give the character a variable storing which direction they are facing. Then when setting the idle animation, check the variable.

  • You have defined the spawn times by a tick count. The ticks are being calculated before the gameplay layout is set active. This means, even before you are in play mode, your enemies are spawning. You can easily fix this by adding a family with all the enemies, arrows and the prince/princess and on start of layout, destroying them. That way, the level will start fresh.

  • ChristianOak

    Yes it is definitely possible to both create a game like Might and Magic and to create randomly generated worlds. However, that is definitely not the first game you want to start with. Before you attempt any game like HOMM, you need to start with the basics.

    You can't just start game design with a super complex idea and hope to be successful.

    Go through the beginner tutorials and the manual. After you have a good grasp of how Construct works, make a few puzzle games. You could clone some already popular games like the common falling block games or match 3 games. Only after completing (yes I said COMPLETING) a few basic games should you start working on something more complex. Remember, HOMM is a complex game which requires some understanding of AI and inventory management; all of which are complex topics on their own.

    Also, asking a question like, "How do I make <enter game name here>?" is not particularly useful either to you, or the community. Instead, a good question would be, once you have a grasp of how to use Construct, asking how to make use of a particular feature you cannot find clear information about.

  • A0Nasser

    jayderyu specifically stated updates, not new versions. If you buy Unity version 4, you get all version 4 updates. You don't have to pay when 4.1 becomes available for example. However, when 5 comes out, you will have to pay to upgrade. Construct and Construct 2 have separate licenses just like Unity 4 and Unity 5.

    All Construct 2 updates are included when you purchase a personal license. If Scirra decides the next version is a major milestone and creates a Construct 3 version, I would expect you would have to pay an upgrade cost as well.

  • You could use 2 separate objects, 1 slightly bigger (1 or 2 pixels) that triggers the line of site and a smaller 1 with the solid behavior.

  • I downloaded your file and took a look. It looks pretty good to me but, when you get a bunch of animations your array will grow exponentially. What I usually do is, rather than naming my animations with a direction, I name them according to the action the animation represents and append a number that represents the direction (e.g. walk1, walk 2...). Then, since you are already calculating the direction number, append it to the end of the animation name. Attached is a modified version of your file with the suggested change. Take a look at how I renamed your animations and the every tick event.

  • One thing you may not have tried is, On start of touch, check to see if 2 items are selected. If not signal to drop the item. I am attaching an example which has 4 sprite objects. If 2 or more are selected, it will allow the user to drag the selected ones. If 1 or less is selected, none can be dragged. Understand, it is not production ready; it is just to show the method above.

    I hope this gets you what you need and good luck with your project.

  • When it comes to negative degrees, -90 degrees is the same thing as 270 degrees which is the same as 630 degrees (1 full rotation plus 270). Because you can continue going around a circle, you can consider a given angle in the circle as the angle +/- 360. It will always be equivalent. I hope that answers your question.

    As for the bug, it is caused by the check if the angle is between -25 and 25. As with almost all issues, there are multiple fixes for it. Attached are 2.

  • This should fix the issue for you.

    Part of the reason your controls were failing is, the keyboard and D-pad were fighting against each other. The D-pad x-axis was 0 so even though you pressed the keyboard arrow key, the angle was set back, etc... I combined some of the controls into a single event so they wouldn't fight and the 2 events for setting the piece idle, I placed before the ones that set it to rotating.

    Here are a couple other things I did to get it working:

    I pulled out the amount you are rotating by and placed it in a global variable. That way if you decide to change the value, you only have to change it 1 place. I added a global variable called state with 3 valid options: -1 for rotate left, 0 for idle and 1 for rotate right. Using a variable to represent state can make changes over time a little easier to work with. I used the state to define when the sprite is rotating and which direction. Finally, to create the smooth transition back to the original state, I checked to see if the left and right buttons were released and if the controller x-axis was 0. If so, I set the state back to 0 for idle. When the state is 0, I transition the sprite back to 0 rotation.

    I hope that helps and good luck with you project.

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • The answer is, it depends. You need to try the tools out and see which ones fit your style. Personally, I used Gimp and Inkscape together for years. Then I bought the Adobe suite and realized, I preferred Gimp and Inkscape to Photoshop and Illustrator. I also tried a few other Open Source products such as Pencil, Synfig, Paint.net and many more. They were all great tools but I just kept going back to what I knew in the end.

    I like to create the base graphics in Inkscape, add detail in the Gimp and, as of late, I have been using Spriter to animate it.

    I would suggest you stick to Open Source at least until your art starts paying. Commercial graphics programs cost too much for a hobbyist in my opinion.

    Also, if you have access to a touch screen or usb connected tablet, MyPaint is a fantastic digital painting tool. Check it out.

  • bsimser

    Just wanted to throw this out there:

    "do this"

    <insert image>

    [attachment=0:4xc0nyhr][/attachment:4xc0nyhr]

    "then this"

    <insert image>

    [attachment=1:4xc0nyhr][/attachment:4xc0nyhr]

    I know this is kind of a snide response but, I wanted to show you the images can be placed "inline" with your text. All you have to do is, after clicking the "Place inline" button, make sure the line that reads "[attachment=#]YOUR_IMAGE_NAME.EXTENTSION[/attachment]" is on the correct line of your post.

InDWrekt's avatar

InDWrekt

Member since 19 Sep, 2011

Twitter
InDWrekt has 7 followers

Trophy Case

  • 13-Year Club
  • Forum Contributor Made 100 posts in the forums
  • Forum Patron Made 500 posts in the forums
  • Regular Visitor Visited Construct.net 7 days in a row
  • RTFM Read the fabulous manual
  • Email Verified

Progress

18/44
How to earn trophies