i have 2 problems with my code, there is no errors, but it doesn't do what i want i want it to do and i can't figure out why, here are the problemsfirst of all it won't let me choose my character at login even though i followed a code given to me through newbie central, and it won't let me even view the mob that should be used by the character when i test play it
mob
goodguys
icon = 'goodguys.dmi' icon_state = "Goku"
badguys
icon = 'badguys.dmi' icon_state = "Frieza"
var
HP = 30
wealth = 0
Del()
var/obj/gold/G = new(loc)
G.amount = rand(1,100)
..()
mob/Login()
..()
var/choice = ("Choose your race.") in list("Goku","Frieza")
switch(choice)
if("Goku")
icon = 'goodguys.dmi'
icon_state = "Goku"
if("Frieza")
icon = 'badguys.dmi'
icon_state = "Frieza"
proc
Deathcheck() if(HP <= 0) world << "[src] is sleeping with fishes! (=> "
del(src)
verb
headbutt(mob/M as mob in oview(1)) usr << "You headbutt [M]!"
oview() << "[usr] headbutts [M]!"
var/damage = rand(1,10) world << "[damage] damage!" M.HP -= damage M.Deathcheck()
say(msg as text) world << "[usr]: [msg]"
obj
gold
icon = 'gold.dmi'
var
amount
verb
get()
set src in view(1)
usr << "You pick up [amount] gold."
usr.wealth += amount
del(src) Move(usr.wealth)
turf
landscapes
icon = 'landscapes.dmi' grass
icon_state = "grass"
tree
icon_state = "tree"
opacity = 1
density = 1
tree2
name = "tree"
icon_state = "tree2"
opacity = 1
density = 1
dirt
icon_state = "dirt"
world
turf = /turf/landscapes/grass
ID:149582
Mar 31 2002, 2:26 pm
|
|
Apr 9 2002, 3:34 pm
|
|
In response to FireEmblem
|
|
FireEmblem wrote:
> var/choice = ("Choose your race.") in list("Goku","Frieza") Change every usr to src. -Kappa the Imp |