Jump to content


Photo

Exciting No Limits Discovery


  • This topic is locked This topic is locked
6 replies to this topic

#1 Kevin Dice

Kevin Dice

    Peta-Coaster Member

  • Admin
  • 782 posts

Posted 21 August 2011 - 03:19 AM

I just tried out the NLtrack C library, a library coded in C that opens and modifies nltrack files.

I just made a successful working program with the library. The program I wrote is completely useless, but I think we all can appreciate what awesome potential this has.
This program adds another track node. You specify the location in XYZ coordinates of the node, control point 1, and control point 2. You also can specify the banking of the node. I could have easily included the individual track color option, the individual track colors, the track segment type, and more....but, I didn't because it is 3am.

If I could make an open GL graphical interface like the one in the No Limits editor, I may be able to make a practical No Limits tool.

The libnltrack library and this useless program are distributed under the GNU GPL v2 Licence. A copy of the licence text can be found here: GNU GPL v2 Licence

You can download the node adder program here: Useless Node Adder Note: The captcha is in the advertisement.

I found it interesting that I could put the control points anywhere I want (don't have to be co-linear). Of course when you try to move them in the NL Editor, they snap back to being co-linear. This is really the only special thing that this node adder can do.
Example picture:
Posted Image


If anyone has a request for a simple but very necessary NL tool, post your suggestions here. Keep in mind: Doing simple, repetitive tasks is something that's easy to do.
Posted ImageEmail: kevindice@coaster-net.com
By the way... You just lost The Game.

#2 CPF

CPF

    COASTER-net Dedicated Member

  • Members
  • PipPipPipPipPipPip
  • 1,348 posts

Posted 21 August 2011 - 08:49 AM

Wow. Thats pretty sweet. Maybe you can compete with Newton 2 :cheese:

Edited by CPF, 21 August 2011 - 08:49 AM.

Posted Image


#3 Kevin Dice

Kevin Dice

    Peta-Coaster Member

  • Admin
  • 782 posts

Posted 21 August 2011 - 11:26 AM

Haha, Not for a while on that one. We'll see how the OpenGL interface goes first. I'm almost completely new to C. I've only done a few things in C++ before so some of the stuff caries over.

Right now, I have one idea for a useful program. Say you have a total of 12+ brake, transport, or station segments in your track. Normally you would have to open the track settings for each segment individually and then edit the transport speed, max acceleration G's, max deceleration G's, transport type, etc...and repeat 11 more times for each track segment. I could write a program that does this when you type values into a prompt. It would save about 2 or 3 minutes of time.

Ex. of the program output:
Enter a 1 to modify all transport segments or a 0 to leave them alone:
Enter a 1 to modify all brake segments or a 0 to leave them alone:
Enter a 1 to modify all station segments or a 0 to leave them alone:
For each of the following values, enter a value of the requested format, or enter 'N' to make no change to that value.
Enter an integer or decimal for the Speed value in km/h:
Enter a whole number or positive decimal for the acceleration value: 
Enter a whole number or positive decimal for the deceleration value:
Enter a 0 for friction wheels or a 1 for LIMs:
Enter a 1 to hide transport device or a 0 to make it visible:
Enter a 1 for left catwalk and a 0 for no left catwalk:
Enter a 1 for right catwalk and a 0 for no right catwalk:


Anyone want a program like this?

Edit: I made some progress on the OpenGL. It's nothing at all so far; just two shapes with a color fade between vertices.
Clicky

Posted ImageEmail: kevindice@coaster-net.com
By the way... You just lost The Game.

#4 Silver Swordsman

Silver Swordsman

    Peta-Coaster Member

  • Members
  • PipPipPipPipPip
  • 864 posts

Posted 21 August 2011 - 07:20 PM

I'm excited about this! It may not seem like much, but I agree, the implications are enormous. Just a question Kev, d'ya think there's any way to mess with the simulator? (More advanced graphics, etc)?
Posted Image
The High Speed Rail Project... in RCT3.
(*Voted Best DE Author of 2010)

#5 Kevin Dice

Kevin Dice

    Peta-Coaster Member

  • Admin
  • 782 posts

Posted 21 August 2011 - 08:50 PM

I think trying to recompile it would be in violation of the licence agreement. I think there's a way to easily export the coordinates of the track node bezier curves to an array, then import them into blender. From blender, I may be about to make a model of a train follow the path. I could also export a 3ds version of the track from the constructionkit and line it up with the train path. Not sure how long it will be before I try it.
Posted ImageEmail: kevindice@coaster-net.com
By the way... You just lost The Game.

#6 Tyler Carlton

Tyler Carlton

    COASTER-net Dedicated Member

  • Members
  • PipPipPipPipPipPip
  • 1,850 posts

Posted 21 August 2011 - 09:05 PM

That seems somewhat like entropy is doing with this:


Although I'm not totally sure if its the same thing, I've never used Blender before.
Posted Image
Sig by me, if you would like one of a similar fashion pm me.

#7 Kevin Dice

Kevin Dice

    Peta-Coaster Member

  • Admin
  • 782 posts

Posted 21 August 2011 - 09:11 PM

^I saw that two days ago. It's exactly what I'm going for. Except, I think I want to design my own train type and make it look as much like NL as possible. That way people will be angry that I have an extra train type that they don't. Posted Image

And something I love about blender:
When you hover over ANY button you will get the python function that the button calls.
When you drag down the "File" bar across the top of the page, you see all of the most previously executed commands. I can generate the complete add bezier curve import python syntax by using the data from the nl track file.

I just need to figure the syntax out first. Won't be long.

Edit:
There exists no blender python function to select the control points of the various nodes of the bezier curve. So, I will have to figure it out later.
I am able though to select the nodes themselves.

Anything you can select you can put in the correct spot, so until I can select the control points, I can't put them where they need to be...and I can't recreate a no limits track in blender.
...yet.
Posted ImageEmail: kevindice@coaster-net.com
By the way... You just lost The Game.




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users