hrisnz's Recent Forum Activity

  • You guys are a blast! Thank you so much!

  • You guys (and this forum) are amazing. Everybody is so friendly and helpful. Thanks a lot.

    Twitter should learn 1 thing or 2.000.000 from this platform :D

  • Hi PeterPlatter

    I enjoyed thinking about "physics based games" as a starting point for none combat games. And with physics based I mean having not "enemys" be the obstacles on our way to a goal that have to be overcome but stuff like weather conditions, gravity, magnetism, evolution, decay, oxygen, fire, ...

    What do you guys think about this approach?

  • Hi LuisCGForte,

    Did you mean like this?

    I'm pretty sure I am missing out on some obvious "add JS as script in C3 or syntax or or or" issue here because this doesn't work :D

  • UUuh I do use C3. But I did not know this! Thanks for the tip :)

    Have a great day

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Hi!

    Thank you for your help guys!

    I got it.

    I didn't manage to get moment.js running like suggested by newt but because of your advice LuisCGForte to use full Javascript I found a post by Asmodean and got it working.

    construct.net/en/forum/construct-3/how-do-i-8/convert-unixtime-readable-143677

    I added +1 year (because I want my game to always take place today in a year of time. The +1 on the month was given in Asmodean's example already "Browser.ExecJS("this.myDate.getMonth()")+1" and it makes the month show correctly. I did not quiet get why a 1 needs to be added to the months. But now everything works.

    For any who is interested in how I use it in my game "SESA":

    Instead of having the start date (which is like your highscore) hard coded, so same every game. it will detect the current date as you play and adds one year to it. So the game will be called "SESA - One Year From Now". Since the prologue tells the player that an asteroid struck earth in the near future and now you have to control the Space Exploration and Survival Administration to colonies your solar system and more to come. I just thought its a cool idea to subtly seed the thought of „what would i do/ who would i be/ would i be if an asteroid struck earth in one year from today. How would i live this year... Just a very small detail and a bit of over engineering, as always. Buts thats just me hey

    I hope this helps more people in the future maybe ;)

    Thanks again for your help!

    Best,

    Chris

  • Hi newt,

    thanks for this one! This plugins was new to me.

    First I thought you can only create own moments and add values in hours. But it seems to also be able to create a timestamp vom Unix and than change its format via js parsing.

    I tried it, and I quiet don't get it :D

    I was hoping for something like "set text to: Year (Get the currect year as string)"

    But sadly it seems to be not that easy.

    Thanks for the link to the plugin and your help so far!

    Best,

    Chris

  • Hello community :)

    I want to use the current "date" in my C3 game as a string. Apparently there is a solution to this, that is 4 years old, using JavaScript or other 2 year old plugins.

    construct.net/en/forum/construct-2/how-do-i-18/system-date-time-103607

    Is this really the only solution?? Is there another way I'm missing out on? This feels like it should be so much easier :P

    Any advice would be amazing <3

    All the best,

    Chris

    Tagged:

  • Both ways seem to work :) thanks again. I used the a little bit unelegant looking version with adding "wait 0.01 seconds" to each subevent. This way I knew what to do when expanding the code to all other planets.

    So for anyone who is interested. It is looking like this now.

    I'm open for improvements or anyone who can explain me how to achieve the same result using "else"

    Have a great productive night ;)

  • Thank you guys so much, i will try this just now!

    What I want to do with is:

    I have 1 Sun

    I have multiple Planets

    If you click on any of them, the camera focuses on them using lerp position.

    But if you click a planet while being focused on it, you return to focus the sun.

    I see if your solutions work and let you know <3

    Thanks again!!!

    Best,

    Chris

  • Hello guys :)

    I keep running in this same issue, and solving it with a global variable to emulate a switch like the following doesn't stop my thirst of a solution:

    global variable = 0

    if X add 1 to global variable

    if global variable > 1 set global variable to 0

    This works fine for a very isolated case. But as soon as you want to do multiple things with it, it stops being very elegant.

    So what I want to do is this:

    But in this case, both subevents fire - resulting in it stopping itself.

    I guess the screenshot illustrates quiet good what I want to do and also why it does not work at the same time.

    If it's helpful to let you know how I want to use the solution to this problem, let me know :*

    I guess what I need is something to "break" / stop the event from continuing. But neither "Trigger Once while true" nor "signal", "wait for signal" is helping here.

    I feel like I'm missing a pretty basic understanding of how events function in Construct to solve this problem myself here. I think in c# you would just do it with a "return"? Because than the following event would not get fired.

    Any help on this would be a blasting amazing blast :****

    Thank you so much and have a great week guys!

    Chris

  • I had a similar problem and this was one of the rare posts i found. Even though my problem was not related to text boxes but the normal text emelement, i still post my answer here in case anyone else stumbles over this:

    My text box, using an imported font, did not show any text that was wrapped (on mobile devices only); so it only showed the first line and cut of words even leaving splinters of letters behind. Testing on PC the text rendered fine.

    Events wise I set my text first, referring to this manual excerpt: "TextWidth

    TextHeight

    Return the size of the actual text content within the text object's rectangle. Note the Text object must be drawn before these have the correct values. If you set the text then immediately access these expressions, they won't yet have the correct value. Adding a 'Wait 0.1 seconds' action will usually solve this." scirra.com/manual/116/text

    Then I set width and height, to position other elements responsive to its position and size.

    THE ANSWER TO THE TEXT BEING CUT OFF:

    It seamed to have something to do with "custom font" + "Enabled BBCode". As soon as I disabled it in the properties of the text object, everything works fine on all devices.

    I hope this might help somebody in the future :)

    Best,

    Chris

hrisnz's avatar

hrisnz

Early Adopter

Member since 17 Feb, 2016

None one is following hrisnz yet!

Trophy Case

  • 8-Year Club
  • Forum Contributor Made 100 posts in the forums
  • Popular Game One of your games has over 1,000 players
  • Regular Visitor Visited Construct.net 7 days in a row
  • RTFM Read the fabulous manual
  • Email Verified

Progress

13/44
How to earn trophies