atom/proc/Bumped()
turf
World1
icon='Worlds.dmi'
icon_state="1"
density=1
var/playerownership=""
var/pname=""
var/race=""
var/ringed=0
var/mooned=0
var/size=20
var/population=0
var/shipyard=0
Bumped(mob/M)
if(M.colanyship)
switch(input("Colonise world?","Colonisation") in list ("yes","no"))
if("yes")
src.population+=10000
src.playerownership=usr.key
if("no")
return null
else
switch(input("Attack World?","Bombard") in list ("yes","no"))
if("yes")
src.population-=1000
sleep(1)
if(population<=0)
src.playerownership=null
if("no")
return null
mob
var
colanyship=1
mob
colanyship
icon='Yship.dmi'
icon_state="YColany"
density=1
I have a problem with bump when i the ship bumps into the planet it i does nothing. I haven't done much on bump for a while so someone tell. Please also look if there are any problems because i'm lacking sleep...
As for the code you showed, you should make sure the thing Bumped() is actually a mob. You can't just type Bumped(mob/M) and then think everytime it's Bumped() the thing it was Bumped() by was a mob.
Finally, you don't need to do if("no") and then return null. Doing this gives the same effect: