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.


Messages - Port

Pages: 1 ... 25 26 27 28 29 [30] 31 32 33 34 35 ... 1041
436
It's high time to transition to Torque 3D.
But of course Badspot will never do that and we will end up using a 20-year-old game engine.

Torque 3D still uses TorqueScript though...?

437
CBMHost (if they have any open slots), HamHost (very promising), LugHost (very promising as well), BAM (I am not sure if they will have hosting - but if they do, I grant you that they'll be as big as RTB was). They're all equally good picks.

It's not going to run a hosting service, though it's not entirely unlikely that there will be some slight degree of integration in terms of LugHost servers.

438
This explains a lot about why function calls are so slow.
http://www.cuppadev.co.uk/2012/10/optimizing-torquescript/

439
Modification Help / Re: Finding a paint closest color
« on: March 23, 2014, 01:45:08 PM »
HSV distance instead of RGB distance

440
i'm pretty sure it just died restarted it, it's back it's dead again

The server randomly locks up. Either get rid of /list or add pagination (/list?start=n).

442
I was planning on using '0.0.0.0'.

Unless all forum users have IP 0.0.0.0 (which is reversed and cannot be assigned by a ISP, so they don't) and have been playing Blockland recently, that would just be rejected by the server.

443
Off Topic / Re: I love port.
« on: March 23, 2014, 03:05:52 AM »
i'm scared

444
Modification Help / Re: Finding a paint closest color
« on: March 23, 2014, 02:46:18 AM »
time to overkill everything

function min(%a0, %a1, %a2, %a3, %a4, %a5, %a6, %a7, %a8, %a9,
  %a10, %a11, %a12, %a13, %a14, %a15, %a16, %a17, %a18, %a19)
{
  for (%n = 20; %n > 0; %n--)
    if (%a[%n - 1] !$= "")
      break;

  %min = %a0;

  for (%i = 1; %i < %n; %i++)
    if (%a[%i] < %min)
      %min = %a[%i];

  return %min;
}

function max(%a0, %a1, %a2, %a3, %a4, %a5, %a6, %a7, %a8, %a9,
  %a10, %a11, %a12, %a13, %a14, %a15, %a16, %a17, %a18, %a19)
{
  for (%n = 20; %n > 0; %n--)
    if (%a[%n - 1] !$= "")
      break;

  %ax = %a0;

  for (%i = 1; %i < %n; %i++)
    if (%a[%i] > %min)
      %max = %a[%i];

  return %max;
}

function RGBtoHSV(%rgb)
{
  %r = getWord(%rgb, 0);
  %g = getWord(%rgb, 1);
  %b = getWord(%rgb, 2);

  %min = min(%r, %g, %b);
  %max = max(%r, %g, %b);

  %value = %max;
  %delta = %max - %min;

  if (%max != 0)
    %saturation = %delta / %max;
  else
    return "-1 0" SPC %value;

  if (%r == %max)
    %hue = (%g - %b) / %delta;
  else if (%g == %max)
    %hue = 2 + (%b - %r) / %delta;
  else
    %hue = 4 + (%r - %g) / %delta;

  %hue *= 60;

  if (%hue < 0)
    %hue += 360;

  return %hue SPC %saturation SPC %value;
}

function colorDifference(%rgba1, %rgba2)
{
  %a1 = getWord(%rgba2, 3);
  %a2 = getWord(%rgba2, 3);

  %hsv1 = RGBtoHSV(%rgba1);
  %hsv2 = RGBtoHSV(%rgba2);

  return vectorDist(%hsv1, %hsv2) + (%a2 - %a1) * 45;
}

function findBestSprayColor(%rgba)
{
  %best = -1;

  for (%i = 0; %i < 64; %i++)
  {
    %color = getColorIDTable(%i);
    %value = colorDifference(%rgba, %color);

    if (%diff $= "" || %value < %diff)
    {
      %diff = %value;
      %best = %i;
    }
  }

  return %best;
}

445
just saying, json is horrible at space efficiency

... your point is? In "{"name": "Brian Smith", "blid": 8437}", space efficiency is not an issue.

446
%player.hideNode("ALL");

447
Off Topic / Re: I love port.
« on: March 22, 2014, 05:53:55 PM »
jesus christ

448
Suggestions & Requests / Re: Please make TCP Object support classes
« on: March 22, 2014, 05:45:21 PM »
Well it's not "broken", it's just not meant to be. class and superClass are features of ScriptObject/ScriptGroup objects and aren't intended to be used anywhere else.

449
Games / Re: Sub Rosa - Next version available for Pre-Order!
« on: March 22, 2014, 02:22:43 PM »
-snip-

450
Off Topic / Re: Post regarding Post regarding Ravencroft
« on: March 22, 2014, 01:55:56 PM »
... what? It was a joke topic. Why was Betel even banned? I've seen like 2-3 topics joking about somebody dying in the last week or so.

Pages: 1 ... 25 26 27 28 29 [30] 31 32 33 34 35 ... 1041