ID:170594
 
Does anyone know how to make a verb that when you press it it will ask you whoch icon you want to use and if it has opacity then it asks if it has density and you ask yes or no on those questions then it asks for a name and then after you are done with that it adds that verb to the build tab and when you press it , then it will build that object at hte place you are standing.Thanks in advance!
Try this(Untested)
mob/verb/SetCustomBuild(I as icon)
var/A = input("Will it be dense?")in list("Yes","No")
switch(A)
if("Yes") usr.COD=1
if("No") usr.COD=0
var/B = input("Will it block light?")in list("Yes","No")
switch(B)
if("Yes") usr.COO=1
if("No") usr.COO=0
usr.COI=I

mob/verb/BuildCustomObj()
var/obj/A=new/obj(usr.loc)
A.density=usr.COD
A.opacity=usr.COO
A.icon=usr.COI

mob/var/COD
mob/var/COO
mob/var/COI
Its getting a bit annoying that you keep asking for a piece of coding without apparently trying it out your self.

Couldn't you atleast attempt it and show us what you've done before posting?
In response to Artekia
THANKS, that had absolutly no errors!
In response to DeathAwaitsU
Ok, i will, sry that i have been posting alot....
In response to Tsonic112
Tsonic112 wrote:
Ok, i will, sry that i have been posting alot....

Yeah, to be honest- I gave you an example on how to work doors, remembering the creator in a var.

I used an example involving mohawks- and instead of reading it and learning from it, you dismissed it as nonesense.

You'll profit SO much better if you *read* DM code, not just *look* at DM code.


But meh.

(also, could I mention, you should try taking out some of the code in your game. Specifically the code that came from the infamous source we know as Z-...)