• Strange problem with a model.
    11 replies, posted
I've been working on an fireaxe model, for a mod I'm currently working on. Now the thing is, I've created models before, but not weapons, just static objects. The problem itself is very strange. The model itself shows up in HLMV, and is fully compatible with the playermodels. However, I tried replacing the model with the crowbar view model, and it's giving me a strange error. [QUOTE] c_baseentity.cpp (1081) : Assertion Failed: !"Model could not be found, index is -1"[/QUOTE] I have no idea what the problem is, I've checked if it was the path, but it's ok. Then I tried seeing if it was the QC, but both QC's I used didn't work. After that I decided it might have been the texture or the bones. Both did not matter. So now my final plan was to see if anyone here can detect any mistake. Here's the QC files, and the crowbar script I changed abit. Any ideas?
You haven't posted any QCs and i'm not sure what your saying is the problem, is the world or view model not working? and what do you mean by: [QUOTE=Donald;23480413]I tried replacing the model with the crowbar view model[/quote] As im not at all sure what you mean by it, do you mean you tried to make a view model using the crowbar view model as a base and now it's not showing up? or is invisible when you replace the crowbar model with it?
You might be better off modeling AND animating the view model. You'd learn more and not have some weird error... Otherwise post qc's.
I actually did upload it, sadly I didn't upload. I'm beginning to think the model might be corrupt. So I'm just gonna try and make another one. QC files: [QUOTE]$modelname "weapons/w_fireaxe.mdl" $cdmaterials "models/weapons/w_models/w_fireaxe" $scale 1 $keyvalues { "prop_data" { "base" "metal.medium" } } $model fireaxe "w_fireaxe.smd" $sequence idle "idle" loop fps 15 $collisionmodel "w_fireaxe.smd" { $mass 3.0 // Mass in kilograms $concave } [/QUOTE] [QUOTE]$cd "D:\AgeOfEvo\modelsrc\world\fireaxe" $modelname "weapons\w_fireaxe.mdl" $body studio "w_fireaxe.smd" $cdmaterials "models\weapons\w_models\w_fireaxe\" $hboxset "default" //$hbox 0 "ValveBiped" 0.000 0.000 0.000 1.227 4.372 5.826 //$hbox 0 "ValveBiped.weapon_bone" -1.461 -6.015 -5.037 0.264 0.569 7.115 // Model uses material "w_pist_deagle.vmt" $surfaceprop "weapon" //$keyvalues { prop_data { "base" "Metal.Small" } } //$illumposition 6.470 0.629 1.581 $sequence idle "idle" fps 30.00 $collisionmodel "phymodel.smd" { $mass 5.0 $inertia 1.00 $damping 0.00 $rotdamping 0.00 } [/QUOTE]
you can just copy and paste qc's. Instead of uploading them to a filesharing site. It seems like your fireaxe model doesn't have any bones in it.
Hmm but it actually does. I've actually tested it with another model, and it gave the same thing. Could it be my smd exporter is broken, or could I be doing something wrong with the bones. I basically just have a model (editable poly, with UVW map) and I make a bone somewhere in the space, and name it to ValveBiped.Bip01_R_Hand. Then I use the skin modifier to link them. After that it's just export to smd and compile with QC. Anything wrong D:? Side note, the textures in HLMV are a bit transparent. VMT: [QUOTE]"VertexlitGeneric" { "$basetexture" "models/weapons/testaxe/testaxe" "$surfaceprop" "Metal" "$translucent" 1 }[/QUOTE]
Post the top 30 lines of your smd (again, just copy and paste it)
Both those qcs are compiling to the same model name so its likely one is either overwriting the other or is being used instead of the other. Also is the second one meant to be a v_model?
bad read, he's just trying to compile the model, he's saying neither of the qc's work...
They work, however when trying to use ingame they both give me the same error. Here is the smd lines for the 2 models I tried useing: Fireaxe: [QUOTE]version 1 nodes 0 "Cylinder01" -1 1 "ValveBiped.Bip01_R_Hand" -1 end skeleton time 0 0 -0.724390 -5.867972 -9.685064 0.000000 0.000000 -1.570796 1 0.793673 -5.912473 12.445477 1.570796 -0.000000 1.570796 end triangles fireaxe.png 0 -0.366632 -6.682904 -1.328521 0.243436 -0.969916 0.001370 0.199106 0.208740 1 1 1.000000 0 -0.804981 -6.735205 -1.304459 0.001221 -0.999685 0.025066 0.199939 0.225691 1 1 1.000000 0 -1.192434 -6.848619 -5.728047 0.020424 -0.999452 0.026042 0.046806 0.240674 1 1 1.000000 fireaxe.png 0 -1.192434 -6.848619 -5.728047 0.020424 -0.999452 0.026042 0.046806 0.240674 1 1 1.000000 0 -0.723624 -6.789479 -5.872417 0.269333 -0.963047 0.000684 0.041808 0.222545 1 1 1.000000 0 -0.366632 -6.682904 -1.328521 0.243436 -0.969916 0.001370 0.199106 0.208740 1 1 1.000000 fireaxe.png 0 0.018845 -6.532310 -1.349677 0.501108 -0.865080 -0.022973 0.198373 0.193834 1 1 1.000000 0 -0.366632 -6.682904 -1.328521 0.243436 -0.969916 0.001370 0.199106 0.208740 1 1 1.000000 0 -0.723624 -6.789479 -5.872417 0.269333 -0.963047 0.000684 0.041808 0.222545 1 1 1.000000 fireaxe.png 0 -0.723624 -6.789479 -5.872417 0.269333 -0.963047 0.000684 0.041808 0.222545 1 1 1.000000 0 -0.311359 -6.619191 -5.999374 0.529408 -0.847991 -0.025277 0.037413 0.206603 1 1 1.000000 0 0.018845 -6.532310 -1.349677 0.501108 -0.865080 -0.022973 0.198373 0.193834 1 1 1.000000 fireaxe.png 0 0.304956 -6.301589 -1.365383 0.767996 -0.638701 -0.047357 0.197830 0.182770 1 1 1.000000 0 0.018845 -6.532310 -1.349677 0.501108 -0.865080 -0.022973 0.198373 0.193834 1 1 1.000000 0 -0.311359 -6.619191 -5.999374 0.529408 -0.847991 -0.025277 0.037413 0.206603 1 1 1.000000[/QUOTE]Testaxe (trying to see if it was the model) [QUOTE]version 1 nodes 0 "Box01" -1 1 "ValveBiped.Bip01_R_Hand" -1 end skeleton time 0 0 1.149107 1.086051 15.028385 0.000000 0.000000 -1.570796 1 0.004384 1.129888 23.743217 0.000000 -3.141593 -0.000000 end triangles testaxe.png 0 0.027390 2.207768 15.028387 0.000000 -0.000000 -1.000000 0.566471 0.585749 1 1 1.000000 0 2.270825 2.207768 15.028387 0.000000 -0.000000 -1.000000 0.566471 0.640396 1 1 1.000000 0 2.270825 -0.035667 15.028387 0.000000 -0.000000 -1.000000 0.511824 0.640396 1 1 1.000000 testaxe.png 0 2.270825 -0.035667 15.028387 0.000000 -0.000000 -1.000000 0.511824 0.640396 1 1 1.000000 0 0.027390 -0.035667 15.028387 0.000000 -0.000000 -1.000000 0.511824 0.585749 1 1 1.000000 0 0.027390 2.207768 15.028387 0.000000 -0.000000 -1.000000 0.566471 0.585749 1 1 1.000000 testaxe.png 0 0.027390 2.207768 37.462738 0.000000 0.000000 1.000000 0.566471 0.580622 1 1 1.000000 0 0.027390 -0.035667 37.462738 0.000000 0.000000 1.000000 0.511824 0.580622 1 1 1.000000 0 2.270825 -0.035667 37.462738 0.000000 0.000000 1.000000 0.511824 0.525975 1 1 1.000000 testaxe.png 0 2.270825 -0.035667 37.462738 0.000000 0.000000 1.000000 0.511824 0.525975 1 1 1.000000 0 2.270825 2.207768 37.462738 0.000000 0.000000 1.000000 0.566471 0.525975 1 1 1.000000 0 0.027390 2.207768 37.462738 0.000000 0.000000 1.000000 0.566471 0.580622 1 1 1.000000 testaxe.png 0 0.027390 -0.035667 15.028387 -1.000000 0.000000 -0.000000 0.980000 0.139493 1 1 1.000000 0 0.027390 -0.035667 32.644985 -1.000000 0.000000 -0.000000 0.550883 0.139493 1 1 1.000000 0 0.027390 2.207768 32.644985 -1.000000 0.000000 -0.000000 0.550883 0.084846 1 1 1.000000[/QUOTE]The way I link the bones to my models is with the skin modifier. Is that correct? Because without it I can't export them properly. Edit: Reading through some other threads, I tried compiling with x86 but that changed nothing. (did fix the transparency cause it was in the vmt) I still have no idea what could be wrong with it.
sorry forgot about this thread, it looks like you have an extra bone there, in both of them. Find out how to delete "Box01" and "Cylinder01". Otherwise you need to assign some verticies to them, that is giving the error.
It would seem it's putting that bone in itself. The strangest thing is that the model works for me in Gmod, and 2 of my friends say it works in their sourcemod after compiling it themselves. I'll see what I can do. If anything comes up please let me know, but so far thanks alot :). Could this be related to the SDK update? Because the mod I'm working on was created through the: Create mod from template from the SDK 2007. EDIT: Found out that is was the SDK making fun of me, Thanks valve, thanks alot for supporting Mac and breaking our SDK. THANKS. (And real thanks to Naelstrom and Silver Spirit :) )
Sorry, you need to Log In to post a reply to this thread.