ID:159222
 
So I am trying to set_invisibility for a certain race. So this is a bleach demo. I have the concept of this in my head but don't really know how type it. I am trying to make Humans for not being able to see not another race but itself.



Thanks for Reading
mob
Login()
if(src.Race=="Human")
src.invisibility=1


Is this what your looking for or is there something I missed, tell me and I'll gladly assist you.

-Gizhy
If you split up races between object types (which is often useful anyway), such things are very trivial. You can also split up declarations and only give each object the properties it needs (for example, a hollow doesn't need vars that define a creature's shinigami powers, generally neither does a human). I'll demonstrate that:
mob/creature
var/HP
spirit
invisibility = 1
var/spirit_power //SPIRITUAL ENERGY
see_invisible = 1 //spirits are both invisible and can see themselves
hollow
var/list/hollow_powers
shinigami //2 special spirit types are hollow, shinigami
var/obj/sword/zanpakuto //teh shinigami powar
human
/*humans are left with the default values for those 2 vars,
but you'll want to eventually give them the ability to
see invisible, either for gameplay or accuracy to Bleach*/


world/mob = /mob
client/New()
spawn(-1) //do this stuff _after_ New() returns
switch(input(src,"Start as what?") in list("human","Hollow","Shinigami"))
if("human")
src.mob = new /mob/creature/human
if("Hollow")
src.mob = new /mob/creature/spirit/hollow
//...
src.mob.Move(Starting_Area)
return ..()