Skip to content

Commit

Permalink
An attempt to allow clowns to change their name upon spawning in the …
Browse files Browse the repository at this point in the history
…way wizards or AIs do. The proc is currently not called when the clown spawns. Here's hoping someone fixes it or I spontaneously come up with a solution in the morning. Here it is to be monkeyed with.

git-svn-id: http://tgstation13.googlecode.com/svn/trunk@1143 316c924e-a436-60f5-8080-3fe189b3f50e
  • Loading branch information
[email protected] committed Feb 28, 2011
1 parent 0a68c9e commit eefa612
Show file tree
Hide file tree
Showing 4 changed files with 61 additions and 0 deletions.
26 changes: 26 additions & 0 deletions code/defines/procs/helpers.dm
Original file line number Diff line number Diff line change
Expand Up @@ -533,6 +533,32 @@
M.real_name = newname
M.name = newname

/proc/clname(var/mob/M as mob) //--All praise goes to NEO|Phyte, all blame goes to DH, and it was Cindi-Kate's idea
var/randomname = pick(clown_names)
var/newname = input(M,"You are the clown. Would you like to change your name to something else?", "Name change",randomname)

if (length(newname) == 0)
newname = randomname

if (newname)
if (newname == "Unknown")
M << "That name is reserved."
return clname(M)
for (var/mob/living/carbon/A in world)
if (A.real_name == newname)
M << "There's already a clown with that name."
return clname(M)
if (length(newname) >= 26)
newname = copytext(newname, 1, 26)
newname = dd_replacetext(newname, ">", "'")
M.real_name = newname
M.name = newname
// if (istype(src.belt, /obj/item/device/pda))
// var/obj/item/device/pda/pda = src.belt
// pda.owner = src.real_name
// pda.ownjob = src.wear_id.assignment
// pda.name = "PDA-[src.real_name] ([pda.ownjob])"

/proc/ionnum()
return "[pick("!","@","#","$","%","^","&","*")][pick(pick("!","@","#","$","%","^","&","*"))][pick(pick("!","@","#","$","%","^","&","*"))][pick(pick("!","@","#","$","%","^","&","*"))]"

Expand Down
3 changes: 3 additions & 0 deletions code/game/jobs/jobprocs.dm
Original file line number Diff line number Diff line change
Expand Up @@ -654,6 +654,9 @@
src.loc = pick(NL)
return

if (rank == "Clown")
clname(src)

/mob/living/carbon/human/proc/spawnId(rank)
var/obj/item/weapon/card/id/C = null
switch(rank)
Expand Down
1 change: 1 addition & 0 deletions code/names.dm
Original file line number Diff line number Diff line change
Expand Up @@ -6,5 +6,6 @@ var/list/first_names_male = dd_file2list("config/names/first_male.txt")
var/list/first_names_female = dd_file2list("config/names/first_female.txt")
var/list/last_names = dd_file2list("config/names/last.txt")
var/list/loggedsay = dd_file2list("config/names/loggedsay.txt")
var/list/clown_names = dd_file2list("config/names/clown.txt")
//loaded on startup because of "
//would include in rsc if ' was used
31 changes: 31 additions & 0 deletions config/names/clown.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
Gigglesworth
Honkel the III
Goose McSunny
Mr. Shoe
Toodles Sharperton
Dinky Doodle
Honkerbelle
Bo Bo Sassy
Baby Cakes
Ladybug Honks
Ziggy Yoyo
Razzle Dazzle
Buster Frown
Pepinpop
Silly Willy
Jo Jo Bobo Bo
Pocket
Patches
Checkers
Freckle
Honker
Bonker
Skiddle
Scootaloo
Sprinkledinkle
Ronnie Pace
Miss Stockings
Slippy Joe
Redshirt McBeat
Flop O'Honker
Gamzee

0 comments on commit eefa612

Please sign in to comment.