Hi I have made a portion of script that does something similar to the first part of your question. hopefully you can adapt it or find someone to adapt it for you. I have added some explanations to what I did.
Note I wrote this code for blender 2.8 so the code may be deprecated but should still work.
G = GameLogic
C = G.getCurrentController()
pickw = C.getSensor("pickweap") # this is a collision sensor
item = pickw.getHitObject()
#get collision objects name and display it
n = item.getName()
name = '"'+n[2:]+'"' #the string setproperty actuator only accepts names without the default 'OB' prefix that blender adds this removes it
prop = C.getActuator("prop") # this is a set property actuator on a realtime text plane
prop.setValue(name) #set the property to be the name of the collision object
G.addActiveActuator(prop, True) # activate actuator