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

Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Topics - Power

Pages: 1 [2]
16
Feature requests / Full UML Class Diagram for SFML?
« on: March 30, 2020, 10:53:35 pm »
Hello,
While i am browsing the SFML documentation, i can stumble on little diagrams showing which class inhetit who (like here : https://www.sfml-dev.org/documentation/2.5.1/classsf_1_1CircleShape.php).
I also found myself rewriting all this information on paper and trying to have a full view on all the available functions available.

I wondered if there was a full diagramm class showing all the inheritance between all classes? To have a place where you can click on any class at one glance.

17
General / How to be more efficient and faster in coding?
« on: March 16, 2020, 11:37:14 am »
Hello,
Since the coronavirus outbreak, and even before, i tried to spend some time to try to make my first game, and  it made me realize that i had to relearn all of SFML through tutorials since i am pretty new to SFML and the only free courses i took on SFML were not enough to cover everything.

But i find myself very slooww, what i thought finishing in one night, i found myself doing it in many days.

I tried to ask myself the question, how to get things done and be efficient in coding and code learning? i tried to see my patterns and see what "distracted" me.

I am curious about your experiences and your solutions. How do you learn a new langage fast? How do you code and focus and get things done fast with no distractions? What's your best and more efficient methods.

Thanks,
P~

18
SFML wiki / Confusion while Reading the documentation on : Events
« on: March 09, 2020, 07:59:52 pm »
Hello,

(I am still new to c++, but i made quite lot of progress, i am not a computer science student although.)

I have a question that could appear "non intelligent" but it kinda confused me. Here it is:
While using the "window" module, its functions were easy to use and pretty straighforward (https://www.sfml-dev.org/documentation/2.5.1/classsf_1_1Window.php)
The "Public Member Functions" section contains all the functions at one glance, for instance i can use window1.isOpen() if i created and object called window1 from the classe Window.

But then i went to the event page (https://www.sfml-dev.org/documentation/2.5.1/classsf_1_1Event.php)
because i wanted to check an example that i had read from here : https://www.sfml-dev.org/tutorials/2.5/window-events.php which is below:
         
  if (event.type == sf::Event::MouseWheelScrolled)

 {
 if (event.mouseWheelScroll.wheel == sf::Mouse::VerticalWheel)
   cout << "wheel type: vertical" << endl;
else if (event.mouseWheelScroll.wheel == sf::Mouse::HorizontalWheel)
 cout << "wheel type: horizontal" << endl;
else
 cout << "wheel type: unknown" << endl;
 cout << "wheel movement: " << event.mouseWheelScroll.delta << endl; // this line
 cout << "mouse x: " << event.mouseWheelScroll.x << endl;
   cout << "mouse y: " << event.mouseWheelScroll.y << endl;
                }
I got confused when i read this part "  event.mouseWheelScroll.delta",

What is : "mouseWheelScroll"?
It can neither be found on the classes section of the Event pages nor the public types, i can see it on the public Attributes somehow.
Checking the Event.hpp page : https://www.sfml-dev.org/documentation/2.5.1/Event_8hpp_source.php, i don't find "mouseWheelScroll", only "MouseWheelScrollEvent" and "MouseWheelEvent" which are different from "mouseWheelScroll".
As for the "delta" in "event.mouseWheelScroll.delta" no confusion, it's one of variables of the structures i found on the "Event.hpp" page.

Sorry if the answer is obvious, maybe i miss something in c++ that i still need to learn. If yes, please do enlighten me.
Thank you

19
Graphics / Do these three features exist? [Solved]
« on: March 08, 2020, 08:42:14 am »
Hello,
I was very exciting to discover SFML and the world of programming,
Now i have few quick questions if someone expert knows the answer

1) Is it possible to draw an object (with paint) and use some kind of tool/programm to transform it into a real in game item with the exact shape you have drawn?  (meaning the item will have the collision area you have drawn)

2) Is there a function to merge items/objects into 1 item? (example : 2 circles meet each other (one circle hits the other), resulting in making one single item with a shapre of "8")

3) Is it possible to give an item, let's say a rectangle, 4 different kind of interactions with other items depending on which side of the rectangle was hit by another item? (So if a user rotated the rectangle to make it hit with the side number 2 or 3, the result would change, my question is, can SFML differenciate between the 4 sides of the rectangle?)

Thank you
And a have a good day
P-

Pages: 1 [2]
anything