Getweapons is already a table, why are you looping through it to make another table?
My understanding of the wiki description without actually having had used/experience in this command may make me unreliable and incorrect, but, the wiki says it stores the table.
So you could simply use
local target_ply.weps = { target_ply:GetWeapons() }
(You're going to want to attach the weps table to each player who might be softbanned while on server, hence the target_ply.weps
You're also going to have to check/get the ammo counts for each weapon and store that to give to them later.
Now, the challenge, Give expects weapon ClassNames. You can't just loop back through and Give ( target_ply.weps[var] )
You'd have to loop through the table and do something like Give ( target_ply.weps[var]:GetClass() )
But, you also have to store weapon ammo. I'm not sure GetWeapons does that.
*click* Few minutes later.
Here, found this example that looks 98% accurate like it may work out of the box on Facepunch
https://facepunch.com/showthread.php?t=1477280&s=0258ce5b3e965249181345973d9c7220&p=48281605&viewfull=1#post48281605(I know, I know, surprise surprise..it only took about 20 posts for someone to just feed the guy straight out after several posts explaining what might work, why it was a bad idea, the argument on why it wasn't a bad idea, then the apology by the person who stated they were wrong about it being a bad idea, then answering in straight code)
PlayerDeath hook grabs.
PlayerSay hook, about half way down, shows the general give code.
You should be able to figure out how to modify it for your needs, using our codestyle to match ULX.