ID:175296
 
How can you look at objs in code like a create obj verb?
now now. dont repost!
Just use the forum search button. Your basically using a list of objects in the world and creating a new one at the same location as you.
In response to Maz
Here, this is a working code from a new person im teaching:

mob
verb
Create(O as obj in istype(/obj/,/mob/,/turf/))
switch(alert("Would you like to COLORIZE?!,"COLORS!","Yes","No"))
if("Yes")
var/objred = input("How much red do you want on the object?") as number
var/objblue = input("How much blue do you want on the object?") as number
var/objgreen = input("How much green do you want on the object?") as number
O += rgb(objred,objgreen,objblue)
new O(locate(usr.x,usr.y-1,usr.z))
if("No")
new O(locate(usr.x,usr.y-1,usr.z))

Hope that helps!

In response to Draks
Draks wrote:
Create(O as obj in istype(/obj/,/mob/,/turf/))

Come again? This isn't even close to a correct usage of istype(), to say nothing of the extraneous slashes at the end of those type paths.

Lummox JR
In response to Lummox JR
sorry, i meant typesof.