AllanR's Recent Forum Activity

  • insanesnake

    take a look at this thread from a couple months ago...

    https://www.construct.net/en/forum/construct-3/general-discussion-7/scrollto-lerp-front-instead-143258?kws=spaceship

    this is a sample I made, it drifts the way I would make a spaceship...

    https://www.rieperts.com/games/forum/spacebackground2.capx

  • I would do:

    IF 	a = "Test3"
    	b = "Test2"
    	c = "Test1"
    THEN Result = "True first"
    
    else
    
    -> IF 	a = "Test5"
    -> 		b = "Test6"
    -> 		c = "Test7"
    -> THEN	Result = "True second"
    
    -> else
    
    -> -> IF 	a = "Test7"
    -> -> 		b = "Test8"
    -> -> 		c = "Test9"
    -> -> THEN Result = "True third"
  • Mokoto

    I used to use Absolute X and Y occasionally, but I found that using Mouse.X("HUD") or Touch.X("HUD") where HUD is a layer with Parallax set to 0,0 works much better - and should solve the issue you are having.

  • Awesome! :) you have obviously put a lot of work into that! Very impressive.

  • potap100

    you must have an action in your event sheet that tells it to start playing the song, which is making it start the song over again.

    if the layouts share an event sheet, then you can first test if Audio is not playing anything, then start the song.

  • yeah, I saw that too in event 88.

    NaN stands for Not a Number, and means you are trying to put a text value into a number variable...

    You might want to use an array if you are going to have more levels. Then you can save and load the entire array with one action.

  • mOOnpunk

    if the value is going from 0 to 1, then you want a formula like:

    A + (B*(1-current value))

    you could add clamp() just to make sure the values don't get outside the range you want...

    EDIT: on second thought, I am not sure I completely understand what you are looking for.

  • ComGamer

    I have a library for making buttons that I use in a lot of projects - it covers all the states, multi-touch, overlapping, and other things.

    what I do is store the name of the function to call when the button is clicked in an instance variable of the button family. That way I can create a new sprite for a button, add it to the family, give it the name of the function to call, and everything else is handled automatically.

    You could do something similar... when the r key is pressed, let the object determine what function to call.

  • Aldenwar

    just guessing here, but you may need a "For Each PlayersCharacters" under the 4th event. That code might be failing if two players are dead at the same time. The Trigger Once may also be part of the trouble.

    I would try to eliminate the trigger once by expanding the player's status to Alive / Dead / Respawning

  • the array wont be loaded yet when event 8 executes (at start of layout)

    it will take a while before the AJAX on complete executes, after that the array will be loaded and available to other events...

    if you assign the text object in the AJAX on complete event (after loading the array), I would expect that to work.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • in the AJAX On Complete event (event 7) you are setting a text object to AJAX.LastData

    you should be loading LastData into the array (Array Load AJAX.LastData)

    then you can access the array like this:

    TextObject Set Text Array.At(random)

    (Where random is a random number between 0 and the last entry)

  • another option I use a lot is to use TokenCount and TokenAt...

    put your text in a variable with a delimiter and then use TokenCount to see how many choices there are, and TokenAt to extract a random one.

    if you want any control over how often a particular text is chosen, or want to make sure it doesn't repeat until all the possibilities have appeared, then an array is a good choice - you can delete the entry that is chosen.

    (Using TokenAt is a great way to load up the array, and then delete each entry as it is used to make sure it doesn't repeat)

    EDIT: Nepeo can you remove an entry from the Advanced Random to eliminate duplicates? That would be awesome!

AllanR's avatar

AllanR

Member since 21 Nov, 2013

Twitter
AllanR has 23 followers

Trophy Case

  • 11-Year Club
  • Forum Contributor Made 100 posts in the forums
  • Forum Patron Made 500 posts in the forums
  • Forum Hero Made 1,000 posts in the forums
  • Popular Game One of your games has over 1,000 players
  • x2
    Coach One of your tutorials has over 1,000 readers
  • Regular Visitor Visited Construct.net 7 days in a row
  • Steady Visitor Visited Construct.net 30 days in a row
  • RTFM Read the fabulous manual
  • Email Verified

Progress

20/44
How to earn trophies