ID:178211
 
Rather disturbing title aint it? well im makin a soccer game and have some net turfs but i want it so if the thing entering the net is a Ball then it allows it in, gives the corresponding team a score and relocates ball, but if its a player it turns its density to 1 so the player cannot walk around in the net. Thanks In Advance to anyone who can help meh, and thanks to people who read
Ok, lets say theres a blue and red team
obj
>> Soccer_Ball
>> >> var
>> >> >> LastKick
>> >>Bump(mob/O)
>> >> >> src.LastKick = O.team//the team of ball is kickers
>> >> >> walk(src,O.dir)
area
>> GOAL_SPOT
>> >> Enter(atom/O)
>> >> >> if(ismob(O))//if its a mob
>> >> >> >> return 0//mobs cant go in
>> >> >> if(istype(O,/obj/Soccer_Ball))
>> >> >> >> world<<"GOAL for the [O.LastKick] team!"
>> >> >> >> O.LastKick += 1

This is a demo code. Tinker with it a bit