Need some help - random gives errors
#1

Код:
new Float: checkpoints[][0] =
{
  { -18.4717,2349.4331,24.1406 },
  { -439.3994,2229.5598,42.3833 },
  { -793.1042,2772.0095,45.6958 },
  { 637.9069,1686.1379,6.9871 },
};
Thats what I have, its meant as random spawns for checkpoints. But I get some errors:

Код:
error 029: invalid expression, assumed zero
error 008: must be a constant expression; assumed zero
Why?
Reply
#2

here you go:
Код:
new Float: checkpoints[][0] =
{
  { -18.4717,2349.4331,24.1406 },
  { -439.3994,2229.5598,42.3833 },
  { -793.1042,2772.0095,45.6958 },
  { 637.9069,1686.1379,6.9871 }
}
I think this will work now. but i am not sure....
Reply
#3

Код:
new Float: checkpoints[4][3] =
{
  { -18.4717,2349.4331,24.1406 },
  { -439.3994,2229.5598,42.3833 },
  { -793.1042,2772.0095,45.6958 },
  { 637.9069,1686.1379,6.9871 }
};
Reply
#4

All you need to do is remove the comma from the last coord and it will work
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)