Megabeard's Forum Posts

  • Err, I didn't think I'd have such a major issue so soon again, but my player scores are acting up and I was hoping someone could help.

    You see, at the end of each level, I give the player a "Report" letting them know how they did. There's a coin bonus, time bonus, level score, and total score.

    But for some reason, my level score and total score are acting very odd. At the end of the level, the level score seems to be 2x-3x what it should be considering the bonuses, and the total score is always 2-3x higher than the level score... even though it's the first level. So the level score should be equal to the total score, and the level score should be equal to time bonus + Coin Bonus. I don't really understand what I've done wrong, but here are some printscreens to show you what I did:

    <img src="http://i49.tinypic.com/15raxxl.png" border="0" />

    Here's what I'm getting:

    <img src="http://i46.tinypic.com/2na36dd.png" border="0" />

    Can anyone help?

  • > I feel like I'm missing something obvious here...Yes you are. You're missing a counter of the elapsed time. ROJO showed a way of displaying a value in a minute:second format, but without counting the time it will always read 0:0, of course. Also, don't change the variable that you use for counting. And how come that you were able to enter "int global('Seconds')/60" without an error message? There are brackets missing: "int( global('Seconds')/60 ) "

    First, create a counter for the elapsed time, let's say "totaltime". Now let it count the time:

    +Always

    ->Add TimeDelta to global('totaltime')

    Then add the conversion:

    ->set global 'minutes' to int(global('totaltime') / 60)

    ->set global 'seconds' to global('totaltime') % 60

    and finally show it:

    -> Set text to global('minutes') & ":" & global('seconds')

    Somewhere on these forums you will find my "clock" example, it shows the conversion for h:m:s and also shows how to display the time as an analog clock.

    It's now working properly, thanks for the help!

    Also, I'm unsure why "int global('Seconds')/60" worked. I'm using the newest version of Classic, so maybe that's a change that was made?

    I'll look for your analog clock example since that's sort of what I'm going for. Thanks again!

  • Well I just tried doing what you suggested, but I think I did it wrong. Here's a printscreen:

    <img src="http://i49.tinypic.com/309jatv.png" border="0" />

    When I untoggle the 'Add 1 every 1000 milliseconds', the text goes haywire when I try to play. When I toggle it as shown in the screencap, it reads: "0:0"

    I feel like I'm missing something obvious here...

  • Hello again. This one is a small issue, I swear! <img src="smileys/smiley36.gif" border="0" align="middle" />

    I'd like to make a timer which looks more traditional. As in, after 60 seconds, it goes to: "1:00" and so on to show the minutes. I've got the timer aspect of it down. That part was pretty simple, but I can only get it to show seconds. So after it gets to 60 seconds, it doesn't show minutes, it just keeps going up in seconds.

    tl;dr version: I'd like to make a timer which that looks like this: "1:00", not like this: "60". Is there a simple way to do this in Classic?

    Any help would be appreciated. <img src="smileys/smiley1.gif" border="0" align="middle" />

    Edit: Also, I have thought maybe something like this would work:

    Have two separate texts, one would be the minute, and the other seconds. Each seconds reaches 60, I reset seconds, and add 1 to minutes.

    ... I was just hoping there was a more simple was is all.

  • Valve is what a lot of Game Devs should aspire to be... and I'm sure they do. The only trouble is that it's even harder to do today what they accomplished in an older generation.

  • Indeed. I recently did something similar to what you suggested and have encountered that very problem, since it just looks like my character is running backwards (Which is a bit confusing to me). I don't consider it a huge deal since it still looks pretty nice, but if you're curious how to fix that up I'll let you know if I find a way to make it work...

  • Thanks Pecek, that cleared things up for me. I just have what should be one more question...

    How would I go about making the angle of the player equal to the angle of the moving platforms I'm using? Noga mentioned that it made things look more smooth, and I'd just like to see how it looks, because at the moment my player sprite is just hanging off of the platform when it moves at an angle.

    Thanks again for the help guys.

  • Hey Noga, if you happen to see this thread again, I have a question...

    In the sub-event where you looped waypoints 1-8, your action was:

    System: Create Object MovingPlatform on layer 1 at (20 + 32 * LoopIndex, 300)

    I guess my question would be what "(20 + 32 * LoopIndex, 300)" means? Whenever I use this, the platform I'm using doesn't flow nearly as smoothly as yours, and in addition, I can't seem to create additional platforms like your cap demonstrated. I have to add my own in on the layout, and I think that's why when I do it for my game, it doesn't look as nice or function as well as yours.

  • Interesting, I wouldn't have thought of RTS movement... guess I just kind of assumed sine was the only way. The bouncing was pretty minor to me, and I think it may have to do with the fact that it's many different boxes moving. In my case, it's just going to be one solid line (Hopefully that works anyway.), but the movement you used was perfect for what I have in mind.

    Thanks Noga!

  • Hey guys, I'm stumped yet again and was hoping I could get some advice. <img src="smileys/smiley1.gif" border="0" align="middle" />

    I'd like to make a moving line graph that the player has to ride over a pitfall in my platformer. It's a similar idea to the moving platforms of Super Mario World, except here it's a bit more complicated because a line graph moves at different angles when moving up and down.

    Here's an example of what I mean: youtube.com/watch

    Except like I said, it would move at an angle... but truth be told, I can't seem to figure out how Sine works at all. As in, I can't even get the platform to move. <img src="smileys/smiley36.gif" border="0" align="middle" />

    So can anyone help?

  • In whatever event I use to switch layouts, I also include an action to stop the music within that event. Have you already tried that? It works for me.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • What you say seems to be working for me, though only for Audiere, the sounds won't play using Xaudio2 for some reason. On the flip side, Audiere apparently doesn't recognize when it's supposed to be global even though the option is there... oh well, at least sound related things are nice and simple to add in now.

    Thanks for the help, tulamide! :)

  • In my game, I'd like to play music in my layouts in the simplest ways possible. I find that when you load the file during play time as an action, it's a bit complicated for my liking. You have to load the file from where the construct file is, otherwise you have to specify the folder, which I'm guessing as an exe would be a huge pain since I'd have to include all those files with the exe (Or am I wrong?), so I want to avoid that.

    I notice that there is a folder for music and sounds in the project bar of Construct, so I'm wondering, how would I play music from the files I already loaded to those folders? I figure just putting them in the program like I would, say, a sprite, would be by far the easiest route to go, but in both Xaudio2 and Audiere, I can't figure out how to play those files I had already loaded.

    So basically, what I'm hoping to do is just play the sounds I've already loaded into Construct. Any ideas how I'd go about doing that? Thanks.

  • The funny thing about ideas in game design is unlike many other forms of entertainment, that other people usually won't take other people's because they already have their own. You sure there's absolutely nothing you can think of? If not, here's a little something that's been in the back of my mind for some time that I'll likely never get around to doing:

    In the future, you are an obsolete robot, and like with most technology, when it's obsolete, it gets thrown away, upgraded, or deactivated. However, this particular robot escapes the grasp of its owners in light of learning it was about to be "Decomissioned". However, the robot has pursuers, who are experts on hunting down rogue units. You are deemed a threat to society, and your only objective is to survive, and make your way out of a futuristic city.

    The gameplay is up to you, but I envisioned it as being very tech based. Since you play as an obsolete robot, when you attack, you lose energy. The only way to gain energy is finding power cells. The energy also keeps you alive. It's somewhat similar to the mechanic of energy in the F-zero series. You can use attacks, but it also drains your life, so you have to be careful. Other ideas I had were being able to detach the robot's body parts to complete puzzles. A bit like how Bender from Futurama can crawl around using nothing but one of his detatched arms.

    The final boss could be your hunters, or perhaps your former owners.

    Not a very developed idea, but maybe it'll catch your interest.

  • That sounds very plausible, and it shouldn't interfere with the other events like my attempts, so I'll give that a shot now.

    Thanks for the response! :)