Neo-Docklights OXP

Discussion and information relevant to creating special missions, new ships, skins etc.

Moderators: winston, another_commander

User avatar
Thargoid
Thargoid
Thargoid
Posts: 5528
Joined: Thu Jun 12, 2008 6:55 pm

Neo-Docklights OXP

Post by Thargoid »

A simple little OXP based on a suggestion by Disembodied.

For systems of tech level 3 or more, it adds a trail of green docking lights in front of the main station (between it and the buoy). Designed to guide newer commanders into the dock, just follow them in whilst matching the station rotation as normal.

The lights also temporarily turn red when the station launches a ship, as a warning.

Download via box or the wiki as normal, from the links below.
Last edited by Thargoid on Wed Jan 09, 2013 6:42 pm, edited 1 time in total.
User avatar
JazHaz
---- E L I T E ----
---- E L I T E ----
Posts: 2991
Joined: Tue Sep 22, 2009 11:07 am
Location: Enfield, Middlesex
Contact:

Re: Docklights OXP

Post by JazHaz »

Cool. Downloading.
User avatar
JazHaz
---- E L I T E ----
---- E L I T E ----
Posts: 2991
Joined: Tue Sep 22, 2009 11:07 am
Location: Enfield, Middlesex
Contact:

Re: Docklights OXP

Post by JazHaz »

Here's a screenshot of the OXP in action.

Image
DockLights OXP by JazHaz, on Flickr
JazHaz

Gimi wrote:
drew wrote:
£4,500 though! :shock: <Faints>
Cheers,
Drew.
Maybe you could start a Kickstarter Campaign to found your £4500 pledge. 8)
Thanks to Gimi, I got an eBook in my inbox tonight (31st May 2014 - Release of Elite Reclamation)!
User avatar
SandJ
---- E L I T E ----
---- E L I T E ----
Posts: 1048
Joined: Fri Nov 26, 2010 9:08 pm
Location: Help! I'm stranded down here on Earth!

Re: Docklights OXP

Post by SandJ »

Lovely. Downloaded and installed straight away!

An observation: it makes it very clear the pilot's position is not necessarily in the centre of the ship; in a Cobbie III they are most definitely below. It may be worth mentioning this on the Wiki and in the ReadMe otherwise newbies will find it confusing.

Personally, where I currently have a "Fuel Scoop Camera" view, I have now added two "Docking Lights Centred" views (as custom_views in my SandJ shipdata-overrides.plist)

Bug: by launching, then docking using Shift-C, then launching again, the docklights do not appear near to the station; they start about 1.9km from the Dodecahedron Station.

Also, I have launched from a busy station and stopped and watched as a succession of ships launched after me; the red / green switching does not appear to be consistent. They can be flashing green when a 2nd ship comes out. Also, you don't get any warning that a ship is coming, do you? They just go red. I can imagine why: I assume there is no way to tell a ship is going to launch in 5 seconds.
Flying a Cobra Mk I Cobbie 3 with nothing but Explorers Club.OXP and a beam laser 4 proper lasers for company :D
Dropbox referral link 2GB of free space online + 500 Mb for the referral: good for securing work-in-progress.
richard.a.p.smith
Deadly
Deadly
Posts: 174
Joined: Mon Jun 07, 2010 9:03 am

Re: Docklights OXP

Post by richard.a.p.smith »

Nice one, another bit of ambience - thanks!

There seems to be a clash with jump planner/long range scanner. I just put docklights in and when doing a "jump to system" it does one jump to the first system and stops. If you try again it leaves a wormhole behind (didn't stop to look at where the wormhole was going, though) but you don't jump anywhere. I don't think docking and launching gets rid of this behaviour, you just make a wormhole, but I think it does get rid of the landing strip lights. I removed docklights and jump planner worked okay. Put it back, problem reappeared. Ah, logs, hang on . . . let me have a look . . .

19:18:10.942 [shipData.load.warning.turret.badWeaponRange]: ----- WARNING: ball turret weapon range of 20000 for subenitity of ship aquatics_pirateDestroyer is too high, using 7500.

Off-topic already, oops! There are a whole load of these things in the log. I don't think it's related but in case anyone reads this and sees something that needs work . . .

. . . oh, er, no other errors noted in the log.

Rich
User avatar
SandJ
---- E L I T E ----
---- E L I T E ----
Posts: 1048
Joined: Fri Nov 26, 2010 9:08 pm
Location: Help! I'm stranded down here on Earth!

Re: Docklights (actually v1.76.1 + Aquatics + turret range)

Post by SandJ »

richard.a.p.smith wrote:

Code: Select all

19:18:10.942 [shipData.load.warning.turret.badWeaponRange]: ----- WARNING: ball turret weapon range of 20000 for subenitity of ship aquatics_pirateDestroyer is too high, using 7500.
Off-topic already, oops!
Certainly is. :lol: I take it you are running the new v1.76.1, yes? From this post:
Ahruman wrote:
Changes since version 1.76:
  • weapon_range and weapon_energy keys in the turret subentity declaration now work as intended. Values are maximised at 7500 and 100 respectively.
I am guessing an update to the Aquatics OXP will come from Thargoid in due course.
Flying a Cobra Mk I Cobbie 3 with nothing but Explorers Club.OXP and a beam laser 4 proper lasers for company :D
Dropbox referral link 2GB of free space online + 500 Mb for the referral: good for securing work-in-progress.
User avatar
Thargoid
Thargoid
Thargoid
Posts: 5528
Joined: Thu Jun 12, 2008 6:55 pm

Re: Docklights OXP

Post by Thargoid »

The Aquatics update should already be there for download - I think I already fixed that problem? Can you check that your installation of the OXP is up to date (it should be v2.28).

The Docklights colour change is just triggered by the launch (so no, it's not possible to give advanced warning as the colour change is based on the ship launched event), so it sounds like things are going a bit out of synch and the second ship is either getting delayed or is appearing within 10s of the first one (the lights just turn red for 10s then go green again).

I'll have a play with it anyway and see if I can make it a bit more robust, and if I can replicate the Dodec issue. And yes, it does rather show up how off-axis some ship views are. It doesn't usually get in the way of docking, but it perhaps is worth documenting anyway.
User avatar
SandJ
---- E L I T E ----
---- E L I T E ----
Posts: 1048
Joined: Fri Nov 26, 2010 9:08 pm
Location: Help! I'm stranded down here on Earth!

Re: Docklights OXP

Post by SandJ »

Thargoid wrote:
The Docklights colour change is just triggered by the launch (so no, it's not possible to give advanced warning as the colour change is based on the ship launched event)
I thought as much. Still, it is easier to see the lights go red than spot an emerging small ship.
Thargoid wrote:
it does rather show up how off-axis some ship views are. It doesn't usually get in the way of docking, but it perhaps is worth documenting anyway.
It is actually beneficial in making a newbie think about using their external views (if they even know they are there) and appreciating that manually docking into the centre of the rectangle is not always safe, even in a Cobra Mk III.
Flying a Cobra Mk I Cobbie 3 with nothing but Explorers Club.OXP and a beam laser 4 proper lasers for company :D
Dropbox referral link 2GB of free space online + 500 Mb for the referral: good for securing work-in-progress.
richard.a.p.smith
Deadly
Deadly
Posts: 174
Joined: Mon Jun 07, 2010 9:03 am

Re: Docklights OXP

Post by richard.a.p.smith »

Thargoid wrote:
Can you check that your installation of the OXP is up to date (it should be v2.28).
Yes, it's 2.28. I'll keep an eye out for a docklights update, it's a neat idea, just that I use the jump planner fairly often. Rich.
User avatar
SandJ
---- E L I T E ----
---- E L I T E ----
Posts: 1048
Joined: Fri Nov 26, 2010 9:08 pm
Location: Help! I'm stranded down here on Earth!

Re: Docklights OXP

Post by SandJ »

Regarding lights not stretching from the station to the beacon consistently, here's two screen dumps showing 'clumping' of some of the lights.

Image

Image
Flying a Cobra Mk I Cobbie 3 with nothing but Explorers Club.OXP and a beam laser 4 proper lasers for company :D
Dropbox referral link 2GB of free space online + 500 Mb for the referral: good for securing work-in-progress.
User avatar
Commander McLane
---- E L I T E ----
---- E L I T E ----
Posts: 9520
Joined: Thu Dec 14, 2006 9:08 am
Location: a Hacker Outpost in a moderately remote area
Contact:

Re: Docklights OXP

Post by Commander McLane »

Thargoid wrote:
The Docklights colour change is just triggered by the launch (so no, it's not possible to give advanced warning as the colour change is based on the ship launched event), so it sounds like things are going a bit out of synch and the second ship is either getting delayed or is appearing within 10s of the first one (the lights just turn red for 10s then go green again).
Yes, there are ships that take less than 10 seconds to launch after the previous ship. I think it depends on ship size, or perhaps on the speed with which the previous ship can clear the launch area, but the rules are not clear to me.
another_commander
Quite Grand Sub-Admiral
Quite Grand Sub-Admiral
Posts: 6682
Joined: Wed Feb 28, 2007 7:54 am

Re: Docklights OXP

Post by another_commander »

In my opinion (and this would probably be the easiest way too), when launching traders with escorts, lights should remain red until the entire convoy has departed.
User avatar
Eric Walch
Slightly Grand Rear Admiral
Slightly Grand Rear Admiral
Posts: 5536
Joined: Sat Jun 16, 2007 3:48 pm
Location: Netherlands

Re: Docklights OXP

Post by Eric Walch »

Commander McLane wrote:
Yes, there are ships that take less than 10 seconds to launch after the previous ship. I think it depends on ship size, or perhaps on the speed with which the previous ship can clear the launch area, but the rules are not clear to me.
The minimum interval is set at 6.0 seconds. But, for a launch, the area, up to a distance of 2000 meters in front of a dock must also be clear of ships. If not clear, a new launch time is scheduled for 2 seconds later.
Most ships don't clear the corridor fast, so the interval mainly depends how fast a ship gets 2000 meter away from the dock, or how fast he deviates from the straight line. (dot product < 0.86, means: > 30.7 degr deviation)
Only stuff < 1000 kg will not block the launches (cargo pods) or a station in red_alert will not wait for a free corridor. So, a player can't hold off defenders when hovering himself in front of the port and than shooting at a station. :lol:
another_commander wrote:
In my opinion (and this would probably be the easiest way too), when launching traders with escorts, lights should remain red until the entire convoy has departed.
Good idea, check the group property and look if none of the members still has the status: STATUS_DOCKED.
User avatar
Thargoid
Thargoid
Thargoid
Posts: 5528
Joined: Thu Jun 12, 2008 6:55 pm

Re: Docklights OXP

Post by Thargoid »

At the moment if the 10s timer is running then it's not restarted - I'll change it so that each launch does restart. That way things should work as needed. That will also cover escorts, as I presume anything that launches will trigger the stationLaunchedShip event, not just the mother of a convoy.

I'm just a bit confused about the problem (and images) that SandJ reports. There's nothing in the spawning bit of the code that could do that:

Code: Select all

	var loopCounter = 0 ; // reset the counter
	for(loopCounter = 0; loopCounter < 40;loopCounter++)
		{
		system.addShips("dockLights_green", 1, system.mainStation.position.add(system.mainStation.vectorForward.multiply(500 + loopCounter * 250)), 0);
		}
[/color]
User avatar
SandJ
---- E L I T E ----
---- E L I T E ----
Posts: 1048
Joined: Fri Nov 26, 2010 9:08 pm
Location: Help! I'm stranded down here on Earth!

Re: Docklights OXP

Post by SandJ »

Thargoid wrote:
I'm just a bit confused about the problem (and images) that SandJ reports.
I assume you have witnessed the "launch, see the lights are OK, dock, launch, see the lights start 2km away" problem - I can reproduce it every time.
Thargoid wrote:
I'm just a bit confused about the problem (and images) that SandJ reports. There's nothing in the spawning bit of the code that could do that
Launch and see the pretty green flashers, all in a row. Fly about in the system generally going about your business. Fly back toward the station and the meanie greenies have been for a wander too:

Image

"Aha!" I hear you cry. "But what OXPs have you got installed, eh, eh?" I foresaw that, so I have created it again with just Docklights & Debug installed. Have a Latest.log:

Code: Select all

17:14:12.967 [log.header]: Opening log for Oolite version 1.76.1 (x86-64 test release) under Linux at 2012-06-06 17:14:12 +0000.
4 processors detected.
Build options: spoken messages, mass/fuel pricing, JavaScript console support, OXP verifier, localization tools, debug GraphViz support, JavaScript profiling.

Note that the contents of the log file can be adjusted by editing logcontrol.plist.

17:14:13.091 [display.mode.list.native]: X11 native resolution detected: 1280 x 1024
17:14:13.255 [joystick.init]: Number of joysticks detected: 0
17:14:13.280 [dataCache.rebuild.explicitFlush]: Cache explicitly flushed with shift key. Rebuilding from scratch.
17:14:13.280 [rendering.opengl.version]: OpenGL renderer version: 4.2.0 ("4.2.0 NVIDIA 295.53"). Vendor: "NVIDIA Corporation". Renderer: "GeForce GTX 550 Ti/PCIe/SSE2".
17:14:13.280 [rendering.opengl.extensions]: OpenGL extensions (265):
GL_ARB_draw_instanced, GL_NV_texture_lod_clamp, GL_NV_float_buffer, GL_NV_vertex_attrib_integer_64bit, GL_ARB_occlusion_query, GL_EXT_texture_env_add, GL_ARB_texture_storage, GL_ARB_texture_env_dot3, GL_ARB_sync, GL_EXTX_framebuffer_mixed_formats, GL_ARB_texture_multisample, GL_NV_texture_env_combine4, GL_ARB_point_parameters, GL_OES_depth24, GL_ARB_vertex_array_object, GL_NVX_gpu_memory_info, GL_NV_vertex_buffer_unified_memory, GL_ARB_blend_func_extended, GL_NV_explicit_multisample, GL_EXT_provoking_vertex, GL_NV_texture_shader2, GL_EXT_blend_equation_separate, GL_ARB_compressed_texture_pixel_storage, GL_NV_texture_shader3, GL_ARB_texture_non_power_of_two, GL_ARB_texture_mirrored_repeat, GL_EXT_multi_draw_arrays, GL_NV_fence, GL_ARB_timer_query, GL_ARB_texture_buffer_object, GL_OES_packed_depth_stencil, GL_NV_occlusion_query, GL_EXT_abgr, GL_ARB_vertex_program, GL_NV_shader_buffer_load, GL_ATI_texture_float, GL_ARB_draw_buffers_blend, GL_ARB_viewport_array, GL_KTX_buffer_region, GL_ARB_shadow, GL_NV_light_max_exponent, GL_EXT_texture_cube_map, GL_EXT_texture_compression_dxt1, GL_ARB_shader_atomic_counters, GL_NV_texture_multisample, GL_NV_primitive_restart, GL_EXT_framebuffer_object, GL_EXT_texture_sRGB, GL_ARB_conservative_depth, GL_ARB_get_program_binary, GL_ARB_multitexture, GL_NV_half_float, GL_NV_copy_image, GL_NV_path_rendering, GL_OES_depth32, GL_NV_register_combiners, GL_EXT_texture_compression_rgtc, GL_ARB_shader_objects, GL_EXT_blend_func_separate, GL_EXT_bgra, GL_ARB_pixel_buffer_object, GL_ARB_vertex_attrib_64bit, GL_NV_fragment_program2, GL_EXT_Cg_shader, GL_ARB_draw_buffers, GL_EXT_separate_shader_objects, GL_NV_texgen_reflection, GL_ARB_texture_env_crossbar, GL_ARB_fragment_shader, GL_EXT_texture_swizzle, GL_EXT_fog_coord, GL_EXT_vertex_array_bgra, GL_EXT_framebuffer_blit, GL_NV_copy_depth_to_color, GL_ARB_texture_compression_rgtc, GL_ARB_sample_shading, GL_NV_vertex_program1_1, GL_ARB_seamless_cube_map, GL_EXT_texture_shared_exponent, GL_ARB_shading_language_420pack, GL_ARB_shader_subroutine, GL_EXT_texture_format_BGRA8888, GL_EXT_geometry_shader4, GL_EXT_direct_state_access, GL_EXT_compiled_vertex_array, GL_NV_parameter_buffer_object2, GL_ARB_shader_image_load_store, GL_NV_vertex_array_range2, GL_ARB_shading_language_include, GL_EXT_texture_storage, GL_EXT_shader_image_load_store, GL_EXT_separate_specular_color, GL_ARB_vertex_type_2_10_10_10_rev, GL_NV_vdpau_interop, GL_EXT_vertex_array, GL_ARB_shading_language_100, GL_OES_texture_float, GL_EXT_rescale_normal, GL_ARB_texture_float, GL_EXT_packed_depth_stencil, GL_EXT_bindable_uniform, GL_ARB_texture_swizzle, GL_ARB_half_float_pixel, GL_EXT_texture_compression_s3tc, GL_EXT_draw_instanced, GL_ARB_occlusion_query2, GL_NV_transform_feedback, GL_NV_texture_compression_vtc, GL_ARB_texture_rgb10_a2ui, GL_SGIS_texture_lod, GL_ARB_geometry_shader4, GL_NV_point_sprite, GL_ARB_framebuffer_object, GL_NV_conditional_render, GL_EXT_stencil_two_side, GL_ARB_texture_rg, GL_OES_get_program_binary, GL_NV_texture_expand_normal, GL_EXT_texture_type_2_10_10_10_REV, GL_ARB_color_buffer_float, GL_NV_gpu_program4_1, GL_NV_framebuffer_multisample_coverage, GL_EXT_blend_color, GL_NV_packed_depth_stencil, GL_NV_geometry_shader4, GL_NV_texture_rectangle, GL_ARB_vertex_array_bgra, GL_EXT_texture_integer, GL_EXT_texture_array, GL_ARB_base_instance, GL_EXT_import_sync_object, GL_ARB_shading_language_packing, GL_ARB_fragment_program_shadow, GL_NV_gpu_program4, GL_NV_fragdepth, GL_EXT_texture_buffer_object, GL_OES_standard_derivatives, GL_NV_vertex_program2_option, GL_NV_gpu_program5, GL_ARB_map_buffer_range, GL_ARB_fragment_program, GL_ARB_copy_buffer, GL_NV_blend_minmax, GL_ARB_tessellation_shader, GL_NV_gpu_shader5, GL_S3_s3tc, GL_NV_depth_clamp, GL_EXT_texture_lod_bias, GL_EXT_texture_filter_anisotropic, GL_EXT_draw_buffers2, GL_OES_texture_3D, GL_NV_fragment_program, GL_EXT_secondary_color, GL_ARB_transform_feedback2, GL_ARB_transform_feedback3, GL_EXT_framebuffer_multisample, GL_ARB_window_pos, GL_IBM_rasterpos_clip, GL_EXT_texture_env_combine, GL_ARB_vertex_shader, GL_ARB_texture_compression_bptc, GL_SGIS_generate_mipmap, GL_ARB_compatibility, GL_ATI_texture_mirror_once, GL_EXT_packed_float, GL_ARB_texture_border_clamp, GL_ARB_explicit_attrib_location, GL_NV_blend_square, GL_ARB_internalformat_query, GL_EXT_texture3D, GL_SUN_slice_accum, GL_NV_vertex_array_range, GL_ARB_ES2_compatibility, GL_NV_vertex_program, GL_ARB_texture_query_lod, GL_NV_multisample_filter_hint, GL_EXT_texture_mirror_clamp, GL_EXT_texture_sRGB_decode, GL_ARB_texture_compression, GL_NV_vertex_program2, GL_NV_multisample_coverage, GL_ARB_texture_env_add, GL_ARB_imaging, GL_NV_vertex_program3, GL_ARB_provoking_vertex, GL_EXT_gpu_shader4, GL_ARB_texture_rectangle, GL_EXT_texture_edge_clamp, GL_NV_transform_feedback2, GL_OES_texture_half_float_linear, GL_ARB_draw_elements_base_vertex, GL_ARB_fragment_coord_conventions, GL_OES_texture_half_float, GL_ARB_separate_shader_objects, GL_SGIX_shadow, GL_ARB_texture_cube_map, GL_EXT_transform_feedback2, GL_NV_alpha_test, GL_OES_vertex_array_object, GL_EXT_framebuffer_sRGB, GL_NV_fragment_program_option, GL_EXT_texture_compression_latc, GL_ARB_robustness, GL_ARB_point_sprite, GL_ARB_texture_gather, GL_ARB_texture_buffer_object_rgb32, GL_OES_depth_texture, GL_NV_depth_buffer_float, GL_ARB_depth_texture, GL_EXT_texture_object, GL_EXT_depth_bounds_test, GL_NV_fog_distance, GL_ARB_instanced_arrays, GL_EXT_blend_minmax, GL_SGIX_depth_texture, GL_ATI_draw_buffers, GL_ARB_framebuffer_sRGB, GL_NV_fbo_color_attachments, GL_EXT_blend_subtract, GL_NV_register_combiners2, GL_EXT_packed_pixels, GL_IBM_texture_mirrored_repeat, GL_NV_texture_shader, GL_EXT_draw_range_elements, GL_ARB_texture_cube_map_array, GL_ARB_sampler_objects, GL_ARB_half_float_vertex, GL_OES_mapbuffer, GL_ARB_shader_precision, GL_ARB_gpu_shader5, GL_OES_rgb8_rgba8, GL_ARB_depth_clamp, GL_ARB_transpose_matrix, GL_NV_parameter_buffer_object, GL_ARB_vertex_buffer_object, GL_ARB_draw_indirect, GL_EXT_pixel_buffer_object, GL_EXT_vertex_attrib_64bit, GL_ARB_transform_feedback_instanced, GL_OES_texture_npot, GL_NVX_conditional_render, GL_ARB_texture_env_combine, GL_OES_vertex_half_float, GL_ARB_shader_bit_encoding, GL_EXT_timer_query, GL_EXT_gpu_program_parameters, GL_ARB_uniform_buffer_object, GL_ARB_multisample, GL_EXT_texture_env_dot3, GL_OES_texture_float_linear, GL_NV_shader_atomic_counters, GL_EXT_shadow_funcs, GL_EXT_texture_lod, GL_ARB_depth_buffer_float, GL_NV_pixel_data_range, GL_ARB_map_buffer_alignment, GL_ARB_gpu_shader_fp64, GL_EXT_stencil_wrap, GL_OES_fbo_render_mipmap, GL_EXT_x11_sync_object, GL_EXT_point_parameters, GL_OES_element_index_uint, GL_NV_texture_barrier, GL_NV_gpu_program_fp64, GL_NV_complex_primitives
17:14:13.285 [rendering.opengl.shader.support]: Shaders are supported.
17:14:13.285 [speech.synthesis]: Spoken messages are off.
17:14:13.302 [dataCache.rebuild.explicitFlush]: Cache explicitly flushed with shift key. Rebuilding from scratch.
17:14:13.302 [searchPaths.dumpAll]: Unrestricted mode - resource paths:
    ~/GNUstep/Applications/Oolite/oolite.app/Resources
    AddOns
    AddOns/DockLights 1.00.oxp
    AddOns/Debug.oxp
17:14:13.389 [shipData.load.begin]: Loading ship data.
17:14:13.503 [script.javascript.init]: JavaScript reset successful.
17:14:13.510 [script.load.world.listAll]: Loaded 6 world scripts:
    dockLights_worldScript.js 1.00
    oolite-cloaking-device 1.76.1
    oolite-constrictor-hunt 1.76.1
    oolite-nova 1.76.1
    oolite-thargoid-plans 1.76.1
    oolite-trumbles 1.76.1
17:14:14.459 [loading.complete]: ========== Loading complete. ==========
17:14:14.499 [debugTCP.connected]: Connected to debug console "DebugConsole".
17:14:18.948 [script.javascript.init]: JavaScript reset successful.
17:14:18.954 [script.load.world.listAll]: Loaded 6 world scripts:
    dockLights_worldScript.js 1.00
    oolite-cloaking-device 1.76.1
    oolite-constrictor-hunt 1.76.1
    oolite-nova 1.76.1
    oolite-thargoid-plans 1.76.1
    oolite-trumbles 1.76.1
17:48:24.321 [screenshot]: Saved screen shot "oolite-059.png" (1280 x 952 pixels).
Flying a Cobra Mk I Cobbie 3 with nothing but Explorers Club.OXP and a beam laser 4 proper lasers for company :D
Dropbox referral link 2GB of free space online + 500 Mb for the referral: good for securing work-in-progress.
Post Reply