Author Topic: HELP: SPINWHEEL  (Read 3421 times)

CiTrON

  • Newbie
  • *
  • Posts: 6
    • View Profile
HELP: SPINWHEEL
« on: April 18, 2020, 12:21:22 AM »
what is the mathematics of this?

Code: [Select]
local wheel_x = [ flx*0.08, flx*0.08, flx*0.08, flx*0.08, flx*0.08, flx*0.08, flx*0.06, flx*0.08, flx*0.08, flx*0.08, flx*0.08, flx*0.08, ];
local wheel_y = [ -fly*0.22, -fly*0.105, fly*0.0, fly*0.105, fly*0.215, fly*0.325, fly*0.436, fly*0.61, fly*0.72 fly*0.83, fly*0.935, fly*0.99, ];
local wheel_w = [ flw*0.20, flw*0.20, flw*0.20, flw*0.20, flw*0.20, flw*0.20, flw*0.24, flw*0.20, flw*0.20, flw*0.20, flw*0.20, flw*0.20, ];
local wheel_h = [ flw*0.07, flw*0.07, flw*0.07, flw*0.08, flw*0.08, flw*0.08, flw*0.11, flw*0.07, flw*0.07, flw*0.07, flw*0.07, flw*0.07, ];
local wheel_a = [ 201, 201, 201, 201, 201, 201, 255, 201, 201, 201, 201, 201, ];
local wheel_r = [ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, ];
local num_arts = 5;

how do i calculate wheel_x and wheel_y for my theme?

(example of how I plan to customize) ↓


yiri

  • Jr. Member
  • **
  • Posts: 13
    • View Profile
Re: HELP: SPINWHEEL
« Reply #1 on: May 03, 2020, 04:42:16 AM »
esta chevere , por que no ayudaran a estas cuestiones , también tengo la duda como hacen para colocar cuadros de juegos diferentes animados en pantalla que se puedan escoger entre ellos los juegos.

Yaron2019

  • Guest
Re: HELP: SPINWHEEL
« Reply #2 on: May 03, 2020, 08:25:30 AM »
These are arrays - imagine a chain of cells tied to each other, each containing data - in this case a number calculated from the height and width of the screen. fly is the height, flx is the width. The advantage of making a calculation of fly*0.8 for example is that, in theory, no matter the resolution of the screen, the placement will be the same. Each cell in the arrays in question represent a single wheel logo art.

So what you need for your style of wheel is something like this:
the x location of each wheel logo art on the screen:
local wheel_x = [ flx*0.2, flx*0.2, flx*0.2, flx*0.2, flx*0.2, flx*0.2, flx*0.2, flx*0.2, flx*0.2, flx*0.2, flx*0.2, flx*0.2, ];

the y location of each wheel logo art on the screen:
local wheel_y = [ -fly*0.22, -fly*0.105, fly*0.0, fly*0.105, fly*0.215, fly*0.325, fly*0.436, fly*0.61, fly*0.72 fly*0.83, fly*0.935, fly*0.99, ];

wheel_w = the width of the logos
wheel_h = the height of the logos
wheel_a = the alpha value of the logos (opacity)
local wheel_r = the rotation value of the logos