From 577ec5eba99a1a46ed6f2c21c169f7082e499b82 Mon Sep 17 00:00:00 2001 From: "vageyenaman@gmail.com" Date: Mon, 3 Oct 2011 01:29:41 +0000 Subject: [PATCH] =?UTF-8?q?Committed=20for=20Rolan7:=20=20=20=20=20?= =?UTF-8?q?=E2=97=A6=20Fixed=20job=20assignments.=20Hopefully=20this=20sho?= =?UTF-8?q?uld=20stop=20the=20massive=20amount=20of=20assistants=20spawnin?= =?UTF-8?q?g=20at=20round=20start!?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit My changes: ◦ Fixed some Metroid-related bugs. Had stuff to do with draining life out of things and being able to move at the same time. Also some stuff with the way Metroids' speech is handled. ◦ Removed some unnecessary, commented-out code from the say() proc. ◦ Removed the chat bubble preference from the character creation screen. ◦ Added some more chat bubble themes, in the event someone wants to continue that. I've lost all motivation to continue the project because, no matter what I do, it just looks butt-ugly and laggy as hell. git-svn-id: http://tgstation13.googlecode.com/svn/trunk@2321 316c924e-a436-60f5-8080-3fe189b3f50e --- code/defines/mob/living/carbon/metroid.dm | 2 +- code/game/jobs/jobprocs.dm | 29 +---- .../modules/mob/living/carbon/metroid/life.dm | 3 +- .../mob/living/carbon/metroid/powers.dm | 4 +- code/modules/mob/living/carbon/metroid/say.dm | 14 ++- code/modules/mob/living/say.dm | 109 ++++++++++++++---- code/modules/mob/new_player/preferences.dm | 2 +- icons/changelog.html | 5 + icons/effects/speechbubble.dmi | Bin 1925 -> 2960 bytes 9 files changed, 116 insertions(+), 52 deletions(-) diff --git a/code/defines/mob/living/carbon/metroid.dm b/code/defines/mob/living/carbon/metroid.dm index dffbd2fade0..2d2cefc503e 100644 --- a/code/defines/mob/living/carbon/metroid.dm +++ b/code/defines/mob/living/carbon/metroid.dm @@ -7,7 +7,7 @@ icon_state = "baby metroid" pass_flags = PASSTABLE voice_message = "skree!" - say_message = "says" + say_message = "hums" health = 150 gender = NEUTER diff --git a/code/game/jobs/jobprocs.dm b/code/game/jobs/jobprocs.dm index 748f23c93d5..1c0dfcf9f14 100644 --- a/code/game/jobs/jobprocs.dm +++ b/code/game/jobs/jobprocs.dm @@ -31,8 +31,8 @@ var/list/candidates = FindOccupationCandidates(unassigned, command_position, level) if(!candidates.len) continue var/mob/new_player/candidate = pick(candidates) - unassigned -= candidate if(Assign_Role(candidate, command_position)) + unassigned -= candidate jobs[command_position]-- return 1 return 0 @@ -48,8 +48,8 @@ candidates -= player if(candidates.len) var/mob/new_player/candidate = pick(candidates) - unassigned -= candidate if(Assign_Role(candidate, "AI")) + unassigned -= candidate jobs["AI"]-- ai_selected++ break @@ -59,8 +59,8 @@ for(var/mob/new_player/player in unassigned) if(jobban_isbanned(player, "AI")) continue - unassigned -= player if(Assign_Role(player, "AI")) + unassigned -= player jobs["AI"]-- ai_selected++ break @@ -107,31 +107,12 @@ var/list/candidates = FindOccupationCandidates(unassigned, occupation, level) while(candidates.len && occupations_available[occupation]) var/mob/new_player/candidate = pick(candidates) - unassigned -= candidate if(Assign_Role(candidate, occupation)) + unassigned -= candidate occupations_available[occupation]-- - if(!unassigned.len) return 1 - - //Set all remaining players to an assistant job - var/list/vacancies = list() - for(var/assist_job in assistant_occupations) - if(!occupations_available[assist_job] > 0) continue - for(var/i = 1 to occupations_available[assist_job]) - vacancies += assist_job - for(var/mob/new_player/player in unassigned) - if((!unassigned.len) || (!vacancies.len)) break - unassigned -= player - var/assist_job = pick(vacancies) - if(Assign_Role(player, assist_job)) - vacancies -= assist_job - - if(unassigned.len) - for(var/mob/new_player/player in unassigned) - if(!unassigned.len) break - Assign_Role(player, "Assistant") - //If anyone still has no job then something is fucked up with their mob and they will currently spawn at spawn but the runtimes should no longer dump several people here + Assign_Role(player, "Assistant") return 1 diff --git a/code/modules/mob/living/carbon/metroid/life.dm b/code/modules/mob/living/carbon/metroid/life.dm index 5df8d7d35d2..88fac4623c4 100644 --- a/code/modules/mob/living/carbon/metroid/life.dm +++ b/code/modules/mob/living/carbon/metroid/life.dm @@ -43,7 +43,8 @@ handle_nutrition() if(Tempstun) - canmove = 0 + if(!Victim) // not while they're eating! + canmove = 0 else canmove = 1 diff --git a/code/modules/mob/living/carbon/metroid/powers.dm b/code/modules/mob/living/carbon/metroid/powers.dm index 136487e4695..157c9918cdf 100644 --- a/code/modules/mob/living/carbon/metroid/powers.dm +++ b/code/modules/mob/living/carbon/metroid/powers.dm @@ -103,8 +103,8 @@ if(cloneloss<0) cloneloss = 0 nutrition += rand(10,25) - if(nutrition >= lastnut + 100) - if(prob(60)) + if(nutrition >= lastnut + 50) + if(prob(80)) lastnut = nutrition powerlevel++ if(powerlevel > 10) diff --git a/code/modules/mob/living/carbon/metroid/say.dm b/code/modules/mob/living/carbon/metroid/say.dm index 6bb65f63f8d..a1e49441963 100644 --- a/code/modules/mob/living/carbon/metroid/say.dm +++ b/code/modules/mob/living/carbon/metroid/say.dm @@ -1,3 +1,15 @@ /mob/living/carbon/metroid/say_quote(var/text) - return "[src.say_message], \"[text]\""; + var/ending = copytext(text, length(text)) + + if (ending == "?") + return "telepathically asks, \"[text]\""; + else if (ending == "!") + return "telepathically cries, \"[text]\""; + + return "telepathically chirps, \"[text]\""; + +/mob/living/carbon/metroid/say_understands(var/other) + if (istype(other, /mob/living/carbon/metroid)) + return 1 + return ..() diff --git a/code/modules/mob/living/say.dm b/code/modules/mob/living/say.dm index dd9e0a7afe8..08e56e3116b 100644 --- a/code/modules/mob/living/say.dm +++ b/code/modules/mob/living/say.dm @@ -312,8 +312,60 @@ else rendered = "[real_name][alt_name] [message_a]" +/* + // Create speech bubble + var/obj/speech_bubble/B = new/obj/speech_bubble + B.icon = 'speechbubble.dmi' + B.parent = src + B.mouse_opacity = 0 + B.invisibility = invisibility + B.layer = 10 + + // Determine if the speech bubble's going to have a special look + var/presay = "" + if(istype(src, /mob/living/silicon)) + presay = "bot" + if(istype(src, /mob/living/carbon/alien)) + presay = "xeno" + if(istype(src, /mob/living/carbon/metroid)) + presay = "metroid" +*/ for (var/mob/M in heard_a) + M.show_message(rendered, 2) + /* + if(M.client) + + // If this client has bubbles disabled, obscure the bubble + if(!M.client.bubbles || M == src) + var/image/I = image('speechbubble.dmi', B, "override") + I.override = 1 + M << I + */ + /* + // find the suffix, if bot, human or monkey + var/punctuation = "" + if(presay == "bot" || presay == "") + var/ending = copytext(text, length(text)) + if (ending == "?") + punctuation = "question" + else if (ending == "!") + punctuation = "exclamation" + else + punctuation = "" + + // flick the bubble + flick("[presay]say[punctuation]", B) + + if(istype(loc, /turf)) + B.loc = loc + else + B.loc = loc.loc + + spawn() + sleep(11) + del(B) + */ if (length(heard_b)) var/message_b @@ -329,37 +381,50 @@ rendered = "[voice_name] [message_b]" + + /* + // Create speech bubble + var/obj/speech_bubble/B = new/obj/speech_bubble + B.icon = 'speechbubble.dmi' + B.parent = src + B.mouse_opacity = 0 + B.invisibility = invisibility + B.layer = 10 + + // Determine if the speech bubble's going to have a special look + var/presay = "" + if(istype(src, /mob/living/silicon)) + presay = "bot" + if(istype(src, /mob/living/carbon/alien)) + presay = "xeno" + if(istype(src, /mob/living/carbon/metroid)) + presay = "metroid" + */ + for (var/mob/M in heard_b) M.show_message(rendered, 2) + /* if(M.client) - spawn() - var/isbot = "" - if(istype(src, /mob/living/silicon)) - isbot = "bot" - var/obj/speech_bubble/B = new/obj/speech_bubble - B.icon = 'speechbubble.dmi' - B.parent = src - B.mouse_opacity = 0 - B.invisibility = invisibility - B.layer = 10 + if(!M.client.bubbles || M == src) + var/image/I = image('speechbubble.dmi', B, "override") + I.override = 1 + M << I + */ /* - if(!M.client.bubbles || M == src) - var/image/I = image('speechbubble.dmi', B, "override") - I.override = 1 - M << I + flick("[presay]say", B) - flick("[isbot]say", B) + if(istype(loc, /turf)) + B.loc = loc + else + B.loc = loc.loc - if(istype(loc, /turf)) - B.loc = loc - else - B.loc = loc.loc + spawn() + sleep(11) + del(B) + */ - sleep(11) - del(B) - */ log_say("[name]/[key] : [message]") diff --git a/code/modules/mob/new_player/preferences.dm b/code/modules/mob/new_player/preferences.dm index 0524cab14b1..e7d5cf283c8 100644 --- a/code/modules/mob/new_player/preferences.dm +++ b/code/modules/mob/new_player/preferences.dm @@ -394,7 +394,7 @@ datum/preferences dat += "
" dat += "UI Style: [UI == UI_NEW ? "New" : "Old"]
" dat += "Play admin midis: [midis == 1 ? "Yes" : "No"]
" - dat += "Show chat bubbles: [bubbles == 1 ? "Yes" : "No"]
" + //dat += "Show chat bubbles: [bubbles == 1 ? "Yes" : "No"]
" if((user.client) && (user.client.holder) && (user.client.holder.rank) && (user.client.holder.rank == "Game Master")) dat += "
OOC
" diff --git a/icons/changelog.html b/icons/changelog.html index 6eac40bff61..1db66672792 100644 --- a/icons/changelog.html +++ b/icons/changelog.html @@ -67,6 +67,11 @@ should be listed in the changelog upon commit tho. Thanks. -->
  • Less ponies, gryphons, and Tohou.
  • +
  • Rolan7 updated: + +
  • 1 October 2011: diff --git a/icons/effects/speechbubble.dmi b/icons/effects/speechbubble.dmi index 1cedd80ddc6b8a2b6462c69cc2699f5caa791ed7..eff411b793290064e70e7795366d9b819205201a 100644 GIT binary patch literal 2960 zcmcJRX*io%8^<5JnT|$Vo$4UCrqgy>EiI~+(3Vy=OLwL;_GLN~C5VKCYl5`Xh0554 zYKyk^YAH#i6>6ptR1iyurGzL!5+RGckG}8w?fv%7d^zV_&v~A6-OvC2|L*(T@pO09 z`TD!B0RYfBbK2!10H}aVU`$&R96uj_;|Wd_%w?}=mtbUIRQRpv@CXC|#1)jJ*>A>M z=(^mL>Fp1@kSv_zxIDV8y5KkAR-;}K5TVU+JgN6FS<|XdPY}L4^&IZNzCS;l*gS)O z0<|(kJ=co}ZB)@AQ1x`0TAms|;Vt-dmSI>5i(qfU>x z^r>Zg>^8*6RK|gO?+hbN@A#na-oKiX_Wh%?guWa~dP~%nC}vA+eLg3^ z;(T!V>2XB0K9dt>ZNFk9X%@ucxDf5itM9w&guF5o{M*7z7VDDQqgk6;13g3$-b85Dibd6|Kg>_@v~+#fWrcnLQfRCdz9!_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