Jump to content

Custom FPS model not visible after pickup - how to debug?


blueapples
 Share

Recommended Posts

I've created a custom fbx model and imported it, then set it up similar to an existing melee prefab.

 

This is wired up to a pickup object running PickupWeapon.lua, with it's VWep value set to the exported prefab of my custom model.

 

Here are the two prefabs on the scene for visual comparison:

 

post-17500-0-86103600-1468347125_thumb.png

 

These are the settings for the custom prefab root:

 

post-17500-0-26400000-1468347148.png

 

The original machete prefab had the second rotation value set to 180, but because my model appears to be 180 degree turned, I have it set to 0.

 

The issue I'm running into is that when the pickup triggers, it seems to work -- the weapon is available, pressing fire plays the sound attached to the prefab, etc. But the weapon isn't actually visible:

 

post-17500-0-56853800-1468347349_thumb.png post-17500-0-37528900-1468347361_thumb.png

 

I have tried values between 1-100 for rotation and offset without luck.

 

How should I go about debugging this? I can't inspect the item while it's running so it's hard to know what is setup incorrectly.

Link to comment
Share on other sites

Wow you weren't kidding they are very finicky... finally got something that sort of works though!

 

post-17500-0-41982900-1468410420_thumb.png

 

Obviously needs some work still, but thank you for the tips!

 

Another thing that helped a lot was to make a new map and just wire up the FPSPlayer to the weapon like you suggested. This loads a lot faster than my real map and made tweaking a lot easier.

 

One other thing that helped was to play with the scale value slowly until the model was at least visible, and rotate around the second rotation point by 30 or so degrees at a time to try to find the prefab. Then the rest was just trial and error.

 

I had also started working on a mod for FPSPlayer that would let you make adjustments in the game itself to try to "find" the prefab basically, maybe I'll finish that at some point.

  • Upvote 3
Link to comment
Share on other sites

Looking good.

I think you can also go a decimal point or two smaller for even more precise tweaking, eg 0.002

 

You will also want to test your weapon for clipping through walls and objects to get the scale and positioning the way you like it.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

×
×
  • Create New...