Skip to content

Commit 5577484

Browse files
committed
Added LightHouse & Updated Docs
_The beginnings of a lighthouse has been added to The Outlet _pxlNav Home doc has been updated
1 parent 9e05d6f commit 5577484

File tree

65 files changed

+91
-64
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

65 files changed

+91
-64
lines changed
32.5 KB
Loading
-7.92 KB
Loading
51.8 KB
Loading
389 KB
Loading
-20.2 KB
Binary file not shown.
74.1 KB
Loading

docs/js/pxlRooms/OutletEnvironment/OutletEnvironment.js

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -231,6 +231,21 @@ builBugs(){
231231

232232
// Add some bugs jumping in the grass
233233
this.builBugs();
234+
235+
if( this.geoList.hasOwnProperty('LightHouse_geo') ){
236+
let lhMtl = this.geoList['LightHouse_geo'].material;
237+
if( lhMtl.map && !lhMtl.emissiveMap ){
238+
lhMtl.emissiveMap = lhMtl.map;
239+
lhMtl.emissive.set( 0x404040 );
240+
}
241+
// Certain material types in programs don't support AlphaMaps as it seems
242+
// I'll need to investigate which programs have which limitations in what materials
243+
if( !lhMtl.alphaMap ){
244+
lhMtl.alphaMap = this.pxlUtils.loadTexture( this.assetPath+"LightHouseA_alpha.jpg" );
245+
lhMtl.transparent = true;
246+
lhMtl.alphaTest = .05;
247+
}
248+
}
234249

235250
// Adding a basic ambient light
236251
var ambientLight = new AmbientLight( 0x383838 ); // soft white light

docs/js/pxlRooms/OutletEnvironment/Shaders/envGroundShaders.js

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -177,7 +177,13 @@ export function envGroundFrag( pointLightCount ){
177177
float baseDirtNoise = dirtNoise;
178178
179179
180-
// -- -- --
180+
// -- -- -- -- -- -- -- -- -- -- -- -- --
181+
// -- Texture Offset by Position atan -- --
182+
// -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
183+
184+
vec2 atanVec = normalize( vec2( vModelPos.x + vModelPos.y*.5, vModelPos.z + vModelPos.y*.1 ) );
185+
float deg = atan( atanVec.y, atanVec.x );
186+
deg = cos(deg*PI*2.0);
181187
182188
// -- -- -- -- -- -- -- -- -- --
183189
// -- World Space Texturing - -- --
@@ -198,7 +204,7 @@ export function envGroundFrag( pointLightCount ){
198204
vec3 grassCd = texture2D( grassDiffuse, pos.xz*2.0 + uvNoiseOffset ).rgb ;
199205
200206
// Shift the rocky hill texture so it reads it more horizontally
201-
vec2 hillLayerUv = vec2( subUv.x+uv.y*.1, vModelPos.y*.007 ) ;
207+
vec2 hillLayerUv = vec2( subUv.x+uv.y*.5 + deg, vModelPos.y*.007 ) ;
202208
vec3 rockyHillCd = texture2D(hillDiffuse,hillLayerUv).rgb ;
203209
204210
// -- -- --

docs/pxlNav-docs/global.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2857,7 +2857,7 @@ <h5 class="h5-examples">Examples</h5>
28572857
<br class="clear">
28582858

28592859
<footer>
2860-
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 4.0.4</a> on Wed Mar 05 2025 09:06:53 GMT-0500 (Eastern Standard Time) using the <a href="https://github.com/clenemt/docdash">docdash</a> theme.
2860+
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 4.0.4</a> on Wed Mar 05 2025 11:44:14 GMT-0500 (Eastern Standard Time) using the <a href="https://github.com/clenemt/docdash">docdash</a> theme.
28612861
</footer>
28622862

28632863
<script>prettyPrint();</script>

docs/pxlNav-docs/index.html

Lines changed: 12 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -63,11 +63,17 @@ <h3> </h3>
6363

6464
<section class="readme usertext">
6565
<article><h1>pxlNav v0.0.26 Documentation</h1>
66-
<p><strong>For <code>pxlRoom</code> help, see <a href="pxlRoom%2520RoomEnvironment.html">pxlRoom RoomEnvironment</a></strong></p>
67-
<p><br/>   <strong>For an Environment to roam around in FPV, visit <a href="https://procstack.github.io/Outlet.htm">procstack.github.io/Outlet.htm</a></strong></p>
68-
<p align='center'><img src='../assets/pxlNav_TheOutlet_2025-2-9_Coastline_sm.webp' alt="pxlNav Example The Outlet" /></p>
69-
<p><br/>Since the pxlNav Docs are still being created,
70-
<br/>   If you need help, feel free to ask on <a href="https://discord.gg/D8kMgtBsmp">pxlNav Support</a> discord group.</p></article>
66+
<p>These are the docs for <strong><code>pxlNav</code></strong>
67+
<br>   A javascript Player Controller &amp; Environment Manager for Three.js</p>
68+
<p><strong>Since the docs are still being written,</strong>
69+
<strong><br>   If you have any questions / feedback, feel free to join the <a href="https://discord.gg/UqEY9mpZ9x">pxlNav Support</a> discord group.</strong></p>
70+
<p align='center' style='margin: 0px;'>
71+
<b>If you'd like to roam around a coastal environment,</b>
72+
<br/><sub>vvv&nbsp;&nbsp; </sub><b>visit <a href="https://procstack.github.io/Outlet.htm" alt="pxlNav Example The Outlet" target="_blank">procstack.github.io/Outlet.htm</a></b><sub>&nbsp;&nbsp; vvv</sub>
73+
<h5 style='margin: 0px;'><a href="https://procstack.github.io/Outlet.htm" style="border-width: 0px;" target="_blank"><img src='../assets/pxlNav_TheOutlet_2025-2-9_Coastline_sm.webp' alt="pxlNav Example The Outlet" /></a></h5></p>
74+
<p align='right' style="color: rgba(113, 131, 171, .88);margin-right: 3vw;">
75+
<i>Created by <a href="https://github.com/ProcStack" alt="ProcStack github profile" target="_blank">Kevin Edzenga</a>; <sub>2000,2024-2025</suv></i>
76+
</p></article>
7177
</section>
7278

7379

@@ -82,7 +88,7 @@ <h3> </h3>
8288
<br class="clear">
8389

8490
<footer>
85-
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 4.0.4</a> on Wed Mar 05 2025 09:06:53 GMT-0500 (Eastern Standard Time) using the <a href="https://github.com/clenemt/docdash">docdash</a> theme.
91+
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 4.0.4</a> on Wed Mar 05 2025 11:44:14 GMT-0500 (Eastern Standard Time) using the <a href="https://github.com/clenemt/docdash">docdash</a> theme.
8692
</footer>
8793

8894
<script>prettyPrint();</script>

0 commit comments

Comments
 (0)