Re: ACrab Weapon Accessing via Pie menu
Oh okay, it's for a pie slice so that makes sense then. Sorry, I should have read your first post more carefully.
Have you tried, as you suggested, print (crab)?
Other than that I'm not sure what's wrong, though it's possible you can just reference the actor in the function without doing ToACrab at all.
i.e.
Code:
for i = 1, MovableMan:GetMOIDCount()-1 do
if MovableMan:GetRootMOID(i) == actor.RootID then
MoEnt = MovableMan:GetMOFromID(i)
etc.
Edit: Though looking at a few other ammo swapping scripts I'm pretty sure this isn't the case.
If you don't mind sharing it (via pm or posting here or whatever) I'd be happy to try to help properly, I find it difficult to properly figure things out without the ability to test ingame so I'm afraid I may not be much help if you don't want to share it. That said, it might not be worth the effort since I don't know what the problem is. Rather I'd just throw in enough prints to find the problem and try to work from there, which is obviously something you can easily do yourself.