ID:1662994
 
(See the best response by Kozuma3.)
Code:
mob/verb/atomSense()
for(var/atom/A=locate(src.x,src.y,src.z))
world<<"[A.icon_state]"

currently without the for loop it works if there is only 1 atom in the location. What i want it to do is output this text to the world but with all the atoms from the location.

so if im standing on a obj and turf it will say
obj
turf

Obviously this is for testing purposes for something bigger
Thank you for any help
Problem description:

Like this?

mob/verb/Get_Contents()
world << "[src.loc.name]"
for(var/atom/Atom in src.loc.contents)
world << "[Atom.name]"
opps it wasnt A=locate. It was A in locate. the problem is its displaying blanks when i print to world
oh ill try that hold on
yes it almost works, the name thing works. But i also need to get their icon states. But for whatever reason the iconstates are comming off as blank
Best response
Haven't tried it but this should work o: , you can edit the client's script to change the image's size.

mob/verb/Get_Contents()
world << "[src.loc.name]"
for(var/atom/Atom in src.loc.contents)
world << "\icon[Atom] - [Atom.name]"
//world << "icon_state = [Atom.icon_state]"
or actually i think it s doing the icon_state, just my icon state is set to blank. But the turfs are not printing out.
okay i just copyed and pasted and that new way seems to be getting the turfs, let me just experiment a bit
oh im starting to get it the reason is because i didnt put in thise line of yours
world << "[src.loc.name]"

So the turf isnt actually caculated in the atom, but it can be calculated seperatley. Okay thanks i think this is all i need. You were a big help
In response to Anthonytyran
Anytime :)