x_ite-off-parser 1.0.2 → 1.0.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -1,5 +1,10 @@
1
1
  # x_ite-off-parser
2
2
 
3
+ [![npm Version](https://img.shields.io/npm/v/x_ite-off-parser)](https://www.npmjs.com/package/x_ite-off-parser)
4
+ [![Build Size](https://img.shields.io/bundlephobia/minzip/x_ite-off-parser)](https://bundlephobia.com/package/x_ite-off-parser)
5
+ [![jsDelivr Hits](https://data.jsdelivr.com/v1/package/npm/x_ite-off-parser/badge?style=rounded)](https://create3000.github.io/jsdelivr-download-stats/?username=create3000&repository=x_ite)
6
+ [![npm Downloads](https://img.shields.io/npm/dm/x_ite-off-parser)](https://npmtrends.com/x_ite-off-parser)
7
+
3
8
  OFF 3D File Format Parser for [X_ITE](https://create3000.github.io/x_ite/)
4
9
 
5
10
  ## Usage
@@ -8,10 +13,10 @@ Include the script after X_ITE:
8
13
 
9
14
  ```html
10
15
  <script defer src="https://cdn.jsdelivr.net/npm/x_ite@15.0.3/dist/x_ite.min.js"></script>
11
- <script defer src="https://cdn.jsdelivr.net/npm/x_ite-off-parser@1.0.2/dist/x_ite-off-parser.js"></script>
16
+ <script defer src="https://cdn.jsdelivr.net/npm/x_ite-off-parser@1.0.3/dist/x_ite-off-parser.min.js"></script>
12
17
  <!-- or as ES module -->
13
18
  <script type="module" src="https://cdn.jsdelivr.net/npm/x_ite@15.0.3/dist/x_ite.min.mjs"></script>
14
- <script type="module" src="https://cdn.jsdelivr.net/npm/x_ite-off-parser@1.0.2/dist/x_ite-off-parser.js"></script>
19
+ <script type="module" src="https://cdn.jsdelivr.net/npm/x_ite-off-parser@1.0.3/dist/x_ite-off-parser.min.js"></script>
15
20
  ```
16
21
 
17
22
  Now you can load OFF files:
@@ -233,14 +233,14 @@ class OffParser extends X3D .X3DParser
233
233
 
234
234
  if (this .int32 ())
235
235
  {
236
- colors .push (this .value / 255);
236
+ const r = this .value / 255;
237
237
 
238
238
  if (this .int32 ())
239
239
  {
240
- colors .push (this .value / 255);
240
+ const g = this .value / 255;
241
241
 
242
242
  if (this .int32 ())
243
- colors .push (this .value / 255);
243
+ colors .push (r, g, this .value / 255);
244
244
  }
245
245
  }
246
246
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "x_ite-off-parser",
3
- "version": "1.0.2",
3
+ "version": "1.0.3",
4
4
  "description": "OFF 3D File Format Parser for X_ITE",
5
5
  "main": "dist/x_ite-off-parser.js",
6
6
  "module": "dist/x_ite-off-parser.js",