ID:266912
Aug 21 2002, 10:05 pm
|
|
i read a few of the tutorials but i had errors on all of them and i couldnt make the game do what i wanted. somebody please email me at [email protected] with some help if they can or respond here. thanks.
|
Did you do the ZBT tutorial? It should be flawless. If not, show us what the problems are.
|
In response to Alatar
|
|
here is my code from the zbt tutorial:
mob icon = 'person.dmi' var HP = 30 bug icon = 'bug.dmi' Login() icon_state = gender ..() proc DeathCheck() if (HP <= 0) world << "[src] dies!" verb attack(mob/M as mob in oview(1)) usr << "You attack [M]!" oview() << "[usr] attacks [M]!" var/damage = rand(1/10) world << "[damage] damage!" M.HP -= damage M.DeathCheck() say(msg as text) world << "[usr]: [msg]" turf grass icon = 'grass.dmi' world turf = /turf/grass if you can understand that. and here is the problem: BYOND(332.837) Error: the file C:\Program Files\BYOND\bin\Testworld\Testworld.rsc is locked up! Testworld.dm:6:error: 'bug.dmi' : cannot find file Testworld.dmb - 1 error, 0 warnings (double click on an error to jump to it) |
In response to Kilgore trout
|
|
somehow there is no error now. thanks for the help though.
|
In response to Kilgore trout
|
|
Alright, i'll explain to you what server is locked up means.
That means you are hosting the game, and compiled the code. The server locks up because you are in the game, and trying to compile it. Stop hosting the game, compile it, and it's fine. Hope that helps you. Alatar |
In response to Kilgore trout
|
|
now the bugs that are supposed to show on the map have no icon and they dont show up. also when i run the game i dont have a choice between the male, female, and neuter. i havent changed anything from my other post in the script.
|
In response to Kilgore trout
|
|
Kilgore trout wrote:
now the bugs that are supposed to show on the map have no icon and they dont show up. also when i run the game i dont have a choice between the male, female, and neuter. i havent changed anything from my other post in the script. First off, you don't have a selection for Male, Female, Neuter in that code you posted. Alatar |
In response to Alatar
|
|
how do i put a selection in for that code?
|
In response to Kilgore trout
|
|
Put somthing like this somewhere in your code:
mob Hope that helps, i'm off to bed now. Alatar |
In response to Alatar
|
|
Alatar wrote:
Put somthing like this somewhere in your code: mob usr.gender=input("What gender would you like?","Gender")in list("Male","Female","Neuter") does the same in one line. |
In response to Skysaw
|
|
Erm.... Shouldn't the line read usr.gender = input("What gender would you like?","Gender")in list("male","female","neuter") ?
|
In response to WizDragon
|
|
Uhhh, you don't need to select your gender. Your gender is, by default, the gender of your key. Also, your problem seems to be something with your bug icon. Check it to see if it's there, and has something on it. Also, when doing rand(), and all procs, arguments are seperated by a comma (,), because what you've done will divivde the two numbers.
|
In response to WizDragon
|
|
unless i dont see a difference,other then a space before and after the =...
you dont need the space,it's temporary now,the other problem you had,Kilgore,is that it doesnt show the icon,right? did you make a bug.dmi file? and did you put any capitalization in it? (like Bug.dmi or BUG.DMI or something?) because it's very case sensative... (the difference between: icon = 'bug.dmi' and icon = 'Bug.dmi' is huge,and may cause an error that could confuse most new coders,and gurus alike ^_^ ) |
In response to Roara
|
|
yeah i made the .dmi file and then typed in the code or it and when i run it i can attack the bugs but they are just not there visually.
|
In response to Kilgore trout
|
|
Did you name the icon state? Is there even an icon in the .dmi file?
|
here is my current code:
mob icon = 'person.dmi' var HP = 30 bug icon = 'bug.dmi' Login() usr.gender = input("What gender would you like?","gender")in list("male","female","neuter") icon_state = gender ..() proc DeathCheck() if (HP <= 0) world << "[src] dies!" del(src) verb attack(mob/M as mob in oview(1)) usr << "You attack [M]!" oview() << "[usr] attacks [M]!" var/damage = rand(1,10) world << "[damage] damage!" M.HP -= damage M.DeathCheck() say(msg as text) world << "[usr]: [msg]" turf grass icon = 'grass.dmi' world turf = /turf/grass I was wondering if in place of 'gender' in the Login proc why i cant put 'character' so it asked me which character i wanted to choose rather than gender? |
In response to Roara
|
|
Bah, Skysaw must have edited his post. Before, there was a switch() in there and the gender names were capitalized.
|
Alatar