Welcome, Guest. Please login or register. Did you miss your activation email?

Author Topic: Making new shape with particle fill.  (Read 1244 times)

0 Members and 1 Guest are viewing this topic.

ankitpaudel20

  • Newbie
  • *
  • Posts: 5
    • View Profile
    • Email
Making new shape with particle fill.
« on: January 18, 2020, 08:58:08 am »
I am very new to graphics programming and so decided to use sfml for my project. Now i am trying to generate random 2d terrain with small particle fill so that i can make the terrain  destroyable and hence be able to delete those filled particle at specific part of the game thus reshape the terrain afterward..I did not find any easy way of doing this with shapes.. any way of doing so would be very helpful.

eXpl0it3r

  • SFML Team
  • Hero Member
  • *****
  • Posts: 11030
    • View Profile
    • development blog
    • Email
Re: Making new shape with particle fill.
« Reply #1 on: January 18, 2020, 09:57:32 am »
It can require some trickery and depending on what you're doing with the terrain, will need a decent level of math & physics knowledge, but you're certainly not the first to try something like this. Try and google for "destructive 2D terrain" or if you've been inspired by some game, you may also find articles explaining how they did it or how you can replicate a similar effect.
Official FAQ: https://www.sfml-dev.org/faq.php
Official Discord Server: https://discord.gg/nr4X7Fh
——————————————————————
Dev Blog: https://duerrenberger.dev/blog/

 

anything