Help! Object removal.. and adding
#1

On the GM i edit and shit.. uuh, it's something wrong when I add new objects and I can't get midostreamer to work right. Like half of the CreateObject()'
s dissapear and the other lines are like this:
Quote:

{968, 592.5351, -2272.6128, 20.2332, 0.0000, 269.7591, 180.0000, 500.0}

but still wont show more then half of the objects i add, i think. :P and now i can't delete what i got there cause then i get:
Quote:

C:\Users\Hampus\Desktop\Freeroam\gamemodes\freeroa m.pwn(211) : error 029: invalid expression, assumed zero
C:\Users\Hampus\Desktop\Freeroam\gamemodes\freeroa m.pwn(211) : error 008: must be a constant expression; assumed zero
Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase


2 Errors.

Reply
#2

are you using 500 as draw distance for all objects? if so, add some constants like
#DEFINE ViewDistanceS=20
#DEFINE ViewDistanceM=50
#DEFINE ViewDistanceL=200
#DEFINE ViewDistanceXL=1000
and dont forget to use the high definitions rarely. the streamer never caused any trouble for me, so iam not sure if its the objects maximum exceeded in your case :/
gl anyways
Reply
#3

Amm, I don't have a streamer.. ?
I never downloaded mido or anything..
Reply
#4

if you want an example for a working FS to add/remove objects using midostreamer, have a look at that one:
Код:
#define FILTERSCRIPT

#include <a_samp>
#include <midostream>

#if defined FILTERSCRIPT
new StuntPark[240];
new DrawDistanceL=100;
new DrawDistanceH=500;

public OnFilterScriptInit()
{
	new h=1;
	new Float:X,Float:Y,Float:Z,Float:A;
	for(new i = 0; i<359; i+=10)
	{
		//rampen von aussen nach innen
		X=1430+(50*floatsin(i,degrees));
		Y=1600+(50*floatcos(i,degrees));
		Z=10.82;
		A=(-i+180)%360;
		StuntPark[h]=CreateStreamObject(1655,X,Y,Z,0,0,A,DrawDistanceH);h++;//ramp
		//rampen von innen nach aussen
		X=1430+(43.3*floatsin(i,degrees));
		Y=1600+(43.3*floatcos(i,degrees));
		Z=10.82;
		A=(-i)%360;
		StuntPark[h]=CreateStreamObject(1655,X,Y,Z,0,0,A,DrawDistanceH);h++;//ramp
		//lichter
		X=1430+(46.65*floatsin(i,degrees));
		Y=1600+(46.65*floatcos(i,degrees));
		Z=12.32;
		A=(-i+180)%360;
		StuntPark[h]=CreateStreamObject(3666,X,Y,Z,0,0,A,DrawDistanceH);h++;//ramp
		//glaeser ueber den rampen (nur von aussen sichtbar)
		for(new g=1;g<3;g++)
		{
			X=1430+((50-g*5)*floatsin(i,degrees));
			Y=1600+((50-g*5)*floatcos(i,degrees));
			Z=12.82+g*1.6;
			A=(-i+180)%360;
			StuntPark[h]=CreateStreamObject(1649,X,Y,Z+2,30,0,A+45,DrawDistanceL);h++;//glas
		}
	}
}

public OnFilterScriptExit()
{
  for(new h=1;h<240;h++)
  {
    DestroyStreamObject(StuntPark[h]);
  }
  return 1;
}

#else

main()
{
	print("Ramps at LV Airport");
}

#endif
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)