jatin1726's Recent Forum Activity

  • > > Thanks mate!!! That worked fantastic!

    > > I didn't know that i can pick items that easily if i put them in container!

    >

    > Hi Can you share the list example. I also need it for my project.

    https://i.postimg.cc/28hqqfwD/list1.jpg[/img]

    https://i.postimg.cc/fRsVmg20/list2.jpg[/img]

    This is how i implemented scrollable list in my project. If you have any question, feel free to ask.

    Thanks for the code. Can you share capx too. It will help in better understanding.

    Dop and your help I need for lazy loading thing for scrolling list. Assume for scrolling list there are 100 blocks and each block has unique image. Construct 2 loads all images before starting the game right so downloading 100 images will add lot of delay to the game. Here as a solution websites use lazy loading. For example, in first view only 10 blocks are visible so only 10 images are download. When user scrolls further, 5 new blocks are added to the screen so only 5 new images are download thus it saved unnecessary downloading of images. Can you help out in achieving the same.

    Regards,

    Jatin

  • Are you talking about the last formula? It should work with any number of frames in the animation.

    .

    I am not very good at explaining..

    (((mouse.X-startX)/8)+(Sprite4.AnimationFrameCount*10)+startFrame)%Sprite4.AnimationFrameCount

    Here "8" means sensitivity - frame will change every 8 pixels.

    %Sprite4.AnimationFrameCount is the remainder after division. For example, 50%36 will give you frame number 14 in animation with 36 frames.

    (Sprite4.AnimationFrameCount*10) - this part of the formula is needed to prevent the value in brackets to go into negative numbers (when you swipe to the left). It basically just adds 360. For example:

    (10+360)%36=10

    (-10+360)%36=26

    Thanks dop for such nice explanation. It is really helpful but you r bad lier, u said you r not good explainer but I feel you are good in explaining the solution. God bless you.

  • Check if this is your problem.

    Eliminate "restart layout" because you are resetting the layout to the initial values, then you can never set the new values.

    Thanks, mink for sharing the solution. though I can't remove the restart layout as it plays a cruicial part in my code. I spent some more time and got the issue fixed with keeping restart functionality intact.

  • Ok, I fixed it, see this demo:

    https://www.dropbox.com/s/7rrjq240qvwsykq/slider-pulsar2.capx?dl=0

    Thanks a ton dop. it worked very nicely now. 100% working solution. But I have one question, what is the solution formula you applied for animation frame on touch/mouse. Bcz when I tried the same 360 rotation on object with 23 frames (instead of 35 of pulsar demo capx), it acted wierdly though rotated smoothely. On swiping towards right, bike was rotating towards left side and vice versa instead of goign into the same direct as of touch direction. I think the secret is behind the formula u applied, can you explain it a bit. That will be very helpful.

  • Hi Friends,

    I want to add google analytics for tracking imp and events by users. Could anyone please guide me how to do that?

    Regards,

    Jatin

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Sorry, I don't understand. You can rotate the image left and right many times, not just once.

    It rotates with jerk on touch start. oN each touch start it starts from same fixed point instead of from the point where user touches.

  • jatin1726 Try this demo:

    https://www.dropbox.com/s/hnhepai660anaf4/ScrollingListOfPlayers.capx?dl=0

    Thanks a ton dop. God bless u.

  • Hi Friends,

    I have created three list object. Each list item on selected should change the sprite frame based on ID. But it is not updating the sprite frame as per the id. Can anyone help me what I am doing wrong?

    Here is the capx im working

    bit.ly/2VSf6bE

  • Thanks mate!!! That worked fantastic!

    I didn't know that i can pick items that easily if i put them in container!

    Hi Can you share the list example. I also need it for my project.

  • Wow, 37 events to rotate one sprite! :)

    You can remove the slider bar and do this with just one event:

    > Mouse left button is down: Sprite set frame to ((mouse.X+180)%180)/5
    

    Also, set animation speed to 0 in the sprite editor.

    Hi DOP, thanks for reply but the solution you shared roated image once and then stopped. where as my requirement is smooth 360 rotation on touch. can you help me out in that.

  • Or maybe

    Hi thanks for the reply but I tried to add the touch and it is giving weird jerks while touching the sprite and everytime starts from same position on touch instead of starting from the position where last touch ended. can you help me out how to make it smooth?

  • Hi Friends,

    Need help in getting 360 rotation of an object done (already have different angles images) on touch swipe left and right. You might have seen the same in many sites where car or bike is rotated using mouse or touch. Please help me how to do that. Sharing capx of what I have done before and it not giving best results.

    Here is the file. bit.ly/2VFgCy1

    Regards,

    Jatin

    Tagged:

jatin1726's avatar

jatin1726

Member since 27 Oct, 2014

Twitter
jatin1726 has 4 followers

Trophy Case

  • 10-Year Club
  • Forum Contributor Made 100 posts in the forums
  • x2
    Popular Game One of your games has over 1,000 players
  • x25
    Coach One of your tutorials has over 1,000 readers
  • RTFM Read the fabulous manual
  • Email Verified

Progress

15/44
How to earn trophies