Important Message

You are browsing the archived Lancers Reactor forums. You cannot register or login.
The content may be outdated and links may not be functional.


To get the latest in Freelancer news, mods, modding and downloads, go to
The-Starport

Trade lane issues

The general place to discuss MOD''ing Freelancer!

Post Sat Apr 26, 2003 8:29 am

Trade lane issues

I've been lurking around here for awhile and changing everything that I can through tutorials and intuition, but have thus far been totally unsuccessful in adding trade lanes to my test system.

A forum search yielded no results with specific solutions, only vague references to the problem itself. If any of you modding veterans out there can craft a tutorial on this subject (not wholly avoiding y-axis traversal if possible... I'm not a fan of single-plane thinking in space games), I would be greatly appreciative.

On a side note, a single thread for discussion on the uncloaking problem would probably save quite a bit of time for some... I am a programmer but I'd rather not tackle the problem from scratch if I can learn from what has already been attempted, and perhaps contribute my own insights. It's just a thought.

By the way, I must compliment all of you on accumulating this great wealth of modding knowledge, especially considering how young Freelancer is. Thank you for putting your time and effort forth.

Edited by - CaseWorker on 26-04-2003 09:36:12

Post Sat Apr 26, 2003 11:40 pm

Well, after two hours or so of screwing around I've got an idea of what was wrong... if anyone else is curious here's what I've got on trade lanes:

The number of rings is inconsequential to the lane itself, although the game will have docking issues if you make a one-ring lane. The main component of a trade lane is its lane zone. The code for a zone is as follows:

[zone
nickname = Zone_Ar01_Tradelane_1
pos = -80000, 1000, 50000
rotate = 30, 270, 0
shape = BOX
size = 520, 520, 60520
comment = . Tradelane to nowhere
lane_id = Ar01_1
tradelane_down = 5
sort = 4
toughness = 10
density = 6
repop_time = 15
max_battle_size = 0
pop_type = major_tradelane
relief_time = 15
faction_weight = li_n_grp, 1

As you can tell, I copied most of this out of an existing system, so there's some clutter. Here's the breakdown:

nickname: this can be anything to my knowledge, as long as it is unique
pos: these are the x, y, z coordinates of the first ring in your lane
rotate: this is the orientation of the first ring in your lane - in this case my ring points slightly upward and to the 'east'
shape: leave this alone for now, I'm experimenting with non-BOX lanes but so far all I've gotten is "Dock Denied"
size: 520 is the default docking distance, and the box is already rotated to face in the direction of your first ring. This means the only coordinate you need to mess with is the depth, or z-coord. This MUST be as long as your trade lane, as this zone must encompass all of the rings in your lane.
comment: unnecessary, but useful sometimes
lane_id: make sure this is unique as well

Everything else has to do with encounters and interaction and such. For example, toughness has to do with the number of hits a ring can take before going down, and repop_time is how long before it comes back up. Mess with these based on your system density, traffic, etc...

The rest of your lane code has to do with the rings themselves. Here's a general format...

[Object
nickname = Ar01_Trade_Lane_Ring_1
ids_name = 260758
pos = -80000, 1000, 50000
rotate = 30, 270, 0
Archetype = Trade_Lane_Ring
ids_info = 66170
next_ring = Ar01_Trade_Lane_Ring_2
reputation = li_n_grp
tradelane_space_name = 252673
behavior = NOTHING
difficulty_level = 4
loadout = trade_lane_ring
pilot = pilot_solar_hard

[Object
nickname = Ar01_Trade_Lane_Ring_2
ids_name = 260758
pos = -65858, 10000, 50000
rotate = 30, 270, 0
Archetype = Trade_Lane_Ring
ids_info = 66170
prev_ring = Ar01_Trade_Lane_Ring_1
next_ring = Ar01_Trade_Lane_Ring_3
reputation = li_n_grp
behavior = NOTHING
difficulty_level = 4
loadout = trade_lane_ring
pilot = pilot_solar_hard

[Object
nickname = Ar01_Trade_Lane_Ring_3
ids_name = 260758
pos = -37574, 30000, 50000
rotate = 30, 270, 0
Archetype = Trade_Lane_Ring
ids_info = 66170
prev_ring = Ar01_Trade_Lane_Ring_2
reputation = li_n_grp
tradelane_space_name = 252674
behavior = NOTHING
difficulty_level = 4
loadout = trade_lane_ring
pilot = pilot_solar_hard

The first lane should have a next_ring but not a prev_ring. The middle lanes should have both. The final lane should have a prev_ring but not a next_ring. Also, the first ring and last rings should have tradelane_space_name set to the ids_name strings of their destinations. Freelancer automatically names each of the rings along the way based on which side of the ring you are on. The rotations on all of the rings should be the same. The positions should place the rings in a line. Basic trigonometry is all you need for this part. If anyone's desperate I'll post a guide on that, but there's some information on it elsewhere on the forums.

I don't know how interested anyone else is in the idea of angled trade lanes, multi-level systems, that sort of thing, but I've been messing with it and encountered only one problem... When going up an angled trade lane (or vertical, for that matter), the ship faces in the correct direction. When going down, however, the ship tilts upwards at the same angle, but while moving downwards. It's an aesthetic problem unless you happen to be in a cruiser that crashes against the lane mid-flight. I'm sorting through code to see if I can correct this, but I'd really appreciate any help anyone else can provide.

Post Fri Nov 21, 2003 12:42 am

escalator tradelanes... I feel sure I've covered this before somewhere

the game likes you to be 'level' like when you stop using mouse flight. this applies in tradelane code as well. however you can make the ships go up and down if you stack your rings like an escalator all upright and not angled down but in a descent of maybe 45' any steeper and you'll get 'lost' between rings.

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

having infiltrated so many government installations I am now availble in your local store

Post Fri Nov 21, 2003 3:27 am

Crikey - seven months old........lol

Post Fri Nov 21, 2003 7:02 am

QUOTE:
"pos: these are the x, y, z coordinates of the first ring in your lane"

Correction they are X, Z, Y cords *ex: 800, 700, 10000 = <-X->, up-Z-dwn, frnt-Y-bck* I just wanted to clarify this so thoese who are new to this don't get confused.

James "Quickshot14" Greenwood<br>
QSD (Quickshot14's Domain http://qsd.rgprod.net)<br>
Also Home of QFL & QWC (Quickshot's Freelancer & Warcraft 3 Site)

Return to Freelancer General Editing Forum