[No Limits 1&2] Questions et problèmes (Archives)

Statut
Ce sujet est verrouillé
Bonjour à tous, je voulais savoir comment faire pour changer et mettre le jour a la place de la nuit sur un track je trouve pas :| mise a part les paramètres que j'ai mis tout le Temp en jour dans le menu

Edit modolillois : Fais attention à ton orthographe et ta ponctuation, je ne comprends pas le sens de ta phrase et a mon avis, peu de monde comprend.
 
Salut quelqu'un saurait comment fonctionne ces deux scripts:

Code:
import com.nolimitscoaster.*;
import nlvm.math3d.*;

/* **************************************************************************
This is a generic object attachment script.

Directions to use this script. 
1) Copy and paste attach_object.nlvm to the same directory as your .nl2sco file.
2) Open the NL2SCO Editor and go to the Scripts tab.
3) Select attach_object.nlvm from the Script Class dialog.
4) Save the file and Refresh the scene object.

View the in-game Help for creating .nl2sco files for your 3D models.

It is unlikely that your object will be positioned exactly where you want it at first.
You can modify the positional offset off the 3D model by adding or subtracting 
from xOffset, yOffset, zOffset below.
*************************************************************************** */


public class attach_object extends Script
{
	// ====== CUSTOMIZABLE VARIABLES =======
	// Note: Decimal point "float" values must be followed by an 'f' (e.g. 0.5f, -9.205f). Whole values do not need the 'f'. 
	private static final float xOffset = 0; // left/right
    private static final float  yOffset = 0.0f; //up/down
    ExternalRideView pov;
float xOffset_cam1 = 0.0000000001f;
    float  yOffset_cam1 = -0.5f;
   float  zOffset_cam1 = 0.0f;
    private static final float  zOffset = 0; //back/forth
	private static final float range = 5;	// The first train within this range of the scene object will receive the attachment. (range is in meters)
	private static final int carToAttach = 32; // Defines the car on the train that will receive the attachment. (0 = lead car or zero car)
	// ======================================
	
	private SceneObject sco;	// Scenery object handle.
	private Train train;	// Train handle.
	private Vector3f posOut = new Vector3f(0,0,0);	// Will store the scenery object's position based on the car's position.
	private Vector3f pitchHeadBankOut = new Vector3f(0,0,0);	// Will store the scenery object's orientation based on the car's orientation.
	private Matrix4x4f carMatrix = new Matrix4x4f();	// Will store the car's orientation.
		
	//**************************************************************************************
	// onInit is called when the scene object is loaded. Use this for initialization. 
	// onInit should return true if initialization succeeds, else false. 
	// If onInit returns false then the script will be disabled automatically and onNextFrame will never be called.
	//**************************************************************************************
	public bool onInit()
	{			
		
		
		// ********************************************
		// Get the scene object handle.
		// ********************************************
		sco = sim.getSceneObjectForEntityId(getParentEntityId());
		if (sco == null)
		{
			System.err.println("attach_object.nlvm: This script must be assigned to a scene object.");
			return false;
		}
		
		// ********************************************
		// Determine if there is a track within range of the scenery object.
		// ********************************************
		TrackPos trackPos = sim.findNearestCoasterTrack(sco.getTranslation(), range);
		if (trackPos == null)
		{
			System.err.println("attach_object.nlvm: No track found within range of " + range + " meters.");
			return false;
		}
		
		// ********************************************
		// Determine if there is a train within range of the scenery object.
		// ********************************************
		Coaster coaster = trackPos.getCoaster();
		train = coaster.findNearestTrain(sco.getTranslation(), range);
		if (train == null)
		{
			System.err.println("attach_object.nlvm: No train found within range of " + range + " meters.");
			return false;
		}
		
		pov = sim.createExternalRideView();
		pov.setEnterWarpPointEnabled(true);
		pov.setLabel("Magnus Nose Cam");

		return true;
	}
	

	
	public void onNextFrame(float tick)
	{
		// ********************************************
		// Obtain the orientation matrix of the last car
		// ********************************************
		train.getCarMatrix(carToAttach, carMatrix);
		
		// ********************************************
		// Convert the matrix obtained from getCarMatrix()
		// to the Euler angle vector used in setRotation()
		// ********************************************
		Tools.matrixToPitchHeadBankPos(carMatrix, pitchHeadBankOut, posOut);

		// ********************************************
		// Calculate XYZ offset
		// ********************************************
		Matrix4x4f matrix = new Matrix4x4f();
		matrix.initTrans(xOffset, yOffset, zOffset);
		carMatrix.multRight(matrix);

Matrix4x4f matrixCamera = new Matrix4x4f();
		// ********************************************
		// Update the scene object's rotation and 
		// position for this frame.
		// ********************************************

		Tools.matrixToPitchHeadBankPos(carMatrix, pitchHeadBankOut, posOut);
		sco.setRotation(pitchHeadBankOut);
		sco.setTranslation(posOut);

matrixCamera.initTrans(xOffset_cam1, yOffset_cam1, zOffset_cam1);
		pov.setEnterWarpPoint(posOut,(float)10);	
	carMatrix.multRight(matrixCamera);
			pov.setCameraMatrix(carMatrix);
		
		
	}
}

et

Code:
import com.nolimitscoaster.*;
import nlvm.math3d.*;

/* **************************************************************************
This is a generic object attachment script.

Directions to use this script. 
1) Copy and paste attach_object.nlvm to the same directory as your .nl2sco file.
2) Open the NL2SCO Editor and go to the Scripts tab.
3) Select attach_object.nlvm from the Script Class dialog.
4) Save the file and Refresh the scene object.

View the in-game Help for creating .nl2sco files for your 3D models.

It is unlikely that your object will be positioned exactly where you want it at first.
You can modify the positional offset off the 3D model by adding or subtracting 
from xOffset, yOffset, zOffset below.
*************************************************************************** */


public class crossties extends Script implements TrackTriggerListener
{
	// ====== CUSTOMIZABLE VARIABLES =======
	// Note: Decimal point "float" values must be followed by an 'f' (e.g. 0.5f, -9.205f). Whole values do not need the 'f'. 
	private static final float xOffset = 0; // left/right
    private static final float  yOffset = 0.0f; //up/down
    private static final float  zOffset = 0; //back/forth

	
	
	//restraints
	private static final float range = 5;	// The first train within this range of the scene object will receive the attachment. (range is in meters)
	private static final int carToAttach = 1; // Defines the car on the train that will receive the attachment. (0 = lead car or zero car)
	// ======================================
	
	private SceneObject sco;	// Scenery object handle.
	private Train train;	// Train handle.

	
	private Vector3f posOut = new Vector3f(0,0,0);
		// Will store the scenery object's position based on the car's position.
	private Vector3f pitchHeadBankOut = new Vector3f(0,0,0);	// Will store the scenery object's orientation based on the car's orientation.
	private Matrix4x4f carMatrix = new Matrix4x4f();	// Will store the car's orientation.
	private SceneObjectElement[] lb1 = new SceneObjectElement[32];
	//**************************************************************************************
	// onInit is called when the scene object is loaded. Use this for initialization. 
	// onInit should return true if initialization succeeds, else false. 
	// If onInit returns false then the script will be disabled automatically and onNextFrame will never be called.
	//**************************************************************************************
	public bool onInit()
	{									
		// ********************************************
		// Get the scene object handle.
		// ********************************************
		sco = sim.getSceneObjectForEntityId(getParentEntityId());
		if (sco == null)
		{
			System.err.println("attach_object.nlvm: This script must be assigned to a scene object.");
			return false;
		}
		


		
		// ********************************************
		// Determine if there is a track within range of the scenery object.
		// ********************************************
		//TrackPos trackPos = sim.findNearestCoasterTrack(sco.getTranslation(), range);
		//if (trackPos == null)
		//{
		//	System.err.println("attach_object.nlvm: No track found within range of " + range + " meters.");
		//	return false;
		//}
		
		// ********************************************
		// Determine if there is a train within range of the scenery object.
		// ********************************************
		 coaster = sim.getCoaster("crossties");

		train = coaster.getTrainAt(0);
		if (train == null)
		{
			System.err.println("attach_object.nlvm: No train found within range of " + range + " meters.");
			return false;
		}
		

		for(int i = 0; i < lb1.length; i++){
		System.out.print(i);
		lb1[i] = sco.getElementForName(i + "");
		train.getCarMatrix(i, carMatrix);

		Tools.matrixToPitchHeadBankPos(carMatrix, pitchHeadBankOut, posOut);

		//Matrix4x4f matrix = new Matrix4x4f();
		//matrix.initTrans(xOffset, yOffset, zOffset);
		//carMatrix.multRight(matrix);
		Tools.matrixToPitchHeadBankPos(carMatrix, pitchHeadBankOut, posOut);

		lb1[i].setRotation(pitchHeadBankOut);
		lb1[i].setTranslation(posOut);
}


		
		return true;
	}
	
	Coaster coaster = null;
	
	
	
	public void onNextFrame(float tick)
	{
	
	
	
	
	
	}
	
	public void onTrainLeaving(TrackTrigger trigger, Train train){
	
	}
	public void onTrainEntering(TrackTrigger trigger, Train train){
	
	}
}

car je voudrais positionner mes crossties mais elles ne s'alignent pas avec mon train, pourtant j'ai fait comme dans la vidéo :

https://www.youtube.com/watch?feature=player_detailpage&v=8Uz9ajB1e8U&list=UUImmBRQd9966Wn3kMPXfJWQ

J'ai essayé de modifier les valeurs mais ça change rien... donc je sais pas trop comment faire.
 
bonjour a tous,je voudrait savoir comment faire sur les spinning coaster (maurer,zamperla etc..) pour bloquer la rotation des nacelle dans les zone de frein par exemple.

cordialement

bonne journée a tous
 
cedric77 a dit:
bonjour a tous,je voudrait savoir comment faire sur les spinning coaster (maurer,zamperla etc..) pour bloquer la rotation des nacelle dans les zone de frein par exemple.

cordialement

bonne journée a tous
Tu mets un trigger et tu définies l'action.
 
Salut tout le monde. J'ai un problème. J'ai restauré mon ordinateur et j'ai réinstallé No Limits 2 et il me met le fameux code d’erreur 0xc000007b. Il me manque pas mal de fichier DLL. Je tourne sous 64 bits et bon je suis bloqué je peut pas utiliser NL. Est ce que quelqu'un sait comment faire à part télécharger un pack complet de DLL ?
Merci
 
Oui, car ce n'est pas un Closed (Puisqu'il passe plusieurs fois en station), et ce n'est pas un Shuttle (Car le circuit est une boucle).
 
Si, y'a moyen, seulement il faut que tu créer un nouveau park, puis que tu importes ton coaster à partir de là. :wink:
 
cedric77 a dit:
bonjour a tous,je voulais savoir si les fichier no limit 1 sont compatible avec no limit 2,en gros si on peut rider les track de nolimit 1 sur le 2
ttfun13 a dit:
Et bien malheureusement , non .
Enfin avec moi , ça marche pas ...
KingRCT3 a dit:
Si, y'a moyen, seulement il faut que tu créer un nouveau park, puis que tu importes ton coaster à partir de là. :wink:

Personnellement moi NL2 exécute très bien les .nltrack (fichier de NL1), même le terrain et tous !
Il faut juste choisir "All supported files" dans filetype (quand tu cherche ton ride)

Par contre si t'es fichiers de ride NL1 sont locker ("Fichier de compatibilité"), se qui est souvent le cas pour les rides de NL1, il faut aller les copier/coller quelque part pour enlevé le lock ! Sinon tu n'y aura pas accès =)
 
Bien le bonjour,

Quelqu'un pourrait-il me dire comment changer les textures au sol ?
Je ne parle pas de tout le terrain, juste faire au "pinceau" une partie du terrain du style plus granuleux en dessous du coaster etc car quand je veux le faire, j'ai un message d'erreur qui s'affiche.
Est ce due au fait que je n'ai pas la version Pro ?

Bonne journée à tous !
 
Normalement, tu ajoutes une texture terrain qui n'est pas en autopaint. Puis tu la sélectionnes dans le menu de la colonne de gauche du terrain et tu click paint en choisissant la grandeur des pixels ...  et tu peints !
Et si tu as des carrés rouges, il te faut defreezer .
 
Statut
Ce sujet est verrouillé