Recent

Author Topic: I Need Creativity  (Read 4805 times)

Weitentaaal

  • Sr. Member
  • ****
  • Posts: 278
I Need Creativity
« on: July 26, 2021, 03:32:27 pm »
Hello Guys,

Please have a look at my Attachement.

You Should see an "X" at each right side of the three Cubes.
I have to show somehow that there is a Split of my "Worm". Does any1 have any idea how to show this in a better way ?

People have to Notice that there is a Split... doesn't matter how i just want people to understand. And second objective is the appearance of All together.

PLEASE any Reply is Welcome im just stupid and can't find any good Solution.

Btw. i do not have any space between those Cubes left but i can repaint the Sides ... already have the Code just dont know what to draw.

Thanks in advice
Lazarus: 2.0.6 x86_64-win64-win32/win64
FPC-Version: 3.0.4
Compiler Version: 3.2.0

MarkMLl

  • Hero Member
  • *****
  • Posts: 3073
Re: I Need Creativity
« Reply #1 on: July 26, 2021, 03:52:30 pm »
If you were able to move the glyph onto the faces (i.e. all faces) then you could shade the edges slightly to make them look curved or bevelled.

Alternatively why not move or tilt alternating glyphs forwards/backwards?

MarkMLl
Turbo Pascal v1 on CCP/M-86, multitasking with LAN and graphics in 128Kb.
Pet hate: people who boast about the size and sophistication of their computer.
GitHub repositories: https://github.com/MarkMLl?tab=repositories

Weitentaaal

  • Sr. Member
  • ****
  • Posts: 278
Re: I Need Creativity
« Reply #2 on: July 26, 2021, 03:59:36 pm »
Sorry couldn't follow ..
what do u mean by "Alternatively why not move or tilt alternating glyphs forwards/backwards?"

I do not want to change the "Snake" itself  :-[

If u have a better solution on where to put the pictures (it should still look "clean" (by clean i mean you MUST recognice the Picture)) then any is welcome.

I'm not good at Graphical things this was my first bigger Project with graphics so pls don't kill me xD (i know this looks like trash  %))

Lazarus: 2.0.6 x86_64-win64-win32/win64
FPC-Version: 3.0.4
Compiler Version: 3.2.0

winni

  • Hero Member
  • *****
  • Posts: 2666
Re: I Need Creativity
« Reply #3 on: July 26, 2021, 05:12:04 pm »
Hi!

Just draw the 3D rectangle aat position x in another eye-catching color.

That should be possible without big graphic knowledge.

Winni


Handoko

  • Hero Member
  • *****
  • Posts: 4328
  • My goal: build my own game engine using Lazarus
Re: I Need Creativity
« Reply #4 on: July 26, 2021, 05:14:51 pm »
I would suggest paint those sides with semitransparent color, 60% black for example:

Weitentaaal

  • Sr. Member
  • ****
  • Posts: 278
Re: I Need Creativity
« Reply #5 on: July 26, 2021, 05:19:13 pm »
Thanks Guys for your Time

I would suggest paint those sides with semitransparent color, 60% black for example:


I like this 1 how exactly did u do this ?  :-[

Hi!

Just draw the 3D rectangle aat position x in another eye-catching color.

That should be possible without big graphic knowledge.

Winni



i came to this point but i don't realy know anything about overlapping and Transparence.

Could u guys give me a little start help ?

@Handokos Solution would be Perfect

EDIT: i should be able to draw the rectangles like @Handoko did but where do i set its Transparence.
« Last Edit: July 26, 2021, 05:21:22 pm by Weitentaaal »
Lazarus: 2.0.6 x86_64-win64-win32/win64
FPC-Version: 3.0.4
Compiler Version: 3.2.0

Handoko

  • Hero Member
  • *****
  • Posts: 4328
  • My goal: build my own game engine using Lazarus
Re: I Need Creativity
« Reply #6 on: July 26, 2021, 05:20:49 pm »
I draw them using Inkscape, not Lazarus.  :D

If you want to 'emphasize' them further, you can also make the edges brown:
« Last Edit: July 26, 2021, 05:23:05 pm by Handoko »

Handoko

  • Hero Member
  • *****
  • Posts: 4328
  • My goal: build my own game engine using Lazarus
Re: I Need Creativity
« Reply #7 on: July 26, 2021, 05:30:58 pm »
Could u guys give me a little start help ?

That should be doable using TOpenGLControl or BGRABitmap. I think TCanvas is possible too but may run very slow.

I usually will take the challenge, unfortunately I am a bit busy recently. How I would do it, I won't draw rectangles. I would treat all of them as layering images, I would load pre-generate png files and put them on the screen on correct z-order. The z-order should be like this:

7. Brown lines for the splitter edges (upper Z)
6. A horizontal line
5. Semi-transparent splitter (half, upper Z)
4. Purple-green-orange rectangles
3. Brown lines for the splitter edges (lower Z)
2. Semi-transparent splitters (half, lower Z)
1. Three horizontal edges (for the lowest Z)

If you pay attention, you would see the splitters and brown lines are divided in half and being put on the screen twice (first the lower, then the upper). That's the trick!

Previously, we have Graphics/Games Contest every years but it's been stopped for a while. Maybe you can start a graphics contest for this case.
« Last Edit: July 26, 2021, 06:03:07 pm by Handoko »

winni

  • Hero Member
  • *****
  • Posts: 2666
Re: I Need Creativity
« Reply #8 on: July 26, 2021, 07:55:32 pm »
Hi!

A BGRAbitmap solution. Quick & dirty.

I made all walls semitransparent.
X,Y, Z angles can be changed between 0 .. 90 degrees

Project & screenshoot attached.

Winni

Weitentaaal

  • Sr. Member
  • ****
  • Posts: 278
Re: I Need Creativity
« Reply #9 on: July 27, 2021, 07:43:34 am »
Thank u guys,

currently using TCanvas on a TImage to draw my 3d Field.
Does not Lag (until now) so i will try doing it with TCanvas but for my next graphical i would definitely choose BGRAbitmap.

Winnie your Code was Nice ! did help me out a lot to understand more about graphics .
Could u guys give me a little start help ?

That should be doable using TOpenGLControl or BGRABitmap. I think TCanvas is possible too but may run very slow.

I usually will take the challenge, unfortunately I am a bit busy recently. How I would do it, I won't draw rectangles. I would treat all of them as layering images, I would load pre-generate png files and put them on the screen on correct z-order. The z-order should be like this:

7. Brown lines for the splitter edges (upper Z)
6. A horizontal line
5. Semi-transparent splitter (half, upper Z)
4. Purple-green-orange rectangles
3. Brown lines for the splitter edges (lower Z)
2. Semi-transparent splitters (half, lower Z)
1. Three horizontal edges (for the lowest Z)

If you pay attention, you would see the splitters and brown lines are divided in half and being put on the screen twice (first the lower, then the upper). That's the trick!

Previously, we have Graphics/Games Contest every years but it's been stopped for a while. Maybe you can start a graphics contest for this case.



Lets see if i can bring this to Life :D

Thanks again for ur Time and Effort :)
Lazarus: 2.0.6 x86_64-win64-win32/win64
FPC-Version: 3.0.4
Compiler Version: 3.2.0

Seenkao

  • Full Member
  • ***
  • Posts: 221
Re: I Need Creativity
« Reply #10 on: July 27, 2021, 08:42:53 am »
I think TCanvas is possible too but may run very slow.
Нет, это может работать достаточно быстро. Мы просто рисуем во второй буфер и выводим в один момент.  ::) Я делал таким образом игру, работает неплохо.
Но конечно же лучше использовать OpenGL или что-то подобное.

google trandslate:
No, it might work fast enough. We just draw to the second buffer and output in one moment. ::) I made a game this way, it works well.
But of course it's better to use OpenGL or something similar.

Weitentaaal

  • Sr. Member
  • ****
  • Posts: 278
Re: I Need Creativity
« Reply #11 on: July 27, 2021, 09:15:55 am »
I think TCanvas is possible too but may run very slow.
Нет, это может работать достаточно быстро. Мы просто рисуем во второй буфер и выводим в один момент.  ::) Я делал таким образом игру, работает неплохо.
Но конечно же лучше использовать OpenGL или что-то подобное.

google trandslate:
No, it might work fast enough. We just draw to the second buffer and output in one moment. ::) I made a game this way, it works well.
But of course it's better to use OpenGL or something similar.

Next time i will use something else :D

We are lifelong learners and today I learned that in the future I will not use Canvas anymore xD

Got it this works :

Code: Pascal  [Select][+][-]
  1.  
  2. Procedure DrawTeilungen(cX, cY : Double; dir : TDirection);
  3. var
  4.    CurColor : TColor;
  5. begin
  6.    If dir = dirNone then Exit;
  7.  
  8.    //Aktuelle Farbe merken und dannach wiederherstellen
  9.    CurColor:= StartUp.Drw.Canvas.Brush.Color;
  10.  
  11.    Case dir of
  12.       dirRight : begin
  13.          Teilungen[0].x:= XDrw(cX + CubeSize);
  14.          Teilungen[0].Y:= YDrw(cY + CubeSize);
  15.          Teilungen[3].x:= XDrw(cX + CubeSize - CubeSize / 2);
  16.          Teilungen[3].Y:= YDrw(cY - CubeSize / 2);
  17.          Teilungen[2].x:= XDrw(cX + CubeSize - CubeSize / 2);
  18.          Teilungen[2].Y:= YDrw(cY + CubeSize - CubeSize / 2);
  19.          Teilungen[1].x:= XDrw(cX + CubeSize);
  20.          Teilungen[1].Y:= YDrw(cY);
  21.          Teilungen[4].x:= XDrw(cX + CubeSize);
  22.          Teilungen[4].Y:= YDrw(cY + CubeSize);
  23.       end;
  24.       dirLeft: begin
  25.          Teilungen[0].x:= XDrw(cX);
  26.          Teilungen[0].Y:= YDrw(cY + CubeSize);
  27.          Teilungen[1].x:= XDrw(cX - CubeSize / 2);
  28.          Teilungen[1].Y:= YDrw(cY + CubeSize - CubeSize / 2);
  29.          Teilungen[2].x:= XDrw(cX - CubeSize / 2);
  30.          Teilungen[2].Y:= YDrw(cY - CubeSize / 2);
  31.          Teilungen[3].x:= XDrw(cX);
  32.          Teilungen[3].Y:= YDrw(cY);
  33.          Teilungen[4].x:= XDrw(cX);
  34.          Teilungen[4].Y:= YDrw(cY + CubeSize);
  35.       end;
  36.    end;
  37.  
  38.    StartUp.Drw.Canvas.Brush.Color := clRed;
  39.    StartUp.Drw.Canvas.Polygon(Teilungen);
  40.    StartUp.Drw.Canvas.Brush.Color := CurColor;
  41. end;
  42.  
Lazarus: 2.0.6 x86_64-win64-win32/win64
FPC-Version: 3.0.4
Compiler Version: 3.2.0

 

TinyPortal © 2005-2018