Tg patch branch to master (#192)

* code nitpicking

* Midnight oil

More like 6am oil.  Still having issues with actually eating anyone.

* Subsystem 12/21

Most Recent TG subsystem folder

* globalvars 12/21

Tossed out the flavor_misc and parallax files

* Onclick 12/21

as well as .dme updates

* _defines 12/21

ommited old _MC.dm

* _HELPERS 12/21

Preserved snowflake placement of furry sprites

* _defeines/genetics

reapplied narkism holdover for snowflake races.

* Oops forgot mutant colors

* modules porting 12/21 + Sounds/icons

Admin, Client and most of mob life files ommitted

* enviroment file

* Admin optimizations

ahelp log system kept

* Mob ports 12/21

Flavor text preserved

* datums ported 12/21

* Game ported 12/21

* batch of duplicate fixes/dogborg work

Dogborgs need to be modernized to refractored borg standards.

* moar fixes

* Maps and futher compile fixes

* missed commit

* Noms

* specific release doesn't work

* Tg modernization patch (#115)

* sync (#3)

* shuttle auto call

* Merge /vore into /master (#39)

* progress

* Compile errors fixed

No idea if it's test worthy tho as conflicts with race overhaul and
narky removal.

* Update admins.txt

* efforts continue

Fuck grab code, seriously

* grab code is cancer

* Execute the Narkism

Do not hesitate.

Show no mercy.

* holy shit grab code is awful

* have I bitched about grab code

My bitching, let me show you it

* código de agarre es una mierda

No really it is

* yeah I don't even know anymore.

* Lolnope. Fuck grab code

* I'm not even sure what to fix anymore

* Self eating is not an acceptable fate

* Taste the void, son.

* My code doesn't pass it's own sanity check.

Maybe it's a sign of things to come.

* uncommented and notes

* It Works and I Don't Know Why (#38)

* shuttle auto call

* it works and I don't know why

* Subsystem 12/21

Most Recent TG subsystem folder

* globalvars 12/21

Tossed out the flavor_misc and parallax files

* Onclick 12/21

as well as .dme updates

* _defines 12/21

ommited old _MC.dm

* _HELPERS 12/21

Preserved snowflake placement of furry sprites

* _defeines/genetics

reapplied narkism holdover for snowflake races.

* Oops forgot mutant colors

* modules porting 12/21 + Sounds/icons

Admin, Client and most of mob life files ommitted

* enviroment file

* Admin optimizations

ahelp log system kept

* Mob ports 12/21

Flavor text preserved

* datums ported 12/21

* Game ported 12/21

* batch of duplicate fixes/dogborg work

Dogborgs need to be modernized to refractored borg standards.

* moar fixes

* Maps and futher compile fixes

* port from cactus did

* fix format error

* Update preferences.dm

unfuck

* Revert "port from cactus did"

* unfuck

* more sprite work

* vore

* disabled roundstart xenos for now

* admin QOL

needs callback porting, TBD

* Mentor system initial port

I'm sure I've missed a fuckton of shit

* test merge

* Jesus tits did this finally fix compile issues?

* Tg modern (#149)

* sync (#3)

* shuttle auto call

* Merge /vore into /master (#39)

* progress

* Compile errors fixed

No idea if it's test worthy tho as conflicts with race overhaul and
narky removal.

* Update admins.txt

* efforts continue

Fuck grab code, seriously

* grab code is cancer

* Execute the Narkism

Do not hesitate.

Show no mercy.

* holy shit grab code is awful

* have I bitched about grab code

My bitching, let me show you it

* código de agarre es una mierda

No really it is

* yeah I don't even know anymore.

* Lolnope. Fuck grab code

* I'm not even sure what to fix anymore

* Self eating is not an acceptable fate

* Taste the void, son.

* My code doesn't pass it's own sanity check.

Maybe it's a sign of things to come.

* uncommented and notes

* It Works and I Don't Know Why (#38)

* shuttle auto call

* it works and I don't know why

* Subsystem 12/21

Most Recent TG subsystem folder

* globalvars 12/21

Tossed out the flavor_misc and parallax files

* Onclick 12/21

as well as .dme updates

* _defines 12/21

ommited old _MC.dm

* _HELPERS 12/21

Preserved snowflake placement of furry sprites

* _defeines/genetics

reapplied narkism holdover for snowflake races.

* Oops forgot mutant colors

* modules porting 12/21 + Sounds/icons

Admin, Client and most of mob life files ommitted

* enviroment file

* Admin optimizations

ahelp log system kept

* Mob ports 12/21

Flavor text preserved

* datums ported 12/21

* Game ported 12/21

* batch of duplicate fixes/dogborg work

Dogborgs need to be modernized to refractored borg standards.

* moar fixes

* Maps and futher compile fixes

* Tg modernization patch (#115)

* sync (#3)

* shuttle auto call

* Merge /vore into /master (#39)

* progress

* Compile errors fixed

No idea if it's test worthy tho as conflicts with race overhaul and
narky removal.

* Update admins.txt

* efforts continue

Fuck grab code, seriously

* grab code is cancer

* Execute the Narkism

Do not hesitate.

Show no mercy.

* holy shit grab code is awful

* have I bitched about grab code

My bitching, let me show you it

* código de agarre es una mierda

No really it is

* yeah I don't even know anymore.

* Lolnope. Fuck grab code

* I'm not even sure what to fix anymore

* Self eating is not an acceptable fate

* Taste the void, son.

* My code doesn't pass it's own sanity check.

Maybe it's a sign of things to come.

* uncommented and notes

* It Works and I Don't Know Why (#38)

* shuttle auto call

* it works and I don't know why

* Subsystem 12/21

Most Recent TG subsystem folder

* globalvars 12/21

Tossed out the flavor_misc and parallax files

* Onclick 12/21

as well as .dme updates

* _defines 12/21

ommited old _MC.dm

* _HELPERS 12/21

Preserved snowflake placement of furry sprites

* _defeines/genetics

reapplied narkism holdover for snowflake races.

* Oops forgot mutant colors

* modules porting 12/21 + Sounds/icons

Admin, Client and most of mob life files ommitted

* enviroment file

* Admin optimizations

ahelp log system kept

* Mob ports 12/21

Flavor text preserved

* datums ported 12/21

* Game ported 12/21

* batch of duplicate fixes/dogborg work

Dogborgs need to be modernized to refractored borg standards.

* moar fixes

* Maps and futher compile fixes

* port from cactus did

* fix format error

* Update preferences.dm

unfuck

* Revert "port from cactus did"

* unfuck

* more sprite work

* vore

* disabled roundstart xenos for now

* test merge

* Jesus tits did this finally fix compile issues?

* Initial test compiles. hooray.

* Admin ticket fixes

* I'll give you a bad argument you piece of shit dream maker I fucking swear on my mum

* who list wip

also ahelps are broken again. fuck if I know why

* discord bot basics

* maybe tickets work now & bot framework done

* ahelp callback readd

* Mentor system, Tickets, and discord (#151)

* sync (#3)

* shuttle auto call

* Merge /vore into /master (#39)

* progress

* Compile errors fixed

No idea if it's test worthy tho as conflicts with race overhaul and
narky removal.

* Update admins.txt

* efforts continue

Fuck grab code, seriously

* grab code is cancer

* Execute the Narkism

Do not hesitate.

Show no mercy.

* holy shit grab code is awful

* have I bitched about grab code

My bitching, let me show you it

* código de agarre es una mierda

No really it is

* yeah I don't even know anymore.

* Lolnope. Fuck grab code

* I'm not even sure what to fix anymore

* Self eating is not an acceptable fate

* Taste the void, son.

* My code doesn't pass it's own sanity check.

Maybe it's a sign of things to come.

* uncommented and notes

* It Works and I Don't Know Why (#38)

* shuttle auto call

* it works and I don't know why

* Subsystem 12/21

Most Recent TG subsystem folder

* globalvars 12/21

Tossed out the flavor_misc and parallax files

* Onclick 12/21

as well as .dme updates

* _defines 12/21

ommited old _MC.dm

* _HELPERS 12/21

Preserved snowflake placement of furry sprites

* _defeines/genetics

reapplied narkism holdover for snowflake races.

* Oops forgot mutant colors

* modules porting 12/21 + Sounds/icons

Admin, Client and most of mob life files ommitted

* enviroment file

* Admin optimizations

ahelp log system kept

* Mob ports 12/21

Flavor text preserved

* datums ported 12/21

* Game ported 12/21

* batch of duplicate fixes/dogborg work

Dogborgs need to be modernized to refractored borg standards.

* moar fixes

* Maps and futher compile fixes

* Tg modernization patch (#115)

* sync (#3)

* shuttle auto call

* Merge /vore into /master (#39)

* progress

* Compile errors fixed

No idea if it's test worthy tho as conflicts with race overhaul and
narky removal.

* Update admins.txt

* efforts continue

Fuck grab code, seriously

* grab code is cancer

* Execute the Narkism

Do not hesitate.

Show no mercy.

* holy shit grab code is awful

* have I bitched about grab code

My bitching, let me show you it

* código de agarre es una mierda

No really it is

* yeah I don't even know anymore.

* Lolnope. Fuck grab code

* I'm not even sure what to fix anymore

* Self eating is not an acceptable fate

* Taste the void, son.

* My code doesn't pass it's own sanity check.

Maybe it's a sign of things to come.

* uncommented and notes

* It Works and I Don't Know Why (#38)

* shuttle auto call

* it works and I don't know why

* Subsystem 12/21

Most Recent TG subsystem folder

* globalvars 12/21

Tossed out the flavor_misc and parallax files

* Onclick 12/21

as well as .dme updates

* _defines 12/21

ommited old _MC.dm

* _HELPERS 12/21

Preserved snowflake placement of furry sprites

* _defeines/genetics

reapplied narkism holdover for snowflake races.

* Oops forgot mutant colors

* modules porting 12/21 + Sounds/icons

Admin, Client and most of mob life files ommitted

* enviroment file

* Admin optimizations

ahelp log system kept

* Mob ports 12/21

Flavor text preserved

* datums ported 12/21

* Game ported 12/21

* batch of duplicate fixes/dogborg work

Dogborgs need to be modernized to refractored borg standards.

* moar fixes

* Maps and futher compile fixes

* port from cactus did

* fix format error

* Update preferences.dm

unfuck

* Revert "port from cactus did"

* unfuck

* more sprite work

* vore

* disabled roundstart xenos for now

* admin QOL

needs callback porting, TBD

* Mentor system initial port

I'm sure I've missed a fuckton of shit

* test merge

* Jesus tits did this finally fix compile issues?

* Initial test compiles. hooray.

* Admin ticket fixes

* I'll give you a bad argument you piece of shit dream maker I fucking swear on my mum

* who list wip

also ahelps are broken again. fuck if I know why

* discord bot basics

* maybe tickets work now & bot framework done

* ahelp callback readd

* vore tweaks

* progress

* dirtier fix than a korean hooker in the 60s

* The release your hooker will always fake

* you could save that hookers number but wouldn't you rather just vore the hooker instead

* Save system is literal black magic

* great googly moogly it's all gone to shit

* We May 2015 save code now

* fiddling with digestion code now

* fuck if I know anymore. I'm going to bed

* OWN UP YOUR OWN DIGESTION

* UNREGULATED GUTS ARE NON COMPLIANT

AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA

* BELLIES MUST COMPLY WITH USER OWNERSHIP

* Removed debug messages

* Unneeded verb additions

* file change tweaks

* WATCH YOUR SPACING, DRIVER

* Changelog and devourment for some mobs.

Because I knew people were gunna ask.

NO YOU CANNOT EAT THE FUCKING LEGION

* Vore code sync (#157)

* sync (#3)

* shuttle auto call

* Merge /vore into /master (#39)

* progress

* Compile errors fixed

No idea if it's test worthy tho as conflicts with race overhaul and
narky removal.

* Update admins.txt

* efforts continue

Fuck grab code, seriously

* grab code is cancer

* Execute the Narkism

Do not hesitate.

Show no mercy.

* holy shit grab code is awful

* have I bitched about grab code

My bitching, let me show you it

* código de agarre es una mierda

No really it is

* yeah I don't even know anymore.

* Lolnope. Fuck grab code

* I'm not even sure what to fix anymore

* Self eating is not an acceptable fate

* Taste the void, son.

* My code doesn't pass it's own sanity check.

Maybe it's a sign of things to come.

* uncommented and notes

* It Works and I Don't Know Why (#38)

* shuttle auto call

* it works and I don't know why

* Escape and Devourable

For the normies who play here yet complain about it.

* Things that should be committed

* unneeded files

* Sizeray works now

* tweaks and bed time going

* IT WORKS mostly

Need to get multiple guts and saving working tho

* save tweaks

* item hotfix

* gut examine message

* damifino

* save system works

also ensured some mobs have vore controls, so silicons can't even
remotely do vore things.

* code nitpicking

* Midnight oil

More like 6am oil.  Still having issues with actually eating anyone.

* Subsystem 12/21

Most Recent TG subsystem folder

* globalvars 12/21

Tossed out the flavor_misc and parallax files

* Onclick 12/21

as well as .dme updates

* _defines 12/21

ommited old _MC.dm

* _HELPERS 12/21

Preserved snowflake placement of furry sprites

* _defeines/genetics

reapplied narkism holdover for snowflake races.

* Oops forgot mutant colors

* modules porting 12/21 + Sounds/icons

Admin, Client and most of mob life files ommitted

* enviroment file

* Admin optimizations

ahelp log system kept

* Mob ports 12/21

Flavor text preserved

* datums ported 12/21

* Game ported 12/21

* batch of duplicate fixes/dogborg work

Dogborgs need to be modernized to refractored borg standards.

* moar fixes

* Maps and futher compile fixes

* missed commit

* Noms

* specific release doesn't work

* Tg modernization patch (#115)

* sync (#3)

* shuttle auto call

* Merge /vore into /master (#39)

* progress

* Compile errors fixed

No idea if it's test worthy tho as conflicts with race overhaul and
narky removal.

* Update admins.txt

* efforts continue

Fuck grab code, seriously

* grab code is cancer

* Execute the Narkism

Do not hesitate.

Show no mercy.

* holy shit grab code is awful

* have I bitched about grab code

My bitching, let me show you it

* código de agarre es una mierda

No really it is

* yeah I don't even know anymore.

* Lolnope. Fuck grab code

* I'm not even sure what to fix anymore

* Self eating is not an acceptable fate

* Taste the void, son.

* My code doesn't pass it's own sanity check.

Maybe it's a sign of things to come.

* uncommented and notes

* It Works and I Don't Know Why (#38)

* shuttle auto call

* it works and I don't know why

* Subsystem 12/21

Most Recent TG subsystem folder

* globalvars 12/21

Tossed out the flavor_misc and parallax files

* Onclick 12/21

as well as .dme updates

* _defines 12/21

ommited old _MC.dm

* _HELPERS 12/21

Preserved snowflake placement of furry sprites

* _defeines/genetics

reapplied narkism holdover for snowflake races.

* Oops forgot mutant colors

* modules porting 12/21 + Sounds/icons

Admin, Client and most of mob life files ommitted

* enviroment file

* Admin optimizations

ahelp log system kept

* Mob ports 12/21

Flavor text preserved

* datums ported 12/21

* Game ported 12/21

* batch of duplicate fixes/dogborg work

Dogborgs need to be modernized to refractored borg standards.

* moar fixes

* Maps and futher compile fixes

* port from cactus did

* fix format error

* Update preferences.dm

unfuck

* Revert "port from cactus did"

* unfuck

* more sprite work

* vore

* disabled roundstart xenos for now

* admin QOL

needs callback porting, TBD

* Mentor system initial port

I'm sure I've missed a fuckton of shit

* test merge

* Jesus tits did this finally fix compile issues?

* Initial test compiles. hooray.

* Admin ticket fixes

* I'll give you a bad argument you piece of shit dream maker I fucking swear on my mum

* who list wip

also ahelps are broken again. fuck if I know why

* discord bot basics

* maybe tickets work now & bot framework done

* ahelp callback readd

* vore tweaks

* progress

* dirtier fix than a korean hooker in the 60s

* The release your hooker will always fake

* you could save that hookers number but wouldn't you rather just vore the hooker instead

* Save system is literal black magic

* great googly moogly it's all gone to shit

* We May 2015 save code now

* fiddling with digestion code now

* fuck if I know anymore. I'm going to bed

* OWN UP YOUR OWN DIGESTION

* UNREGULATED GUTS ARE NON COMPLIANT

AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA

* BELLIES MUST COMPLY WITH USER OWNERSHIP

* Removed debug messages

* Unneeded verb additions

* file change tweaks

* WATCH YOUR SPACING, DRIVER

* Changelog and devourment for some mobs.

Because I knew people were gunna ask.

NO YOU CANNOT EAT THE FUCKING LEGION

* title screen change from Crow's PR.

* More of Crow's title screen stuff

* mode tweaks.... again

* gamemode voting in lobby via TalkingCactus
disabled ashwalkers as roundstart
Verk's species tweak
paralax starts disabled by default

* LOOC

* index sync problem (#158)

* digifix

* things

* furry races.dm

* actually deletes species_types

* maps

* tgui and stuff

* Sounds

* icon updates

* Defines and helpers

* global vars and on click

* controllers

* datums

* game folder

* fixes invisible flan mobs

* some modules

* dropbomb verb enhanced

* moar

* moar

* moar

* even more again

* and finally these for modules

* Some compile tweaks

* silly dme get updated you scrub

* compiles cleanly now

* various open PR fixes from TG

as of 0800 Texas Standard Time

* also fancy cryopods before I forget again

* headslug gold core fix

* edgy code of the modernization (#164)

* sync (#3)

* shuttle auto call

* Merge /vore into /master (#39)

* progress

* Compile errors fixed

No idea if it's test worthy tho as conflicts with race overhaul and
narky removal.

* Update admins.txt

* efforts continue

Fuck grab code, seriously

* grab code is cancer

* Execute the Narkism

Do not hesitate.

Show no mercy.

* holy shit grab code is awful

* have I bitched about grab code

My bitching, let me show you it

* código de agarre es una mierda

No really it is

* yeah I don't even know anymore.

* Lolnope. Fuck grab code

* I'm not even sure what to fix anymore

* Self eating is not an acceptable fate

* Taste the void, son.

* My code doesn't pass it's own sanity check.

Maybe it's a sign of things to come.

* uncommented and notes

* It Works and I Don't Know Why (#38)

* shuttle auto call

* it works and I don't know why

* Escape and Devourable

For the normies who play here yet complain about it.

* Things that should be committed

* unneeded files

* Sizeray works now

* tweaks and bed time going

* IT WORKS mostly

Need to get multiple guts and saving working tho

* save tweaks

* item hotfix

* gut examine message

* damifino

* save system works

also ensured some mobs have vore controls, so silicons can't even
remotely do vore things.

* code nitpicking

* Midnight oil

More like 6am oil.  Still having issues with actually eating anyone.

* Subsystem 12/21

Most Recent TG subsystem folder

* globalvars 12/21

Tossed out the flavor_misc and parallax files

* Onclick 12/21

as well as .dme updates

* _defines 12/21

ommited old _MC.dm

* _HELPERS 12/21

Preserved snowflake placement of furry sprites

* _defeines/genetics

reapplied narkism holdover for snowflake races.

* Oops forgot mutant colors

* modules porting 12/21 + Sounds/icons

Admin, Client and most of mob life files ommitted

* enviroment file

* Admin optimizations

ahelp log system kept

* Mob ports 12/21

Flavor text preserved

* datums ported 12/21

* Game ported 12/21

* batch of duplicate fixes/dogborg work

Dogborgs need to be modernized to refractored borg standards.

* moar fixes

* Maps and futher compile fixes

* missed commit

* Noms

* specific release doesn't work

* Tg modernization patch (#115)

* sync (#3)

* shuttle auto call

* Merge /vore into /master (#39)

* progress

* Compile errors fixed

No idea if it's test worthy tho as conflicts with race overhaul and
narky removal.

* Update admins.txt

* efforts continue

Fuck grab code, seriously

* grab code is cancer

* Execute the Narkism

Do not hesitate.

Show no mercy.

* holy shit grab code is awful

* have I bitched about grab code

My bitching, let me show you it

* código de agarre es una mierda

No really it is

* yeah I don't even know anymore.

* Lolnope. Fuck grab code

* I'm not even sure what to fix anymore

* Self eating is not an acceptable fate

* Taste the void, son.

* My code doesn't pass it's own sanity check.

Maybe it's a sign of things to come.

* uncommented and notes

* It Works and I Don't Know Why (#38)

* shuttle auto call

* it works and I don't know why

* Subsystem 12/21

Most Recent TG subsystem folder

* globalvars 12/21

Tossed out the flavor_misc and parallax files

* Onclick 12/21

as well as .dme updates

* _defines 12/21

ommited old _MC.dm

* _HELPERS 12/21

Preserved snowflake placement of furry sprites

* _defeines/genetics

reapplied narkism holdover for snowflake races.

* Oops forgot mutant colors

* modules porting 12/21 + Sounds/icons

Admin, Client and most of mob life files ommitted

* enviroment file

* Admin optimizations

ahelp log system kept

* Mob ports 12/21

Flavor text preserved

* datums ported 12/21

* Game ported 12/21

* batch of duplicate fixes/dogborg work

Dogborgs need to be modernized to refractored borg standards.

* moar fixes

* Maps and futher compile fixes

* port from cactus did

* fix format error

* Update preferences.dm

unfuck

* Revert "port from cactus did"

* unfuck

* more sprite work

* vore

* disabled roundstart xenos for now

* admin QOL

needs callback porting, TBD

* Mentor system initial port

I'm sure I've missed a fuckton of shit

* test merge

* Jesus tits did this finally fix compile issues?

* Initial test compiles. hooray.

* Admin ticket fixes

* I'll give you a bad argument you piece of shit dream maker I fucking swear on my mum

* who list wip

also ahelps are broken again. fuck if I know why

* discord bot basics

* maybe tickets work now & bot framework done

* ahelp callback readd

* vore tweaks

* progress

* Small fixes for dogborgs and sprite accessories:
-Ported the hidden snippets of the dogborg code.
-Reset module now resets pixel offset and icon directory again. (broke shit when reseting from dogborg)
-Medihound belly fixed.
-Husky body marking tweaked to not overlap arms in side view.
-Added husky ears that are basically wolf ears that use secondary color instead.

* dirtier fix than a korean hooker in the 60s

* The release your hooker will always fake

* you could save that hookers number but wouldn't you rather just vore the hooker instead

* Save system is literal black magic

* great googly moogly it's all gone to shit

* We May 2015 save code now

* fiddling with digestion code now

* fuck if I know anymore. I'm going to bed

* OWN UP YOUR OWN DIGESTION

* UNREGULATED GUTS ARE NON COMPLIANT

AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA

* BELLIES MUST COMPLY WITH USER OWNERSHIP

* Removed debug messages

* Unneeded verb additions

* file change tweaks

* WATCH YOUR SPACING, DRIVER

* Changelog and devourment for some mobs.

Because I knew people were gunna ask.

NO YOU CANNOT EAT THE FUCKING LEGION

* title screen change from Crow's PR.

* More of Crow's title screen stuff

* mode tweaks.... again

* gamemode voting in lobby via TalkingCactus
disabled ashwalkers as roundstart
Verk's species tweak
paralax starts disabled by default

* LOOC

* index sync problem (#158)

* digifix

* things

* furry races.dm

* actually deletes species_types

* maps

* tgui and stuff

* Sounds

* icon updates

* Defines and helpers

* global vars and on click

* controllers

* datums

* game folder

* fixes invisible flan mobs

* some modules

* dropbomb verb enhanced

* moar

* moar

* moar

* even more again

* and finally these for modules

* Some compile tweaks

* silly dme get updated you scrub

* compiles cleanly now

* various open PR fixes from TG

as of 0800 Texas Standard Time

* also fancy cryopods before I forget again

* headslug gold core fix

* some species and DNA tweaks

* Digest already damn you

* suddenly sound and resist works. wtf

* Minor tweaks, cryopod noise change

* Vore tested working, species working

* Merge test onto bleeding edgy (#165)

* sync (#3)

* shuttle auto call

* Merge /vore into /master (#39)

* progress

* Compile errors fixed

No idea if it's test worthy tho as conflicts with race overhaul and
narky removal.

* Update admins.txt

* efforts continue

Fuck grab code, seriously

* grab code is cancer

* Execute the Narkism

Do not hesitate.

Show no mercy.

* holy shit grab code is awful

* have I bitched about grab code

My bitching, let me show you it

* código de agarre es una mierda

No really it is

* yeah I don't even know anymore.

* Lolnope. Fuck grab code

* I'm not even sure what to fix anymore

* Self eating is not an acceptable fate

* Taste the void, son.

* My code doesn't pass it's own sanity check.

Maybe it's a sign of things to come.

* uncommented and notes

* It Works and I Don't Know Why (#38)

* shuttle auto call

* it works and I don't know why

* Escape and Devourable

For the normies who play here yet complain about it.

* Things that should be committed

* unneeded files

* Sizeray works now

* tweaks and bed time going

* IT WORKS mostly

Need to get multiple guts and saving working tho

* save tweaks

* item hotfix

* gut examine message

* damifino

* save system works

also ensured some mobs have vore controls, so silicons can't even
remotely do vore things.

* code nitpicking

* Midnight oil

More like 6am oil.  Still having issues with actually eating anyone.

* Subsystem 12/21

Most Recent TG subsystem folder

* globalvars 12/21

Tossed out the flavor_misc and parallax files

* Onclick 12/21

as well as .dme updates

* _defines 12/21

ommited old _MC.dm

* _HELPERS 12/21

Preserved snowflake placement of furry sprites

* _defeines/genetics

reapplied narkism holdover for snowflake races.

* Oops forgot mutant colors

* modules porting 12/21 + Sounds/icons

Admin, Client and most of mob life files ommitted

* enviroment file

* Admin optimizations

ahelp log system kept

* Mob ports 12/21

Flavor text preserved

* datums ported 12/21

* Game ported 12/21

* batch of duplicate fixes/dogborg work

Dogborgs need to be modernized to refractored borg standards.

* moar fixes

* Maps and futher compile fixes

* missed commit

* Noms

* specific release doesn't work

* Tg modernization patch (#115)

* sync (#3)

* shuttle auto call

* Merge /vore into /master (#39)

* progress

* Compile errors fixed

No idea if it's test worthy tho as conflicts with race overhaul and
narky removal.

* Update admins.txt

* efforts continue

Fuck grab code, seriously

* grab code is cancer

* Execute the Narkism

Do not hesitate.

Show no mercy.

* holy shit grab code is awful

* have I bitched about grab code

My bitching, let me show you it

* código de agarre es una mierda

No really it is

* yeah I don't even know anymore.

* Lolnope. Fuck grab code

* I'm not even sure what to fix anymore

* Self eating is not an acceptable fate

* Taste the void, son.

* My code doesn't pass it's own sanity check.

Maybe it's a sign of things to come.

* uncommented and notes

* It Works and I Don't Know Why (#38)

* shuttle auto call

* it works and I don't know why

* Subsystem 12/21

Most Recent TG subsystem folder

* globalvars 12/21

Tossed out the flavor_misc and parallax files

* Onclick 12/21

as well as .dme updates

* _defines 12/21

ommited old _MC.dm

* _HELPERS 12/21

Preserved snowflake placement of furry sprites

* _defeines/genetics

reapplied narkism holdover for snowflake races.

* Oops forgot mutant colors

* modules porting 12/21 + Sounds/icons

Admin, Client and most of mob life files ommitted

* enviroment file

* Admin optimizations

ahelp log system kept

* Mob ports 12/21

Flavor text preserved

* datums ported 12/21

* Game ported 12/21

* batch of duplicate fixes/dogborg work

Dogborgs need to be modernized to refractored borg standards.

* moar fixes

* Maps and futher compile fixes

* port from cactus did

* fix format error

* Update preferences.dm

unfuck

* Revert "port from cactus did"

* unfuck

* more sprite work

* vore

* disabled roundstart xenos for now

* admin QOL

needs callback porting, TBD

* Mentor system initial port

I'm sure I've missed a fuckton of shit

* test merge

* Jesus tits did this finally fix compile issues?

* Initial test compiles. hooray.

* Admin ticket fixes

* I'll give you a bad argument you piece of shit dream maker I fucking swear on my mum

* who list wip

also ahelps are broken again. fuck if I know why

* discord bot basics

* maybe tickets work now & bot framework done

* ahelp callback readd

* vore tweaks

* progress

* Small fixes for dogborgs and sprite accessories:
-Ported the hidden snippets of the dogborg code.
-Reset module now resets pixel offset and icon directory again. (broke shit when reseting from dogborg)
-Medihound belly fixed.
-Husky body marking tweaked to not overlap arms in side view.
-Added husky ears that are basically wolf ears that use secondary color instead.

* dirtier fix than a korean hooker in the 60s

* The release your hooker will always fake

* you could save that hookers number but wouldn't you rather just vore the hooker instead

* Save system is literal black magic

* great googly moogly it's all gone to shit

* We May 2015 save code now

* fiddling with digestion code now

* fuck if I know anymore. I'm going to bed

* OWN UP YOUR OWN DIGESTION

* UNREGULATED GUTS ARE NON COMPLIANT

AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA

* BELLIES MUST COMPLY WITH USER OWNERSHIP

* Removed debug messages

* Unneeded verb additions

* file change tweaks

* WATCH YOUR SPACING, DRIVER

* Changelog and devourment for some mobs.

Because I knew people were gunna ask.

NO YOU CANNOT EAT THE FUCKING LEGION

* title screen change from Crow's PR.

* More of Crow's title screen stuff

* mode tweaks.... again

* gamemode voting in lobby via TalkingCactus
disabled ashwalkers as roundstart
Verk's species tweak
paralax starts disabled by default

* LOOC

* index sync problem (#158)

* digifix

* things

* furry races.dm

* actually deletes species_types

* maps

* tgui and stuff

* Sounds

* icon updates

* Defines and helpers

* global vars and on click

* controllers

* datums

* game folder

* fixes invisible flan mobs

* some modules

* dropbomb verb enhanced

* moar

* moar

* moar

* even more again

* and finally these for modules

* Some compile tweaks

* silly dme get updated you scrub

* compiles cleanly now

* various open PR fixes from TG

as of 0800 Texas Standard Time

* also fancy cryopods before I forget again

* headslug gold core fix

* some species and DNA tweaks

* Digest already damn you

* suddenly sound and resist works. wtf

* Minor tweaks, cryopod noise change

* Vore tested working, species working

* travis map updates

* updates

* pool's closed due to lag

* datum pools are closed too

* Initializing new pool's closed

* Pool's closed and initializing shit is done

* sprite updates

* chattering is okay to do now.

* bleeblin edgy 1/23 (#166)

* sync (#3)

* shuttle auto call

* Merge /vore into /master (#39)

* progress

* Compile errors fixed

No idea if it's test worthy tho as conflicts with race overhaul and
narky removal.

* Update admins.txt

* efforts continue

Fuck grab code, seriously

* grab code is cancer

* Execute the Narkism

Do not hesitate.

Show no mercy.

* holy shit grab code is awful

* have I bitched about grab code

My bitching, let me show you it

* código de agarre es una mierda

No really it is

* yeah I don't even know anymore.

* Lolnope. Fuck grab code

* I'm not even sure what to fix anymore

* Self eating is not an acceptable fate

* Taste the void, son.

* My code doesn't pass it's own sanity check.

Maybe it's a sign of things to come.

* uncommented and notes

* It Works and I Don't Know Why (#38)

* shuttle auto call

* it works and I don't know why

* Escape and Devourable

For the normies who play here yet complain about it.

* Things that should be committed

* unneeded files

* Sizeray works now

* tweaks and bed time going

* IT WORKS mostly

Need to get multiple guts and saving working tho

* save tweaks

* item hotfix

* gut examine message

* damifino

* save system works

also ensured some mobs have vore controls, so silicons can't even
remotely do vore things.

* code nitpicking

* Midnight oil

More like 6am oil.  Still having issues with actually eating anyone.

* Subsystem 12/21

Most Recent TG subsystem folder

* globalvars 12/21

Tossed out the flavor_misc and parallax files

* Onclick 12/21

as well as .dme updates

* _defines 12/21

ommited old _MC.dm

* _HELPERS 12/21

Preserved snowflake placement of furry sprites

* _defeines/genetics

reapplied narkism holdover for snowflake races.

* Oops forgot mutant colors

* modules porting 12/21 + Sounds/icons

Admin, Client and most of mob life files ommitted

* enviroment file

* Admin optimizations

ahelp log system kept

* Mob ports 12/21

Flavor text preserved

* datums ported 12/21

* Game ported 12/21

* batch of duplicate fixes/dogborg work

Dogborgs need to be modernized to refractored borg standards.

* moar fixes

* Maps and futher compile fixes

* missed commit

* Noms

* specific release doesn't work

* Tg modernization patch (#115)

* sync (#3)

* shuttle auto call

* Merge /vore into /master (#39)

* progress

* Compile errors fixed

No idea if it's test worthy tho as conflicts with race overhaul and
narky removal.

* Update admins.txt

* efforts continue

Fuck grab code, seriously

* grab code is cancer

* Execute the Narkism

Do not hesitate.

Show no mercy.

* holy shit grab code is awful

* have I bitched about grab code

My bitching, let me show you it

* código de agarre es una mierda

No really it is

* yeah I don't even know anymore.

* Lolnope. Fuck grab code

* I'm not even sure what to fix anymore

* Self eating is not an acceptable fate

* Taste the void, son.

* My code doesn't pass it's own sanity check.

Maybe it's a sign of things to come.

* uncommented and notes

* It Works and I Don't Know Why (#38)

* shuttle auto call

* it works and I don't know why

* Subsystem 12/21

Most Recent TG subsystem folder

* globalvars 12/21

Tossed out the flavor_misc and parallax files

* Onclick 12/21

as well as .dme updates

* _defines 12/21

ommited old _MC.dm

* _HELPERS 12/21

Preserved snowflake placement of furry sprites

* _defeines/genetics

reapplied narkism holdover for snowflake races.

* Oops forgot mutant colors

* modules porting 12/21 + Sounds/icons

Admin, Client and most of mob life files ommitted

* enviroment file

* Admin optimizations

ahelp log system kept

* Mob ports 12/21

Flavor text preserved

* datums ported 12/21

* Game ported 12/21

* batch of duplicate fixes/dogborg work

Dogborgs need to be modernized to refractored borg standards.

* moar fixes

* Maps and futher compile fixes

* port from cactus did

* fix format error

* Update preferences.dm

unfuck

* Revert "port from cactus did"

* unfuck

* more sprite work

* vore

* disabled roundstart xenos for now

* admin QOL

needs callback porting, TBD

* Mentor system initial port

I'm sure I've missed a fuckton of shit

* test merge

* Jesus tits did this finally fix compile issues?

* Initial test compiles. hooray.

* Admin ticket fixes

* I'll give you a bad argument you piece of shit dream maker I fucking swear on my mum

* who list wip

also ahelps are broken again. fuck if I know why

* discord bot basics

* maybe tickets work now & bot framework done

* ahelp callback readd

* vore tweaks

* progress

* Small fixes for dogborgs and sprite accessories:
-Ported the hidden snippets of the dogborg code.
-Reset module now resets pixel offset and icon directory again. (broke shit when reseting from dogborg)
-Medihound belly fixed.
-Husky body marking tweaked to not overlap arms in side view.
-Added husky ears that are basically wolf ears that use secondary color instead.

* dirtier fix than a korean hooker in the 60s

* The release your hooker will always fake

* you could save that hookers number but wouldn't you rather just vore the hooker instead

* Save system is literal black magic

* great googly moogly it's all gone to shit

* We May 2015 save code now

* fiddling with digestion code now

* fuck if I know anymore. I'm going to bed

* OWN UP YOUR OWN DIGESTION

* UNREGULATED GUTS ARE NON COMPLIANT

AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA

* BELLIES MUST COMPLY WITH USER OWNERSHIP

* Removed debug messages

* Unneeded verb additions

* file change tweaks

* WATCH YOUR SPACING, DRIVER

* Changelog and devourment for some mobs.

Because I knew people were gunna ask.

NO YOU CANNOT EAT THE FUCKING LEGION

* title screen change from Crow's PR.

* More of Crow's title screen stuff

* mode tweaks.... again

* gamemode voting in lobby via TalkingCactus
disabled ashwalkers as roundstart
Verk's species tweak
paralax starts disabled by default

* LOOC

* index sync problem (#158)

* digifix

* things

* furry races.dm

* actually deletes species_types

* maps

* tgui and stuff

* Sounds

* icon updates

* Defines and helpers

* global vars and on click

* controllers

* datums

* game folder

* fixes invisible flan mobs

* some modules

* dropbomb verb enhanced

* moar

* moar

* moar

* even more again

* and finally these for modules

* Some compile tweaks

* silly dme get updated you scrub

* compiles cleanly now

* various open PR fixes from TG

as of 0800 Texas Standard Time

* also fancy cryopods before I forget again

* headslug gold core fix

* some species and DNA tweaks

* Digest already damn you

* suddenly sound and resist works. wtf

* Minor tweaks, cryopod noise change

* Vore tested working, species working

* travis map updates

* updates

* pool's closed due to lag

* datum pools are closed too

* Initializing new pool's closed

* Pool's closed and initializing shit is done

* sprite updates

* chattering is okay to do now.

* Update .travis.yml

* Update .travis.yml

* Update .travis.yml

* Revert "Modern modern"

* Revert "Revert "Modern modern""

* fix it fix it fix it fix it

* fixes title screen - thanks crow

* Riding code reverted

* possible tgui fix?

* who the fuck even knows if this is the problem

* adds moths and sharks (no colors yet, not greyscaled)
adds LOOC back

* "fixes" missing items in some machinery.

* slight tweaks to abductor spawns
borer event enabled (max 1)

* Update .travis.yml

* fixes shuttle purchase from comms

* fixes and QoL

* Polymorphing all is dangerous too

* re-fixes ahelp ticket system again

* metagaming check proving to be spamlicious

* Fixes not being able to see devoured mob poses

* fix for vehicle buckling

* ahelp timer runtime fix (#178)

* controller and game updates 1/29

* Defines, helpers, datums 1/29

* world.dm updates

* modules/admin tweaks

* everything in modules not a mob

* modules/mob fixes and such

No more PAIs ventcrawling

* icons, maps, tools, etc.

* compiler fixes

* round type vote fixed

* hardsuit cargo pack

* reduce ion and electric storm chance

* perms access for travis

* fix helmet to the suit
removes CE from crate

* changelog

* fuck

* perms for travis... again

* Update tgstation.dme

* Update tgstation.dme

* Donation race

* redpanda

* red panda

* size play work

* Size chemical basics

Needs testing/refining

* some fixing ports before I just fucking ported it anyway

* It's been a fucking week.

* commiting moar changes because github

* admins.txt lol

* icons

* defines and such

* globalvars and onclick

* Controllers

* datums

* game folder

* oh look, HoG is back

* modules pt 1

* client things

* more modules

* everything not mob code

* some mob stuff

* more mob things

* silicon mobs

* ayylims and monkeys

* human updates

* huh

* housekeeping is fired.

* last minute fixes

* more last minute things

* human parts double check'd

* more paper

* Icons are fixed

* double check of thermal protection code. (#191)
This commit is contained in:
TalkingCactus
2017-02-03 06:56:14 -05:00
committed by Poojawa
parent 7735dec0ec
commit f7c09077d2
2489 changed files with 830965 additions and 416701 deletions

View File

@@ -1 +0,0 @@
#define CLICKCATCHER_PLANE -99

View File

@@ -34,6 +34,14 @@
if(control_disabled || stat)
return
var/turf/pixel_turf = get_turf_pixel(A)
var/turf_visible = cameranet.checkTurfVis(pixel_turf)
if(pixel_turf && !turf_visible)
log_admin("[key_name_admin(src)] might be running a modified client! (failed checkTurfVis on AI click of [A]([COORD(pixel_turf)])")
message_admins("[key_name_admin(src)] might be running a modified client! (failed checkTurfVis on AI click of [A]([ADMIN_COORDJMP(pixel_turf)]))")
send2admindiscord("NOCHEAT", "[key_name(src)] might be running a modified client! (failed checkTurfVis on AI click of [A]([COORD(pixel_turf)]))")
return
var/list/modifiers = params2list(params)
if(modifiers["shift"] && modifiers["ctrl"])
CtrlShiftClickOn(A)
@@ -57,13 +65,13 @@
if(world.time <= next_move)
return
if(aicamera.in_camera_mode)
if(aicamera.in_camera_mode && pixel_turf && turf_visible)
aicamera.camera_mode_off()
aicamera.captureimage(A, usr)
aicamera.captureimage(pixel_turf, usr)
return
if(waypoint_mode)
set_waypoint(A)
waypoint_mode = 0
set_waypoint(A)
return
/*
@@ -128,7 +136,7 @@
Topic("aiEnable=4", list("aiEnable"="4"), 1)// 1 meaning no window (consistency!)
else
Topic("aiDisable=4", list("aiDisable"="4"), 1)
return
/obj/machinery/door/airlock/AIAltClick() // Eletrifies doors.
if(emagged)
return
@@ -138,7 +146,7 @@
else
// disable/6 is not in Topic; disable/5 disables both temporary and permenant shock
Topic("aiDisable=5", list("aiDisable"="5"), 1)
return
/obj/machinery/door/airlock/AIShiftClick() // Opens and closes doors!
if(emagged)
return
@@ -146,7 +154,7 @@
Topic("aiEnable=7", list("aiEnable"="7"), 1) // 1 meaning no window (consistency!)
else
Topic("aiDisable=7", list("aiDisable"="7"), 1)
return
/obj/machinery/door/airlock/AICtrlShiftClick() // Sets/Unsets Emergency Access Override
if(emagged)
return
@@ -154,12 +162,12 @@
Topic("aiEnable=11", list("aiEnable"="11"), 1) // 1 meaning no window (consistency!)
else
Topic("aiDisable=11", list("aiDisable"="11"), 1)
return
/* APC */
/obj/machinery/power/apc/AICtrlClick() // turns off/on APCs.
toggle_breaker()
add_fingerprint(usr)
if(can_use(usr, 1))
toggle_breaker()
add_fingerprint(usr)
/* AI Turrets */
/obj/machinery/turretid/AIAltClick() //toggles lethal on turrets

View File

@@ -23,7 +23,7 @@
/mob/living/carbon/CanMobAutoclick(atom/object, location, params)
if(!object.IsAutoclickable())
return
var/obj/item/h = get_active_hand()
var/obj/item/h = get_active_held_item()
if(h)
. = h.CanItemAutoclick(object, location, params)

View File

@@ -32,9 +32,13 @@
*/
/atom/Click(location,control,params)
usr.ClickOn(src, params)
/atom/DblClick(location,control,params)
usr.DblClickOn(src,params)
/atom/MouseWheel(delta_x,delta_y,location,control,params)
usr.MouseWheelOn(src, delta_x, delta_y, params)
/*
Standard mob ClickOn()
Handles exceptions: Buildmode, middle click, modified clicks, mech actions
@@ -53,7 +57,7 @@
return
next_click = world.time + 1
if(client.click_intercept)
if(client && client.click_intercept)
if(call(client.click_intercept, "InterceptClickOn")(src, params, A))
return
@@ -98,24 +102,22 @@
throw_item(A)
return
var/obj/item/W = get_active_hand()
var/obj/item/W = get_active_held_item()
if(W == A)
W.attack_self(src)
if(hand)
update_inv_l_hand(0)
else
update_inv_r_hand(0)
update_inv_hands()
return
// operate three levels deep here (item in backpack in src; item in box in backpack in src, not any deeper)
if(!isturf(A) && A == loc || (A in contents) || (A.loc in contents) || (A.loc && (A.loc.loc in contents)))
if(A.ClickAccessible(src, depth=INVENTORY_DEPTH))
// No adjacency needed
if(W)
var/resolved = A.attackby(W,src)
if(!resolved && A && W)
W.afterattack(A,src,1,params) // 1 indicates adjacency
if(W.pre_attackby(A,src,params))
var/resolved = A.attackby(W,src)
if(!resolved && A && W)
W.afterattack(A,src,1,params) // 1 indicates adjacency
else
if(ismob(A))
changeNext_move(CLICK_CD_MELEE)
@@ -129,10 +131,11 @@
if(isturf(A) || isturf(A.loc) || (A.loc && isturf(A.loc.loc)))
if(A.Adjacent(src)) // see adjacent.dm
if(W)
// Return 1 in attackby() to prevent afterattack() effects (when safely moving items for example)
var/resolved = A.attackby(W,src,params)
if(!resolved && A && W)
W.afterattack(A,src,1,params) // 1: clicking something Adjacent
if(W.pre_attackby(A,src,params))
// Return 1 in attackby() to prevent afterattack() effects (when safely moving items for example)
var/resolved = A.attackby(W,src,params)
if(!resolved && A && W)
W.afterattack(A,src,1,params) // 1: clicking something Adjacent
else
if(ismob(A))
changeNext_move(CLICK_CD_MELEE)
@@ -222,6 +225,7 @@
Ctrl click
For most objects, pull
*/
/mob/proc/CtrlClickOn(atom/A)
A.CtrlClick(src)
return
@@ -231,6 +235,13 @@
if(istype(ML))
ML.pulled(src)
/mob/living/carbon/human/CtrlClick(mob/user)
if(ishuman(user) && Adjacent(user))
var/mob/living/carbon/human/H = user
H.dna.species.grab(H, src, H.martial_art)
H.next_click = world.time + CLICK_CD_MELEE
else
..()
/*
Alt click
Unused except for AI
@@ -274,6 +285,21 @@
/atom/proc/CtrlShiftClick(mob/user)
return
/*
Helper to check can the mob click/access an item.
Used by mob inventory and storage items.
*/
/atom/proc/ClickAccessible(mob/user, depth=1)
if(src == user.loc || (src in user.contents))
return TRUE
if(loc && depth > 1)
return loc.ClickAccessible(user, depth-1)
/turf/ClickAccessible(mob/user, depth=1)
return
/*
Misc helpers
@@ -334,15 +360,11 @@
icon_state = "click_catcher"
plane = CLICKCATCHER_PLANE
mouse_opacity = 2
screen_loc = "CENTER-7,CENTER-7"
screen_loc = "CENTER"
/obj/screen/click_catcher/proc/MakeGreed()
. = list()
for(var/i = 0, i<15, i++)
for(var/j = 0, j<15, j++)
var/obj/screen/click_catcher/CC = new()
CC.screen_loc = "NORTH-[i],EAST-[j]"
. += CC
/obj/screen/click_catcher/New()
..()
transform = matrix(200, 0, 0, 0, 200, 0)
/obj/screen/click_catcher/Click(location, control, params)
var/list/modifiers = params2list(params)
@@ -350,7 +372,23 @@
var/mob/living/carbon/C = usr
C.swap_hand()
else
var/turf/T = screen_loc2turf(screen_loc, get_turf(usr))
var/turf/T = params2turf(modifiers["screen-loc"], get_turf(usr))
if(T)
T.Click(location, control, params)
. = 1
. = 1
/* MouseWheelOn */
/mob/proc/MouseWheelOn(atom/A, delta_x, delta_y, params)
return
/mob/dead/observer/MouseWheelOn(atom/A, delta_x, delta_y, params)
var/list/modifier = params2list(params)
if(modifier["shift"])
var/view = 0
if(delta_y > 0)
view = -1
else
view = 1
add_view_range(view)

View File

@@ -51,7 +51,7 @@
aicamera.captureimage(A, usr)
return
var/obj/item/W = get_active_hand()
var/obj/item/W = get_active_held_item()
// Cyborgs have no range-checking unless there is item use
if(!W)
@@ -69,9 +69,10 @@
// cyborgs are prohibited from using storage items so we can I think safely remove (A.loc in contents)
if(A == loc || (A in loc) || (A in contents))
// No adjacency checks
var/resolved = A.attackby(W,src, params)
if(!resolved && A && W)
W.afterattack(A,src,1,params)
if(W.pre_attackby(A,src,params))
var/resolved = A.attackby(W,src, params)
if(!resolved && A && W)
W.afterattack(A,src,1,params)
return
if(!isturf(loc))
@@ -80,9 +81,10 @@
// cyborgs are prohibited from using storage items so we can I think safely remove (A.loc && isturf(A.loc.loc))
if(isturf(A) || isturf(A.loc))
if(A.Adjacent(src)) // see adjacent.dm
var/resolved = A.attackby(W, src, params)
if(!resolved && A && W)
W.afterattack(A, src, 1, params)
if(W.pre_attackby(A,src,params))
var/resolved = A.attackby(W, src, params)
if(!resolved && A && W)
W.afterattack(A, src, 1, params)
return
else
W.afterattack(A, src, 0, params)

View File

@@ -17,53 +17,67 @@
Therefore, the top right corner (except during admin shenanigans) is at "15,15"
*/
//Lower left, persistant menu
//Lower left, persistent menu
#define ui_inventory "WEST:6,SOUTH:5"
//Middle left indicators
#define ui_lingchemdisplay "WEST:6,CENTER-1:15"
#define ui_lingstingdisplay "WEST:6,CENTER-3:11"
#define ui_crafting "12:-10,1:5"
#define ui_building "12:-10,1:21"
#define ui_devilsouldisplay "WEST:6,CENTER-1:15"
//Lower center, persistant menu
//Lower center, persistent menu
#define ui_sstore1 "CENTER-5:10,SOUTH:5"
#define ui_id "CENTER-4:12,SOUTH:5"
#define ui_belt "CENTER-3:14,SOUTH:5"
#define ui_back "CENTER-2:14,SOUTH:5"
#define ui_rhand "CENTER:-16,SOUTH:5"
#define ui_lhand "CENTER: 16,SOUTH:5"
#define ui_equip "CENTER:-16,SOUTH+1:5"
#define ui_swaphand1 "CENTER:-16,SOUTH+1:5"
#define ui_swaphand2 "CENTER: 16,SOUTH+1:5"
/proc/ui_hand_position(i) //values based on old hand ui positions (CENTER:-/+16,SOUTH:5)
var/x_off = -(!(i % 2))
var/y_off = round((i-1) / 2)
return"CENTER+[x_off]:16,SOUTH+[y_off]:5"
/proc/ui_equip_position(mob/M)
var/y_off = round((M.held_items.len-1) / 2) //values based on old equip ui position (CENTER: +/-16,SOUTH+1:5)
return "CENTER:-16,SOUTH+[y_off+1]:5"
/proc/ui_swaphand_position(mob/M, which = 1) //values based on old swaphand ui positions (CENTER: +/-16,SOUTH+1:5)
var/x_off = which == 1 ? -1 : 0
var/y_off = round((M.held_items.len-1) / 2)
return "CENTER+[x_off]:16,SOUTH+[y_off+1]:5"
#define ui_storage1 "CENTER+1:18,SOUTH:5"
#define ui_storage2 "CENTER+2:20,SOUTH:5"
#define ui_borg_sensor "CENTER-3:16, SOUTH:5" //borgs
#define ui_borg_lamp "CENTER-4:16, SOUTH:5" //borgies
#define ui_borg_thrusters "CENTER-5:16, SOUTH:5"//borgies
#define ui_inv1 "CENTER-2:16,SOUTH:5" //borgs
#define ui_inv2 "CENTER-1 :16,SOUTH:5" //borgs
#define ui_inv3 "CENTER :16,SOUTH:5" //borgs
#define ui_borg_module "CENTER+1:16,SOUTH:5"
#define ui_borg_store "CENTER+2:16,SOUTH:5" //borgs
#define ui_borg_camera "CENTER+3:21,SOUTH:5" //borgs
#define ui_borg_album "CENTER+4:21,SOUTH:5" //borgs
#define ui_borg_sensor "CENTER-3:16, SOUTH:5" //borgs
#define ui_borg_lamp "CENTER-4:16, SOUTH:5" //borgs
#define ui_borg_thrusters "CENTER-5:16, SOUTH:5" //borgs
#define ui_inv1 "CENTER-2:16,SOUTH:5" //borgs
#define ui_inv2 "CENTER-1 :16,SOUTH:5" //borgs
#define ui_inv3 "CENTER :16,SOUTH:5" //borgs
#define ui_borg_module "CENTER+1:16,SOUTH:5" //borgs
#define ui_borg_store "CENTER+2:16,SOUTH:5" //borgs
#define ui_borg_camera "CENTER+3:21,SOUTH:5" //borgs
#define ui_borg_album "CENTER+4:21,SOUTH:5" //borgs
#define ui_borg_talk_wheel "CENTER+4:21,SOUTH+1:5" //borgs
#define ui_monkey_head "CENTER-4:13,SOUTH:5" //monkey
#define ui_monkey_mask "CENTER-3:14,SOUTH:5" //monkey
#define ui_monkey_back "CENTER-2:15,SOUTH:5" //monkey
#define ui_monkey_neck "CENTER-2:15,SOUTH:5" //monkey
#define ui_monkey_back "CENTER-1:16,SOUTH:5" //monkey
#define ui_alien_storage_l "CENTER-2:14,SOUTH:5"//alien
#define ui_alien_storage_r "CENTER+1:18,SOUTH:5"//alien
#define ui_alien_talk_wheel "EAST-3:26,SOUTH:5" //alien
#define ui_drone_drop "CENTER+1:18,SOUTH:5" //maintenance drones
#define ui_drone_pull "CENTER+2:2,SOUTH:5" //maintenance drones
#define ui_drone_storage "CENTER-2:14,SOUTH:5" //maintenance drones
#define ui_drone_head "CENTER-3:14,SOUTH:5" //maintenance drones
//Lower right, persistant menu
//Lower right, persistent menu
#define ui_drop_throw "EAST-1:28,SOUTH+1:7"
#define ui_pull_resist "EAST-2:26,SOUTH+1:7"
#define ui_movi "EAST-2:26,SOUTH:5"
@@ -94,6 +108,7 @@
#define ui_borg_health "EAST-1:28,CENTER-1:15" //borgs have the health display where humans have the pressure damage indicator.
#define ui_alien_health "EAST-1:28,CENTER-1:15" //aliens have the health display where humans have the pressure damage indicator.
#define ui_alienplasmadisplay "EAST-1:28,CENTER-2:15"
#define ui_alien_queen_finder "EAST-1:28,CENTER-3:15"
// AI
@@ -120,18 +135,19 @@
#define ui_oclothing "WEST+1:8,SOUTH+1:7"
#define ui_gloves "WEST+2:10,SOUTH+1:7"
#define ui_glasses "WEST:6,SOUTH+2:9"
#define ui_glasses "WEST:6,SOUTH+3:11"
#define ui_mask "WEST+1:8,SOUTH+2:9"
#define ui_ears "WEST+2:10,SOUTH+2:9"
#define ui_neck "WEST:6,SOUTH+2:9"
#define ui_head "WEST+1:8,SOUTH+3:11"
//Ghosts
#define ui_ghost_jumptomob "SOUTH:6,CENTER-2:16"
#define ui_ghost_orbit "SOUTH:6,CENTER-1:16"
#define ui_ghost_reenter_corpse "SOUTH:6,CENTER:16"
#define ui_ghost_teleport "SOUTH:6,CENTER+1:16"
#define ui_ghost_jumptomob "SOUTH:6,CENTER-2:24"
#define ui_ghost_orbit "SOUTH:6,CENTER-1:24"
#define ui_ghost_reenter_corpse "SOUTH:6,CENTER:24"
#define ui_ghost_teleport "SOUTH:6,CENTER+1:24"
#define ui_ghost_pai "SOUTH: 6, CENTER+2:24"
//Hand of God, god

View File

@@ -1,8 +1,13 @@
#define ACTION_BUTTON_DEFAULT_BACKGROUND "default"
/obj/screen/movable/action_button
var/datum/action/linked_action
var/actiontooltipstyle = ""
screen_loc = null
var/button_icon_state
var/appearance_cache
/obj/screen/movable/action_button/Click(location,control,params)
var/list/modifiers = params2list(params)
if(modifiers["shift"])
@@ -20,6 +25,9 @@
icon = 'icons/mob/actions.dmi'
icon_state = "bg_default"
var/hidden = 0
var/hide_icon = 'icons/mob/actions.dmi'
var/hide_state = "hide"
var/show_state = "show"
/obj/screen/movable/action_button/hide_toggle/Click(location,control,params)
var/list/modifiers = params2list(params)
@@ -37,33 +45,44 @@
usr.update_action_buttons()
/obj/screen/movable/action_button/hide_toggle/proc/InitialiseIcon(mob/living/user)
if(isalien(user))
icon_state = "bg_alien"
else
icon_state = "bg_default"
/obj/screen/movable/action_button/hide_toggle/proc/InitialiseIcon(datum/hud/owner_hud)
var settings = owner_hud.get_action_buttons_icons()
icon = settings["bg_icon"]
icon_state = settings["bg_state"]
hide_icon = settings["toggle_icon"]
hide_state = settings["toggle_hide"]
show_state = settings["toggle_show"]
UpdateIcon()
return
/obj/screen/movable/action_button/hide_toggle/proc/UpdateIcon()
cut_overlays()
var/image/img = image(icon, src, hidden ? "show" : "hide")
var/image/img = image(hide_icon, src, hidden ? show_state : hide_state)
add_overlay(img)
return
/obj/screen/movable/action_button/MouseEntered(location,control,params)
openToolTip(usr,src,params,title = name,content = desc)
openToolTip(usr,src,params,title = name,content = desc,theme = actiontooltipstyle)
/obj/screen/movable/action_button/MouseExited()
closeToolTip(usr)
/datum/hud/proc/get_action_buttons_icons()
. = list()
.["bg_icon"] = ui_style_icon
.["bg_state"] = "template"
//TODO : Make these fit theme
.["toggle_icon"] = 'icons/mob/actions.dmi'
.["toggle_hide"] = "hide"
.["toggle_show"] = "show"
/mob/proc/update_action_buttons_icon()
//see human and alien hud for specific implementations.
/mob/proc/update_action_buttons_icon(status_only = FALSE)
for(var/X in actions)
var/datum/action/A = X
A.UpdateButtonIcon()
A.UpdateButtonIcon(status_only)
//This is the proc used to update all the action buttons.
/mob/proc/update_action_buttons(reload_screen)

View File

@@ -1,11 +1,17 @@
/obj/screen/ai
icon = 'icons/mob/screen_ai.dmi'
/obj/screen/ai/Click()
if(isobserver(usr))
return 1
/obj/screen/ai/aicore
name = "AI core"
icon_state = "ai_core"
/obj/screen/ai/aicore/Click()
if(..())
return
var/mob/living/silicon/ai/AI = usr
AI.view_core()
@@ -23,6 +29,8 @@
icon_state = "track"
/obj/screen/ai/camera_track/Click()
if(..())
return
var/mob/living/silicon/ai/AI = usr
var/target_name = input(AI, "Choose who you want to track", "Tracking") as null|anything in AI.trackable_mobs()
AI.ai_camera_track(target_name)
@@ -32,6 +40,8 @@
icon_state = "camera_light"
/obj/screen/ai/camera_light/Click()
if(..())
return
var/mob/living/silicon/ai/AI = usr
AI.toggle_camera_light()
@@ -40,6 +50,8 @@
icon_state = "crew_monitor"
/obj/screen/ai/crew_monitor/Click()
if(..())
return
var/mob/living/silicon/ai/AI = usr
crewmonitor.show(AI)
@@ -48,6 +60,8 @@
icon_state = "manifest"
/obj/screen/ai/crew_manifest/Click()
if(..())
return
var/mob/living/silicon/ai/AI = usr
AI.ai_roster()
@@ -56,14 +70,18 @@
icon_state = "alerts"
/obj/screen/ai/alerts/Click()
if(..())
return
var/mob/living/silicon/ai/AI = usr
AI.ai_alerts()
/obj/screen/ai/announcement
name = "Make Announcement"
name = "Make Vox Announcement"
icon_state = "announcement"
/obj/screen/ai/announcement/Click()
if(..())
return
var/mob/living/silicon/ai/AI = usr
AI.announcement()
@@ -72,6 +90,8 @@
icon_state = "call_shuttle"
/obj/screen/ai/call_shuttle/Click()
if(..())
return
var/mob/living/silicon/ai/AI = usr
AI.ai_call_shuttle()
@@ -80,6 +100,8 @@
icon_state = "state_laws"
/obj/screen/ai/state_laws/Click()
if(..())
return
var/mob/living/silicon/ai/AI = usr
AI.checklaws()
@@ -88,6 +110,8 @@
icon_state = "pda_send"
/obj/screen/ai/pda_msg_send/Click()
if(..())
return
var/mob/living/silicon/ai/AI = usr
AI.cmd_send_pdamesg(usr)
@@ -96,6 +120,8 @@
icon_state = "pda_receive"
/obj/screen/ai/pda_msg_show/Click()
if(..())
return
var/mob/living/silicon/ai/AI = usr
AI.cmd_show_message_log(usr)
@@ -107,7 +133,7 @@
if(isAI(usr))
var/mob/living/silicon/ai/AI = usr
AI.aicamera.toggle_camera_mode()
else if(isrobot(usr))
else if(iscyborg(usr))
var/mob/living/silicon/robot/R = usr
R.aicamera.toggle_camera_mode()
@@ -119,7 +145,7 @@
if(isAI(usr))
var/mob/living/silicon/ai/AI = usr
AI.aicamera.viewpictures()
else if(isrobot(usr))
else if(iscyborg(usr))
var/mob/living/silicon/robot/R = usr
R.aicamera.viewpictures()
@@ -128,11 +154,16 @@
icon_state = "ai_sensor"
/obj/screen/ai/sensors/Click()
if(..())
return
var/mob/living/silicon/S = usr
S.sensor_mode()
/datum/hud/ai/New(mob/owner)
/datum/hud/ai
ui_style_icon = 'icons/mob/screen_ai.dmi'
/datum/hud/ai/New(mob/owner, ui_style = 'icons/mob/screen_ai.dmi')
..()
var/obj/screen/using
@@ -215,4 +246,4 @@
/mob/living/silicon/ai/create_mob_hud()
if(client && !hud_used)
hud_used = new /datum/hud/ai(src)
hud_used = new /datum/hud/ai(src)

View File

@@ -33,13 +33,16 @@
else //no need to update
return 0
else
alert = PoolOrNew(type)
alert = new type()
if(new_master)
var/old_layer = new_master.layer
var/old_plane = new_master.plane
new_master.layer = FLOAT_LAYER
new_master.plane = FLOAT_PLANE
alert.overlays += new_master
new_master.layer = old_layer
new_master.plane = old_plane
alert.icon_state = "template" // We'll set the icon to the client's ui pref in reorganize_alerts()
alert.master = new_master
else
@@ -53,12 +56,14 @@
animate(alert, transform = matrix(), time = 2.5, easing = CUBIC_EASING)
if(alert.timeout)
spawn(alert.timeout)
if(alert.timeout && alerts[category] == alert && world.time >= alert.timeout)
clear_alert(category)
addtimer(CALLBACK(src, .proc/alert_timeout, alert, category), alert.timeout)
alert.timeout = world.time + alert.timeout - world.tick_lag
return alert
/mob/proc/alert_timeout(obj/screen/alert/alert, category)
if(alert.timeout && alerts[category] == alert && world.time >= alert.timeout)
clear_alert(category)
// Proc to clear an existing alert.
/mob/proc/clear_alert(category)
var/obj/screen/alert/alert = alerts[category]
@@ -240,6 +245,163 @@ or shoot a gun to move around via Newton's 3rd Law of Motion."
icon_state = "blobbernaut_nofactory"
alerttooltipstyle = "blob"
// CLOCKCULT
/obj/screen/alert/clockwork
alerttooltipstyle = "clockcult"
/obj/screen/alert/clockwork/scripture_reqs
name = "Next Tier Requirements"
desc = "You shouldn't be seeing this description unless you're very fast. If you're very fast, good job!"
icon_state = "no-servants-caches"
var/static/list/scripture_states = list(SCRIPTURE_DRIVER = TRUE, SCRIPTURE_SCRIPT = FALSE, SCRIPTURE_APPLICATION = FALSE, SCRIPTURE_REVENANT = FALSE, SCRIPTURE_JUDGEMENT = FALSE)
/obj/screen/alert/clockwork/scripture_reqs/New()
..()
START_PROCESSING(SSprocessing, src)
process()
/obj/screen/alert/clockwork/scripture_reqs/Destroy()
STOP_PROCESSING(SSprocessing, src)
return ..()
/obj/screen/alert/clockwork/scripture_reqs/process()
if(clockwork_gateway_activated)
qdel(src)
return
var/current_state
scripture_states = scripture_unlock_check()
for(var/i in scripture_states)
if(!scripture_states[i])
current_state = i
break
icon_state = "no"
if(!current_state)
name = "Current Objective"
for(var/obj/structure/destructible/clockwork/massive/celestial_gateway/G in all_clockwork_objects)
var/area/gate_area = get_area(G)
desc = "<b>Protect the Ark at [gate_area.map_name]!</b>"
return
desc = "<b>All tiers of Scripture are unlocked.<br>\
Acquire components and summon the Ark.</b>"
else
name = "Next Tier Requirements"
var/validservants = 0
var/unconverted_ais_exist = FALSE
for(var/mob/living/L in living_mob_list)
if(is_servant_of_ratvar(L) && (ishuman(L) || issilicon(L)))
validservants++
else if(isAI(L))
unconverted_ais_exist++
var/req_servants = 0
var/req_caches = 0
var/req_cv = 0
var/req_ai = FALSE
desc = "Requirements for <b>[current_state] Scripture:</b>"
switch(current_state) //get our requirements based on the tier
if(SCRIPTURE_SCRIPT)
req_servants = SCRIPT_SERVANT_REQ
req_caches = SCRIPT_CACHE_REQ
if(SCRIPTURE_APPLICATION)
req_servants = APPLICATION_SERVANT_REQ
req_caches = APPLICATION_CACHE_REQ
req_cv = APPLICATION_CV_REQ
if(SCRIPTURE_REVENANT)
req_servants = REVENANT_SERVANT_REQ
req_caches = REVENANT_CACHE_REQ
req_cv = REVENANT_CV_REQ
if(SCRIPTURE_JUDGEMENT)
req_servants = JUDGEMENT_SERVANT_REQ
req_caches = JUDGEMENT_CACHE_REQ
req_cv = JUDGEMENT_CV_REQ
req_ai = TRUE
desc += "<br><b>[validservants]/[req_servants]</b> Servants"
if(validservants < req_servants)
icon_state += "-servants" //in this manner, generate an icon key based on what we're missing
else
desc += ": <b><font color=#5A6068>\[CHECK\]</font></b>"
desc += "<br><b>[clockwork_caches]/[req_caches]</b> Tinkerer's Caches"
if(clockwork_caches < req_caches)
icon_state += "-caches"
else
desc += ": <b><font color=#5A6068>\[CHECK\]</font></b>"
if(req_cv) //cv only shows up if the tier requires it
desc += "<br><b>[clockwork_construction_value]/[req_cv]</b> Construction Value"
if(clockwork_construction_value < req_cv)
icon_state += "-cv"
else
desc += ": <b><font color=#5A6068>\[CHECK\]</font></b>"
if(req_ai) //same for ai
if(unconverted_ais_exist)
if(unconverted_ais_exist > 1)
desc += "<br><b>[unconverted_ais_exist] unconverted AIs exist!</b><br>"
else
desc += "<br><b>An unconverted AI exists!</b>"
icon_state += "-ai"
else
desc += "<br>No unconverted AIs exist: <b><font color=#5A6068>\[CHECK\]</font></b>"
/obj/screen/alert/clockwork/infodump
name = "Global Records"
desc = "You shouldn't be seeing this description, because it should be dynamically generated."
icon_state = "clockinfo"
/obj/screen/alert/clockwork/infodump/MouseEntered(location,control,params)
if(ratvar_awakens)
desc = "<font size=3><b>CHETR<br>NYY<br>HAGEHUGF-NAQ-UBABE<br>RATVAR.</b></font>"
else
var/servants = 0
var/validservants = 0
var/unconverted_ais_exist = FALSE
var/list/scripture_states = scripture_unlock_check()
for(var/mob/living/L in living_mob_list)
if(is_servant_of_ratvar(L))
servants++
if(ishuman(L) || issilicon(L))
validservants++
else if(isAI(L))
unconverted_ais_exist++
if(servants > 1)
if(validservants > 1)
desc = "<b>[servants]</b> Servants, <b>[validservants]</b> of which count towards scripture.<br>"
else
desc = "<b>[servants]</b> Servants, [validservants ? "<b>[validservants]</b> of which counts":"none of which count"] towards scripture.<br>"
else
desc = "<b>[servants]</b> Servant, who [validservants ? "counts":"does not count"] towards scripture.<br>"
desc += "<b>[clockwork_caches ? "[clockwork_caches]</b> Tinkerer's Caches.":"No Tinkerer's Caches, construct one!</b>"]<br>\
<b>[clockwork_construction_value]</b> Construction Value.<br>"
if(clockwork_daemons)
desc += "<b>[clockwork_daemons]</b> Tinkerer's Daemons: <b>[servants * 0.2 < clockwork_daemons ? "DISABLED":"ACTIVE"]</b><br>"
else
desc += "No Tinkerer's Daemons.<br>"
for(var/obj/structure/destructible/clockwork/massive/celestial_gateway/G in all_clockwork_objects)
var/area/gate_area = get_area(G)
desc += "Ark Location: <b>[uppertext(gate_area.map_name)]</b><br>"
if(G.ratvar_portal)
desc += "Seconds until Ratvar's arrival: <b>[G.get_arrival_text(TRUE)]</b><br>"
else
desc += "Seconds until Proselytization: <b>[G.get_arrival_text(TRUE)]</b><br>"
if(unconverted_ais_exist)
if(unconverted_ais_exist > 1)
desc += "<b>[unconverted_ais_exist] unconverted AIs exist!</b><br>"
else
desc += "<b>An unconverted AI exists!</b><br>"
if(scripture_states[SCRIPTURE_REVENANT])
var/inathneq_available = clockwork_generals_invoked["inath-neq"] <= world.time
var/sevtug_available = clockwork_generals_invoked["sevtug"] <= world.time
var/nezbere_available = clockwork_generals_invoked["nezbere"] <= world.time
var/nezcrentr_available = clockwork_generals_invoked["nzcrentr"] <= world.time
if(inathneq_available || sevtug_available || nezbere_available || nezcrentr_available)
desc += "Generals available:<b>[inathneq_available ? "<br><font color=#1E8CE1>INATH-NEQ</font>":""][sevtug_available ? "<br><font color=#AF0AAF>SEVTUG</font>":""]\
[nezbere_available ? "<br><font color=#5A6068>NEZBERE</font>":""][nezcrentr_available ? "<br><font color=#DAAA18>NZCRENTR</font>":""]</b><br>"
else
desc += "Generals available: <b>NONE</b><br>"
else
desc += "Generals available: <b>NONE</b><br>"
for(var/i in scripture_states)
if(i != SCRIPTURE_DRIVER) //ignore the always-unlocked stuff
desc += "[i] Scripture: <b>[scripture_states[i] ? "UNLOCKED":"LOCKED"]</b><br>"
..()
//GUARDIANS
/obj/screen/alert/cancharge
@@ -297,6 +459,23 @@ so as to remain in compliance with the most up-to-date laws."
icon_state = "newlaw"
timeout = 300
/obj/screen/alert/hackingapc
name = "Hacking APC"
desc = "An Area Power Controller is being hacked. When the process is \
complete, you will have exclusive control of it, and you will gain \
additional processing time to unlock more malfunction abilities."
icon_state = "hackingapc"
timeout = 600
var/atom/target = null
/obj/screen/alert/hackingapc/Click()
if(!usr || !usr.client) return
if(!target) return
var/mob/living/silicon/ai/AI = usr
var/turf/T = get_turf(target)
if(T)
AI.eyeobj.setLoc(T)
//MECHS
/obj/screen/alert/low_mech_integrity
@@ -359,6 +538,7 @@ so as to remain in compliance with the most up-to-date laws."
if(isliving(usr))
var/mob/living/L = usr
return L.resist()
// PRIVATE = only edit, use, or override these if you're editing the system as a whole
// Re-render all alerts - also called in /datum/hud/show_hud() because it's needed there
@@ -406,8 +586,8 @@ so as to remain in compliance with the most up-to-date laws."
return usr.client.Click(master, location, control, params)
/obj/screen/alert/Destroy()
..()
. = ..()
severity = 0
master = null
screen_loc = ""
return QDEL_HINT_PUTINPOOL //Don't destroy me, I have a family!

View File

@@ -21,50 +21,46 @@
if(T)
T.fire(A)
/obj/screen/alien/plasma_display
icon = 'icons/mob/screen_gen.dmi'
icon_state = "power_display2"
name = "plasma stored"
screen_loc = ui_alienplasmadisplay
/datum/hud/alien/New(mob/living/carbon/alien/humanoid/owner)
/obj/screen/alien/alien_queen_finder
icon = 'icons/mob/screen_alien.dmi'
icon_state = "queen_finder"
name = "queen sense"
desc = "Allows you to sense the general direction of your Queen."
screen_loc = ui_alien_queen_finder
/datum/hud/alien
ui_style_icon = 'icons/mob/screen_alien.dmi'
/datum/hud/alien/New(mob/living/carbon/alien/humanoid/owner, ui_style = 'icons/mob/screen_alien.dmi')
..()
var/obj/screen/using
var/obj/screen/inventory/inv_box
//equippable shit
//hands
inv_box = new /obj/screen/inventory/hand()
inv_box.name = "right hand"
inv_box.icon = 'icons/mob/screen_alien.dmi'
inv_box.icon_state = "hand_r"
inv_box.screen_loc = ui_rhand
inv_box.slot_id = slot_r_hand
static_inventory += inv_box
inv_box = new /obj/screen/inventory/hand()
inv_box.name = "left hand"
inv_box.icon = 'icons/mob/screen_alien.dmi'
inv_box.icon_state = "hand_l"
inv_box.screen_loc = ui_lhand
inv_box.slot_id = slot_l_hand
static_inventory += inv_box
build_hand_slots(ui_style)
//begin buttons
using = new /obj/screen/swap_hand()
using.icon = 'icons/mob/screen_alien.dmi'
using.icon = ui_style
using.icon_state = "swap_1"
using.screen_loc = ui_swaphand1
using.screen_loc = ui_swaphand_position(owner,1)
static_inventory += using
using = new /obj/screen/swap_hand()
using.icon = 'icons/mob/screen_alien.dmi'
using.icon = ui_style
using.icon_state = "swap_2"
using.screen_loc = ui_swaphand2
using.screen_loc = ui_swaphand_position(owner,2)
static_inventory += using
using = new /obj/screen/act_intent/alien()
@@ -78,23 +74,28 @@
H.leap_icon.screen_loc = ui_alien_storage_r
static_inventory += H.leap_icon
using = new/obj/screen/wheel/talk
using.screen_loc = ui_alien_talk_wheel
wheels += using
static_inventory += using
using = new /obj/screen/drop()
using.icon = 'icons/mob/screen_alien.dmi'
using.icon = ui_style
using.screen_loc = ui_drop_throw
static_inventory += using
using = new /obj/screen/resist()
using.icon = 'icons/mob/screen_alien.dmi'
using.icon = ui_style
using.screen_loc = ui_pull_resist
hotkeybuttons += using
throw_icon = new /obj/screen/throw_catch()
throw_icon.icon = 'icons/mob/screen_alien.dmi'
throw_icon.icon = ui_style
throw_icon.screen_loc = ui_drop_throw
hotkeybuttons += throw_icon
pull_icon = new /obj/screen/pull()
pull_icon.icon = 'icons/mob/screen_alien.dmi'
pull_icon.icon = ui_style
pull_icon.update_icon(mymob)
pull_icon.screen_loc = ui_pull_resist
static_inventory += pull_icon
@@ -110,6 +111,10 @@
alien_plasma_display = new /obj/screen/alien/plasma_display()
infodisplay += alien_plasma_display
if(!istype(mymob, /mob/living/carbon/alien/humanoid/royal/queen))
alien_queen_finder = new /obj/screen/alien/alien_queen_finder
infodisplay += alien_queen_finder
zone_select = new /obj/screen/zone_sel/alien()
zone_select.update_icon(mymob)
static_inventory += zone_select
@@ -120,22 +125,18 @@
inv_slots[inv.slot_id] = inv
inv.update_icon()
/datum/hud/alien/persistant_inventory_update()
/datum/hud/alien/persistent_inventory_update()
if(!mymob)
return
var/mob/living/carbon/alien/humanoid/H = mymob
if(hud_version != HUD_STYLE_NOHUD)
if(H.r_hand)
H.r_hand.screen_loc = ui_rhand
H.client.screen += H.r_hand
if(H.l_hand)
H.l_hand.screen_loc = ui_lhand
H.client.screen += H.l_hand
for(var/obj/item/I in H.held_items)
I.screen_loc = ui_hand_position(H.get_held_index_of_item(I))
H.client.screen += I
else
if(H.r_hand)
H.r_hand.screen_loc = null
if(H.l_hand)
H.l_hand.screen_loc = null
for(var/obj/item/I in H.held_items)
I.screen_loc = null
H.client.screen -= I
/mob/living/carbon/alien/humanoid/create_mob_hud()
if(client && !hud_used)

View File

@@ -13,13 +13,19 @@
nightvisionicon = new /obj/screen/alien/nightvision()
nightvisionicon.screen_loc = ui_alien_nightvision
infodisplay += nightvisionicon
alien_queen_finder = new /obj/screen/alien/alien_queen_finder()
infodisplay += alien_queen_finder
pull_icon = new /obj/screen/pull()
pull_icon.icon = 'icons/mob/screen_alien.dmi'
pull_icon.update_icon(mymob)
pull_icon.screen_loc = ui_pull_resist
hotkeybuttons += pull_icon
using = new/obj/screen/wheel/talk
using.screen_loc = ui_alien_talk_wheel
wheels += using
static_inventory += using
zone_select = new /obj/screen/zone_sel/alien()
zone_select.update_icon(mymob)
static_inventory += zone_select

View File

@@ -34,12 +34,15 @@
desc = "Moves your camera to your blob core."
/obj/screen/blob/JumpToCore/MouseEntered(location,control,params)
if(isovermind(usr))
var/mob/camera/blob/B = usr
if(hud && hud.mymob && isovermind(hud.mymob))
var/mob/camera/blob/B = hud.mymob
if(!B.placed)
openToolTip(usr,src,params,title = "Place Blob Core",content = "Attempt to place your blob core at this location.", theme = "blob")
name = "Place Blob Core"
desc = "Attempt to place your blob core at this location."
else
..()
name = initial(name)
desc = initial(desc)
..()
/obj/screen/blob/JumpToCore/Click()
if(isovermind(usr))
@@ -51,7 +54,7 @@
/obj/screen/blob/Blobbernaut
icon_state = "ui_blobbernaut"
name = "Produce Blobbernaut (40)"
desc = "Produces a strong, smart blobbernaut from a factory blob for 40 points.<br>The factory blob used will become fragile and unable to produce spores."
desc = "Produces a strong, smart blobbernaut from a factory blob for 40 resources.<br>The factory blob used will become fragile and unable to produce spores."
/obj/screen/blob/Blobbernaut/Click()
if(isovermind(usr))
@@ -61,7 +64,7 @@
/obj/screen/blob/ResourceBlob
icon_state = "ui_resource"
name = "Produce Resource Blob (40)"
desc = "Produces a resource blob for 40 points.<br>Resource blobs will give you points every few seconds."
desc = "Produces a resource blob for 40 resources.<br>Resource blobs will give you resources every few seconds."
/obj/screen/blob/ResourceBlob/Click()
if(isovermind(usr))
@@ -70,8 +73,8 @@
/obj/screen/blob/NodeBlob
icon_state = "ui_node"
name = "Produce Node Blob (60)"
desc = "Produces a node blob for 60 points.<br>Node blobs will expand and activate nearby resource and factory blobs."
name = "Produce Node Blob (50)"
desc = "Produces a node blob for 50 resources.<br>Node blobs will expand and activate nearby resource and factory blobs."
/obj/screen/blob/NodeBlob/Click()
if(isovermind(usr))
@@ -81,7 +84,7 @@
/obj/screen/blob/FactoryBlob
icon_state = "ui_factory"
name = "Produce Factory Blob (60)"
desc = "Produces a factory blob for 60 points.<br>Factory blobs will produce spores every few seconds."
desc = "Produces a factory blob for 60 resources.<br>Factory blobs will produce spores every few seconds."
/obj/screen/blob/FactoryBlob/Click()
if(isovermind(usr))
@@ -91,15 +94,18 @@
/obj/screen/blob/ReadaptChemical
icon_state = "ui_chemswap"
name = "Readapt Chemical (40)"
desc = "Randomly rerolls your chemical for 40 points."
desc = "Randomly rerolls your chemical for 40 resources."
/obj/screen/blob/ReadaptChemical/MouseEntered(location,control,params)
if(isovermind(usr))
var/mob/camera/blob/B = usr
if(hud && hud.mymob && isovermind(hud.mymob))
var/mob/camera/blob/B = hud.mymob
if(B.free_chem_rerolls)
openToolTip(usr,src,params,title = "Readapt Chemical (FREE)",content = "Randomly rerolls your chemical for free.", theme = "blob")
name = "Readapt Chemical (FREE)"
desc = "Randomly rerolls your chemical for free."
else
..()
name = initial(name)
desc = initial(desc)
..()
/obj/screen/blob/ReadaptChemical/Click()
if(isovermind(usr))
@@ -109,7 +115,7 @@
/obj/screen/blob/RelocateCore
icon_state = "ui_swap"
name = "Relocate Core (80)"
desc = "Swaps a node and your core for 80 points."
desc = "Swaps a node and your core for 80 resources."
/obj/screen/blob/RelocateCore/Click()
if(isovermind(usr))
@@ -126,6 +132,7 @@
blobpwrdisplay.screen_loc = ui_health
blobpwrdisplay.mouse_opacity = 0
blobpwrdisplay.layer = ABOVE_HUD_LAYER
blobpwrdisplay.plane = ABOVE_HUD_PLANE
infodisplay += blobpwrdisplay
healths = new /obj/screen/healths/blob()
@@ -141,6 +148,7 @@
using = new /obj/screen/blob/JumpToCore()
using.screen_loc = ui_zonesel
using.hud = src
static_inventory += using
using = new /obj/screen/blob/Blobbernaut()
@@ -152,15 +160,16 @@
static_inventory += using
using = new /obj/screen/blob/NodeBlob()
using.screen_loc = ui_lhand
using.screen_loc = ui_hand_position(2)
static_inventory += using
using = new /obj/screen/blob/FactoryBlob()
using.screen_loc = ui_rhand
using.screen_loc = ui_hand_position(1)
static_inventory += using
using = new /obj/screen/blob/ReadaptChemical()
using.screen_loc = ui_storage1
using.hud = src
static_inventory += using
using = new /obj/screen/blob/RelocateCore()

View File

@@ -0,0 +1,45 @@
/datum/hud/marauder
var/obj/screen/hosthealth
var/obj/screen/blockchance
var/obj/screen/counterchance
/datum/hud/marauder/New(mob/living/simple_animal/hostile/guardian/owner)
..()
var/obj/screen/using
healths = new /obj/screen/healths/clock()
infodisplay += healths
hosthealth = new /obj/screen/healths/clock()
hosthealth.screen_loc = ui_internal
infodisplay += hosthealth
using = new /obj/screen/marauder/emerge()
using.screen_loc = ui_zonesel
static_inventory += using
/datum/hud/marauder/Destroy()
blockchance = null
counterchance = null
hosthealth = null
return ..()
/mob/living/simple_animal/hostile/clockwork/marauder/create_mob_hud()
if(client && !hud_used)
hud_used = new /datum/hud/marauder(src, ui_style2icon(client.prefs.UI_style))
/obj/screen/marauder
icon = 'icons/mob/clockwork_mobs.dmi'
/obj/screen/marauder/emerge
icon_state = "marauder_emerge"
name = "Emerge/Return"
desc = "Emerge or Return."
/obj/screen/marauder/emerge/Click()
if(istype(usr, /mob/living/simple_animal/hostile/clockwork/marauder))
var/mob/living/simple_animal/hostile/clockwork/marauder/M = usr
if(M.is_in_host())
M.try_emerge()
else
M.return_to_host()

View File

@@ -5,7 +5,6 @@
/datum/hud/devil/New(mob/owner, ui_style = 'icons/mob/screen_midnight.dmi')
..()
var/obj/screen/using
var/obj/screen/inventory/inv_box
using = new /obj/screen/drop()
using.icon = ui_style
@@ -18,36 +17,24 @@
pull_icon.screen_loc = ui_drone_pull
static_inventory += pull_icon
inv_box = new /obj/screen/inventory/hand()
inv_box.name = "right hand"
inv_box.icon = ui_style
inv_box.icon_state = "hand_r"
inv_box.screen_loc = ui_rhand
inv_box.slot_id = slot_r_hand
static_inventory += inv_box
inv_box = new /obj/screen/inventory/hand()
inv_box.name = "left hand"
inv_box.icon = ui_style
inv_box.icon_state = "hand_l"
inv_box.screen_loc = ui_lhand
inv_box.slot_id = slot_l_hand
static_inventory += inv_box
build_hand_slots(ui_style)
using = new /obj/screen/inventory()
using.name = "hand"
using.icon = ui_style
using.icon_state = "swap_1_m"
using.screen_loc = ui_swaphand1
using.screen_loc = ui_swaphand_position(owner,1)
using.layer = HUD_LAYER
using.plane = HUD_PLANE
static_inventory += using
using = new /obj/screen/inventory()
using.name = "hand"
using.icon = ui_style
using.icon_state = "swap_2"
using.screen_loc = ui_swaphand2
using.screen_loc = ui_swaphand_position(owner,2)
using.layer = HUD_LAYER
using.plane = HUD_PLANE
static_inventory += using
zone_select = new /obj/screen/zone_sel()
@@ -59,23 +46,19 @@
infodisplay += devilsouldisplay
/datum/hud/devil/persistant_inventory_update()
/datum/hud/devil/persistent_inventory_update()
if(!mymob)
return
var/mob/living/carbon/true_devil/D = mymob
if(hud_version != HUD_STYLE_NOHUD)
if(D.r_hand)
D.r_hand.screen_loc = ui_rhand
D.client.screen += D.r_hand
if(D.l_hand)
D.l_hand.screen_loc = ui_lhand
D.client.screen += D.l_hand
for(var/obj/item/I in D.held_items)
I.screen_loc = ui_hand_position(D.get_held_index_of_item(I))
D.client.screen += I
else
if(D.r_hand)
D.r_hand.screen_loc = null
if(D.l_hand)
D.l_hand.screen_loc = null
for(var/obj/item/I in D.held_items)
I.screen_loc = null
D.client.screen -= I
/mob/living/carbon/true_devil/create_mob_hud()
if(client && !hud_used)

View File

@@ -1,42 +1,14 @@
/datum/hud/drone/New(mob/owner, ui_style = 'icons/mob/screen_midnight.dmi')
/datum/hud/dextrous/drone/New(mob/owner, ui_style = 'icons/mob/screen_midnight.dmi')
..()
var/obj/screen/using
var/obj/screen/inventory/inv_box
using = new /obj/screen/drop()
using.icon = ui_style
using.screen_loc = ui_drone_drop
static_inventory += using
pull_icon = new /obj/screen/pull()
pull_icon.icon = ui_style
pull_icon.update_icon(mymob)
pull_icon.screen_loc = ui_drone_pull
static_inventory += pull_icon
inv_box = new /obj/screen/inventory/hand()
inv_box.name = "right hand"
inv_box.icon = ui_style
inv_box.icon_state = "hand_r"
inv_box.screen_loc = ui_rhand
inv_box.slot_id = slot_r_hand
static_inventory += inv_box
inv_box = new /obj/screen/inventory/hand()
inv_box.name = "left hand"
inv_box.icon = ui_style
inv_box.icon_state = "hand_l"
inv_box.screen_loc = ui_lhand
inv_box.slot_id = slot_l_hand
static_inventory += inv_box
inv_box = new /obj/screen/inventory()
inv_box.name = "internal storage"
inv_box.icon = ui_style
inv_box.icon_state = "suit_storage"
// inv_box.icon_full = "template"
inv_box.screen_loc = ui_drone_storage
inv_box.slot_id = slot_drone_storage
inv_box.slot_id = slot_generic_dextrous_storage
static_inventory += inv_box
inv_box = new /obj/screen/inventory()
@@ -48,26 +20,6 @@
inv_box.slot_id = slot_head
static_inventory += inv_box
using = new /obj/screen/swap_hand()
using.icon = ui_style
using.icon_state = "swap_1_m"
using.screen_loc = ui_swaphand1
static_inventory += using
using = new /obj/screen/swap_hand()
using.icon = ui_style
using.icon_state = "swap_2"
using.screen_loc = ui_swaphand2
static_inventory += using
zone_select = new /obj/screen/zone_sel()
zone_select.icon = ui_style
zone_select.update_icon(mymob)
using = new /obj/screen/inventory/craft
using.icon = ui_style
static_inventory += using
for(var/obj/screen/inventory/inv in (static_inventory + toggleable_inventory))
if(inv.slot_id)
inv.hud = src
@@ -75,7 +27,7 @@
inv.update_icon()
/datum/hud/drone/persistant_inventory_update()
/datum/hud/dextrous/drone/persistent_inventory_update()
if(!mymob)
return
var/mob/living/simple_animal/drone/D = mymob
@@ -93,19 +45,4 @@
if(D.head)
D.head.screen_loc = null
if(hud_version != HUD_STYLE_NOHUD)
if(D.r_hand)
D.r_hand.screen_loc = ui_rhand
D.client.screen += D.r_hand
if(D.l_hand)
D.l_hand.screen_loc = ui_lhand
D.client.screen += D.l_hand
else
if(D.r_hand)
D.r_hand.screen_loc = null
if(D.l_hand)
D.l_hand.screen_loc = null
/mob/living/simple_animal/drone/create_mob_hud()
if(client && !hud_used)
hud_used = new /datum/hud/drone(src, ui_style2icon(client.prefs.UI_style))
..()

View File

@@ -12,7 +12,7 @@
else if(!severity || severity == screen.severity)
return null
else
screen = PoolOrNew(type)
screen = new type()
screen.icon_state = "[initial(screen.icon_state)][severity]"
screen.severity = severity
@@ -30,17 +30,18 @@
screens -= category
if(animated)
spawn(0)
animate(screen, alpha = 0, time = animated)
sleep(animated)
if(client)
client.screen -= screen
qdel(screen)
animate(screen, alpha = 0, time = animated)
addtimer(CALLBACK(src, .proc/clear_fullscreen_after_animate, screen), animated, TIMER_CLIENT_TIME)
else
if(client)
client.screen -= screen
qdel(screen)
/mob/proc/clear_fullscreen_after_animate(obj/screen/fullscreen/screen)
if(client)
client.screen -= screen
qdel(screen)
/mob/proc/clear_fullscreens()
for(var/category in screens)
clear_fullscreen(category)
@@ -60,29 +61,33 @@
icon_state = "default"
screen_loc = "CENTER-7,CENTER-7"
layer = FULLSCREEN_LAYER
plane = FULLSCREEN_PLANE
mouse_opacity = 0
var/severity = 0
/obj/screen/fullscreen/Destroy()
..()
severity = 0
return QDEL_HINT_PUTINPOOL
. = ..()
/obj/screen/fullscreen/brute
icon_state = "brutedamageoverlay"
layer = UI_DAMAGE_LAYER
plane = FULLSCREEN_PLANE
/obj/screen/fullscreen/oxy
icon_state = "oxydamageoverlay"
layer = UI_DAMAGE_LAYER
plane = FULLSCREEN_PLANE
/obj/screen/fullscreen/crit
icon_state = "passage"
layer = CRIT_LAYER
plane = FULLSCREEN_PLANE
/obj/screen/fullscreen/blind
icon_state = "blackimageoverlay"
layer = BLIND_LAYER
plane = FULLSCREEN_PLANE
/obj/screen/fullscreen/impaired
icon_state = "impairedoverlay"
@@ -97,7 +102,7 @@
screen_loc = "WEST,SOUTH to EAST,NORTH"
icon_state = "flash"
/obj/screen/fullscreen/flash/noise
/obj/screen/fullscreen/flash/static
icon = 'icons/mob/screen_gen.dmi'
screen_loc = "WEST,SOUTH to EAST,NORTH"
icon_state = "noise"
@@ -106,3 +111,18 @@
icon = 'icons/mob/screen_gen.dmi'
screen_loc = "WEST,SOUTH to EAST,NORTH"
icon_state = "druggy"
/obj/screen/fullscreen/color_vision
icon = 'icons/mob/screen_gen.dmi'
screen_loc = "WEST,SOUTH to EAST,NORTH"
icon_state = "flash"
alpha = 80
/obj/screen/fullscreen/color_vision/green
color = "#00ff00"
/obj/screen/fullscreen/color_vision/red
color = "#ff0000"
/obj/screen/fullscreen/color_vision/blue
color = "#0000ff"

View File

@@ -2,39 +2,54 @@
/datum/hud/dextrous/New(mob/living/owner, ui_style = 'icons/mob/screen_midnight.dmi')
..()
var/obj/screen/using
var/obj/screen/inventory/inv_box
using = new /obj/screen/drop()
using.icon = ui_style
using.screen_loc = ui_drone_drop
static_inventory += using
inv_box = new /obj/screen/inventory/hand()
inv_box.name = "right hand"
inv_box.icon = ui_style
inv_box.icon_state = "hand_r"
inv_box.screen_loc = ui_rhand
inv_box.slot_id = slot_r_hand
static_inventory += inv_box
pull_icon = new /obj/screen/pull()
pull_icon.icon = ui_style
pull_icon.update_icon(mymob)
pull_icon.screen_loc = ui_drone_pull
static_inventory += pull_icon
inv_box = new /obj/screen/inventory/hand()
inv_box.name = "left hand"
inv_box.icon = ui_style
inv_box.icon_state = "hand_l"
inv_box.screen_loc = ui_lhand
inv_box.slot_id = slot_l_hand
static_inventory += inv_box
build_hand_slots(ui_style)
using = new /obj/screen/swap_hand()
using.icon = ui_style
using.icon_state = "swap_1_m"
using.screen_loc = ui_swaphand1
using.screen_loc = ui_swaphand_position(owner,1)
static_inventory += using
using = new /obj/screen/swap_hand()
using.icon = ui_style
using.icon_state = "swap_2"
using.screen_loc = ui_swaphand2
using.screen_loc = ui_swaphand_position(owner,2)
static_inventory += using
if(mymob.possible_a_intents)
if(mymob.possible_a_intents.len == 4)
// All possible intents - full intent selector
action_intent = new /obj/screen/act_intent/segmented
else
action_intent = new /obj/screen/act_intent
action_intent.icon = ui_style
action_intent.icon_state = mymob.a_intent
static_inventory += action_intent
zone_select = new /obj/screen/zone_sel()
zone_select.icon = ui_style
zone_select.update_icon(mymob)
static_inventory += zone_select
using = new /obj/screen/craft
using.icon = ui_style
static_inventory += using
using = new /obj/screen/area_creator
using.icon = ui_style
static_inventory += using
mymob.client.screen = list()
@@ -45,19 +60,24 @@
inv_slots[inv.slot_id] = inv
inv.update_icon()
/datum/hud/dextrous/persistant_inventory_update()
/datum/hud/dextrous/persistent_inventory_update()
if(!mymob)
return
var/mob/living/D = mymob
if(hud_version != HUD_STYLE_NOHUD)
if(D.r_hand)
D.r_hand.screen_loc = ui_rhand
D.client.screen += D.r_hand
if(D.l_hand)
D.l_hand.screen_loc = ui_lhand
D.client.screen += D.l_hand
for(var/obj/item/I in D.held_items)
I.screen_loc = ui_hand_position(D.get_held_index_of_item(I))
D.client.screen += I
else
if(D.r_hand)
D.r_hand.screen_loc = null
if(D.l_hand)
D.l_hand.screen_loc = null
for(var/obj/item/I in D.held_items)
I.screen_loc = null
D.client.screen -= I
//Dextrous simple mobs can use hands!
/mob/living/simple_animal/create_mob_hud()
if(client && !hud_used)
if(dextrous)
hud_used = new dextrous_hud_type(src, ui_style2icon(client.prefs.UI_style))
else
..()

View File

@@ -36,7 +36,15 @@
var/mob/dead/observer/G = usr
G.dead_tele()
/datum/hud/ghost/New(mob/owner)
/obj/screen/ghost/pai
name = "pAI Candidate"
icon_state = "pai"
/obj/screen/ghost/pai/Click()
var/mob/dead/observer/G = usr
G.register_pai()
/datum/hud/ghost/New(mob/owner, ui_style = 'icons/mob/screen_midnight.dmi')
..()
var/mob/dead/observer/G = mymob
if(!G.client.prefs.ghost_hud)
@@ -61,15 +69,19 @@
using.screen_loc = ui_ghost_teleport
static_inventory += using
using = new /obj/screen/ghost/pai()
using.screen_loc = ui_ghost_pai
static_inventory += using
/datum/hud/ghost/show_hud()
var/mob/dead/observer/G = mymob
mymob.client.screen = list()
if(!G.client.prefs.ghost_hud)
return
mymob.client.screen += static_inventory
update_parallax_existence()
create_parallax()
if(G.client.prefs.ghost_hud)
mymob.client.screen += static_inventory
/mob/dead/observer/create_mob_hud()
if(client && !hud_used)
hud_used = new /datum/hud/ghost(src)
hud_used = new /datum/hud/ghost(src, ui_style2icon(client.prefs.UI_style))

View File

@@ -7,11 +7,11 @@
infodisplay += healths
using = new /obj/screen/guardian/Manifest()
using.screen_loc = ui_rhand
using.screen_loc = ui_hand_position(2)
static_inventory += using
using = new /obj/screen/guardian/Recall()
using.screen_loc = ui_lhand
using.screen_loc = ui_hand_position(1)
static_inventory += using
using = new owner.toggle_button_type()
@@ -29,8 +29,69 @@
/mob/living/simple_animal/hostile/guardian/create_mob_hud()
if(client && !hud_used)
hud_used = new /datum/hud/guardian(src)
if(dextrous)
..()
else
hud_used = new /datum/hud/guardian(src, ui_style2icon(client.prefs.UI_style))
/datum/hud/dextrous/guardian/New(mob/living/simple_animal/hostile/guardian/owner, ui_style = 'icons/mob/screen_midnight.dmi') //for a dextrous guardian
..()
var/obj/screen/using
if(istype(owner, /mob/living/simple_animal/hostile/guardian/dextrous))
var/obj/screen/inventory/inv_box
inv_box = new /obj/screen/inventory()
inv_box.name = "internal storage"
inv_box.icon = ui_style
inv_box.icon_state = "suit_storage"
inv_box.screen_loc = ui_id
inv_box.slot_id = slot_generic_dextrous_storage
static_inventory += inv_box
using = new /obj/screen/guardian/Communicate()
using.screen_loc = ui_sstore1
static_inventory += using
else
using = new /obj/screen/guardian/Communicate()
using.screen_loc = ui_id
static_inventory += using
healths = new /obj/screen/healths/guardian()
infodisplay += healths
using = new /obj/screen/guardian/Manifest()
using.screen_loc = ui_belt
static_inventory += using
using = new /obj/screen/guardian/Recall()
using.screen_loc = ui_back
static_inventory += using
using = new owner.toggle_button_type()
using.screen_loc = ui_storage2
static_inventory += using
using = new /obj/screen/guardian/ToggleLight()
using.screen_loc = ui_inventory
static_inventory += using
/datum/hud/dextrous/guardian/persistent_inventory_update()
if(!mymob)
return
if(istype(mymob, /mob/living/simple_animal/hostile/guardian/dextrous))
var/mob/living/simple_animal/hostile/guardian/dextrous/D = mymob
if(hud_shown)
if(D.internal_storage)
D.internal_storage.screen_loc = ui_id
D.client.screen += D.internal_storage
else
if(D.internal_storage)
D.internal_storage.screen_loc = null
..()
/obj/screen/guardian
icon = 'icons/mob/guardian.dmi'

View File

@@ -9,7 +9,7 @@
var/hud_shown = 1 //Used for the HUD toggle (F12)
var/hud_version = 1 //Current displayed version of the HUD
var/inventory_shown = 1 //the inventory
var/inventory_shown = 0 //Equipped item inventory
var/show_intent_icons = 0
var/hotkey_ui_hidden = 0 //This is to hide the buttons that can be used via hotkeys. (hotkeybuttons list of buttons)
@@ -19,6 +19,7 @@
var/obj/screen/blobpwrdisplay
var/obj/screen/alien_plasma_display
var/obj/screen/alien_queen_finder
var/obj/screen/devil/soul_counter/devilsouldisplay
@@ -32,12 +33,16 @@
var/obj/screen/throw_icon
var/obj/screen/module_store_icon
var/list/wheels = list() //list of the wheel screen objects
var/list/static_inventory = list() //the screen objects which are static
var/list/toggleable_inventory = list() //the screen objects which can be hidden
var/list/obj/screen/hotkeybuttons = list() //the buttons that can be used via hotkeys
var/list/infodisplay = list() //the screen objects that display mob info (health, alien plasma, etc...)
var/list/screenoverlays = list() //the screen objects used as whole screen overlays (flash, damageoverlay, etc...)
var/list/inv_slots[slots_amt] // /obj/screen/inventory objects, ordered by their slot ID.
var/list/hand_slots // /obj/screen/inventory/hand objects, assoc list of "[held_index]" = object
var/list/obj/screen/plane_master/plane_masters = list() // see "appearance_flags" in the ref, assoc list of "[plane]" = object
var/obj/screen/movable/action_button/hide_toggle/hide_actions_toggle
var/action_buttons_hidden = 0
@@ -46,10 +51,21 @@
var/obj/screen/healthdoll
var/obj/screen/internals
/datum/hud/New(mob/owner)
var/ui_style_icon = 'icons/mob/screen_midnight.dmi'
/datum/hud/New(mob/owner , ui_style = 'icons/mob/screen_midnight.dmi')
mymob = owner
ui_style_icon = ui_style
hide_actions_toggle = new
hide_actions_toggle.InitialiseIcon(mymob)
hide_actions_toggle.InitialiseIcon(src)
hand_slots = list()
for(var/mytype in subtypesof(/obj/screen/plane_master))
var/obj/screen/plane_master/instance = new mytype()
plane_masters["[instance.plane]"] = instance
/datum/hud/Destroy()
if(mymob.hud_used == src)
@@ -61,6 +77,8 @@
qdel(module_store_icon)
module_store_icon = null
wheels = null //all wheels are also in static_inventory
if(static_inventory.len)
for(var/thing in static_inventory)
qdel(thing)
@@ -96,10 +114,16 @@
lingstingdisplay = null
blobpwrdisplay = null
alien_plasma_display = null
alien_queen_finder = null
deity_power_display = null
deity_follower_display = null
nightvisionicon = null
if(plane_masters.len)
for(var/thing in plane_masters)
qdel(plane_masters[thing])
plane_masters.Cut()
if(screenoverlays.len)
for(var/thing in screenoverlays)
qdel(thing)
@@ -112,13 +136,15 @@
hud_used = new /datum/hud(src)
//Version denotes which style should be displayed. blank or 0 means "next version"
/datum/hud/proc/show_hud(version = 0)
/datum/hud/proc/show_hud(version = 0,mob/viewmob)
if(!ismob(mymob))
return 0
if(!mymob.client)
return 0
mymob.client.screen = list()
var/mob/screenmob = viewmob || mymob
screenmob.client.screen = list()
var/display_hud_version = version
if(!display_hud_version) //If 0 or blank, display the next hud version
@@ -130,13 +156,13 @@
if(HUD_STYLE_STANDARD) //Default HUD
hud_shown = 1 //Governs behavior of other procs
if(static_inventory.len)
mymob.client.screen += static_inventory
if(toggleable_inventory.len && inventory_shown)
mymob.client.screen += toggleable_inventory
screenmob.client.screen += static_inventory
if(toggleable_inventory.len && screenmob.hud_used && screenmob.hud_used.inventory_shown)
screenmob.client.screen += toggleable_inventory
if(hotkeybuttons.len && !hotkey_ui_hidden)
mymob.client.screen += hotkeybuttons
screenmob.client.screen += hotkeybuttons
if(infodisplay.len)
mymob.client.screen += infodisplay
screenmob.client.screen += infodisplay
mymob.client.screen += hide_actions_toggle
@@ -146,45 +172,48 @@
if(HUD_STYLE_REDUCED) //Reduced HUD
hud_shown = 0 //Governs behavior of other procs
if(static_inventory.len)
mymob.client.screen -= static_inventory
screenmob.client.screen -= static_inventory
if(toggleable_inventory.len)
mymob.client.screen -= toggleable_inventory
screenmob.client.screen -= toggleable_inventory
if(hotkeybuttons.len)
mymob.client.screen -= hotkeybuttons
screenmob.client.screen -= hotkeybuttons
if(infodisplay.len)
mymob.client.screen += infodisplay
screenmob.client.screen += infodisplay
//These ones are a part of 'static_inventory', 'toggleable_inventory' or 'hotkeybuttons' but we want them to stay
if(inv_slots[slot_l_hand])
mymob.client.screen += inv_slots[slot_l_hand] //we want the hands to be visible
if(inv_slots[slot_r_hand])
mymob.client.screen += inv_slots[slot_r_hand] //we want the hands to be visible
for(var/h in hand_slots)
var/obj/screen/hand = hand_slots[h]
if(hand)
screenmob.client.screen += hand
if(action_intent)
mymob.client.screen += action_intent //we want the intent switcher visible
screenmob.client.screen += action_intent //we want the intent switcher visible
action_intent.screen_loc = ui_acti_alt //move this to the alternative position, where zone_select usually is.
if(HUD_STYLE_NOHUD) //No HUD
hud_shown = 0 //Governs behavior of other procs
if(static_inventory.len)
mymob.client.screen -= static_inventory
screenmob.client.screen -= static_inventory
if(toggleable_inventory.len)
mymob.client.screen -= toggleable_inventory
screenmob.client.screen -= toggleable_inventory
if(hotkeybuttons.len)
mymob.client.screen -= hotkeybuttons
screenmob.client.screen -= hotkeybuttons
if(infodisplay.len)
mymob.client.screen -= infodisplay
screenmob.client.screen -= infodisplay
if(plane_masters.len)
for(var/thing in plane_masters)
screenmob.client.screen += plane_masters[thing]
hud_version = display_hud_version
persistant_inventory_update()
persistent_inventory_update(screenmob)
mymob.update_action_buttons(1)
reorganize_alerts()
mymob.reload_fullscreen()
update_parallax_existence()
create_parallax()
/datum/hud/human/show_hud(version = 0)
/datum/hud/human/show_hud(version = 0,mob/viewmob)
..()
hidden_inventory_update()
hidden_inventory_update(viewmob)
/datum/hud/robot/show_hud(version = 0)
..()
@@ -193,8 +222,19 @@
/datum/hud/proc/hidden_inventory_update()
return
/datum/hud/proc/persistant_inventory_update()
return
/datum/hud/proc/persistent_inventory_update(mob/viewer)
if(!mymob)
return
var/mob/living/L = mymob
var/mob/screenmob = viewer || L
for(var/X in wheels)
var/obj/screen/wheel/W = X
if(W.toggled)
screenmob.client.screen |= W.buttons_list
else
screenmob.client.screen -= W.buttons_list
//Triggered when F12 is pressed (Unless someone changed something in the DMF)
/mob/verb/button_pressed_F12()
@@ -206,3 +246,35 @@
usr << "<span class ='info'>Switched HUD mode. Press F12 to toggle.</span>"
else
usr << "<span class ='warning'>This mob type does not use a HUD.</span>"
//(re)builds the hand ui slots, throwing away old ones
//not really worth jugglying existing ones so we just scrap+rebuild
//9/10 this is only called once per mob and only for 2 hands
/datum/hud/proc/build_hand_slots(ui_style = 'icons/mob/screen_midnight.dmi')
for(var/h in hand_slots)
var/obj/screen/inventory/hand/H = hand_slots[h]
if(H)
static_inventory -= H
hand_slots = list()
var/obj/screen/inventory/hand/hand_box
for(var/i in 1 to mymob.held_items.len)
hand_box = new /obj/screen/inventory/hand()
hand_box.name = mymob.get_held_index_name(i)
hand_box.icon = ui_style
hand_box.icon_state = "hand_[mymob.held_index_to_dir(i)]"
hand_box.screen_loc = ui_hand_position(i)
hand_box.held_index = i
hand_slots["[i]"] = hand_box
hand_box.hud = src
static_inventory += hand_box
hand_box.update_icon()
var/i = 1
for(var/obj/screen/swap_hand/SH in static_inventory)
SH.screen_loc = ui_swaphand_position(mymob,!(i % 2) ? 2: 1)
i++
for(var/obj/screen/human/equip/E in static_inventory)
E.screen_loc = ui_equip_position(mymob)
if(mymob.hud_used)
show_hud(HUD_STYLE_STANDARD,mymob)

View File

@@ -6,14 +6,22 @@
icon_state = "toggle"
/obj/screen/human/toggle/Click()
if(usr.hud_used.inventory_shown)
var/mob/targetmob = usr
if(isobserver(usr))
if(ishuman(usr.client.eye) && (usr.client.eye != usr))
var/mob/M = usr.client.eye
targetmob = M
if(usr.hud_used.inventory_shown && targetmob.hud_used)
usr.hud_used.inventory_shown = 0
usr.client.screen -= usr.hud_used.toggleable_inventory
usr.client.screen -= targetmob.hud_used.toggleable_inventory
else
usr.hud_used.inventory_shown = 1
usr.client.screen += usr.hud_used.toggleable_inventory
usr.client.screen += targetmob.hud_used.toggleable_inventory
usr.hud_used.hidden_inventory_update()
targetmob.hud_used.hidden_inventory_update(usr)
/obj/screen/human/equip
name = "equip"
@@ -62,6 +70,8 @@
screen_loc = ui_lingstingdisplay
/obj/screen/ling/sting/Click()
if(isobserver(usr))
return
var/mob/living/carbon/U = usr
U.unset_sting()
@@ -77,22 +87,29 @@
/datum/hud/human/New(mob/living/carbon/human/owner, ui_style = 'icons/mob/screen_midnight.dmi')
..()
var/obj/screen/using
var/obj/screen/inventory/inv_box
using = new /obj/screen/inventory/craft
using = new /obj/screen/craft
using.icon = ui_style
static_inventory += using
using = new /obj/screen/act_intent()
using.icon_state = mymob.a_intent
static_inventory += using
action_intent = using
using = new /obj/screen/mov_intent()
using = new/obj/screen/wheel/talk
using.icon = ui_style
using.icon_state = (mymob.m_intent == "run" ? "running" : "walking")
wheels += using
static_inventory += using
using = new /obj/screen/area_creator
using.icon = ui_style
static_inventory += using
action_intent = new /obj/screen/act_intent/segmented
action_intent.icon_state = mymob.a_intent
static_inventory += action_intent
using = new /obj/screen/mov_intent
using.icon = ui_style
using.icon_state = (mymob.m_intent == MOVE_INTENT_RUN ? "running" : "walking")
using.screen_loc = ui_movi
static_inventory += using
@@ -119,32 +136,18 @@
inv_box.screen_loc = ui_oclothing
toggleable_inventory += inv_box
inv_box = new /obj/screen/inventory/hand()
inv_box.name = "right hand"
inv_box.icon = ui_style
inv_box.icon_state = "hand_r"
inv_box.screen_loc = ui_rhand
inv_box.slot_id = slot_r_hand
static_inventory += inv_box
inv_box = new /obj/screen/inventory/hand()
inv_box.name = "left hand"
inv_box.icon = ui_style
inv_box.icon_state = "hand_l"
inv_box.screen_loc = ui_lhand
inv_box.slot_id = slot_l_hand
static_inventory += inv_box
build_hand_slots(ui_style)
using = new /obj/screen/swap_hand()
using.icon = ui_style
using.icon_state = "swap_1"
using.screen_loc = ui_swaphand1
using.screen_loc = ui_swaphand_position(owner,1)
static_inventory += using
using = new /obj/screen/swap_hand()
using.icon = ui_style
using.icon_state = "swap_2"
using.screen_loc = ui_swaphand2
using.screen_loc = ui_swaphand_position(owner,2)
static_inventory += using
inv_box = new /obj/screen/inventory()
@@ -165,6 +168,15 @@
inv_box.slot_id = slot_wear_mask
toggleable_inventory += inv_box
inv_box = new /obj/screen/inventory()
inv_box.name = "neck"
inv_box.icon = ui_style
inv_box.icon_state = "neck"
// inv_box.icon_full = "template"
inv_box.screen_loc = ui_neck
inv_box.slot_id = slot_neck
toggleable_inventory += inv_box
inv_box = new /obj/screen/inventory()
inv_box.name = "back"
inv_box.icon = ui_style
@@ -213,7 +225,7 @@
using = new /obj/screen/human/equip()
using.icon = ui_style
using.screen_loc = ui_equip
using.screen_loc = ui_equip_position(mymob)
static_inventory += using
inv_box = new /obj/screen/inventory()
@@ -304,102 +316,111 @@
zone_select.update_icon(mymob)
static_inventory += zone_select
inventory_shown = 0
for(var/obj/screen/inventory/inv in (static_inventory + toggleable_inventory))
if(inv.slot_id)
inv.hud = src
inv_slots[inv.slot_id] = inv
inv.update_icon()
/datum/hud/human/hidden_inventory_update()
/datum/hud/human/hidden_inventory_update(mob/viewer)
if(!mymob)
return
var/mob/living/carbon/human/H = mymob
if(inventory_shown && hud_shown)
var/mob/screenmob = viewer || H
if(screenmob.hud_used.inventory_shown && screenmob.hud_used.hud_shown)
if(H.shoes)
H.shoes.screen_loc = ui_shoes
H.client.screen += H.shoes
screenmob.client.screen += H.shoes
if(H.gloves)
H.gloves.screen_loc = ui_gloves
H.client.screen += H.gloves
screenmob.client.screen += H.gloves
if(H.ears)
H.ears.screen_loc = ui_ears
H.client.screen += H.ears
screenmob.client.screen += H.ears
if(H.glasses)
H.glasses.screen_loc = ui_glasses
H.client.screen += H.glasses
screenmob.client.screen += H.glasses
if(H.w_uniform)
H.w_uniform.screen_loc = ui_iclothing
H.client.screen += H.w_uniform
screenmob.client.screen += H.w_uniform
if(H.wear_suit)
H.wear_suit.screen_loc = ui_oclothing
H.client.screen += H.wear_suit
screenmob.client.screen += H.wear_suit
if(H.wear_mask)
H.wear_mask.screen_loc = ui_mask
H.client.screen += H.wear_mask
screenmob.client.screen += H.wear_mask
if(H.wear_neck)
H.wear_neck.screen_loc = ui_neck
screenmob.client.screen += H.wear_neck
if(H.head)
H.head.screen_loc = ui_head
H.client.screen += H.head
screenmob.client.screen += H.head
else
if(H.shoes) H.shoes.screen_loc = null
if(H.gloves) H.gloves.screen_loc = null
if(H.ears) H.ears.screen_loc = null
if(H.glasses) H.glasses.screen_loc = null
if(H.w_uniform) H.w_uniform.screen_loc = null
if(H.wear_suit) H.wear_suit.screen_loc = null
if(H.wear_mask) H.wear_mask.screen_loc = null
if(H.head) H.head.screen_loc = null
if(H.shoes) screenmob.client.screen -= H.shoes
if(H.gloves) screenmob.client.screen -= H.gloves
if(H.ears) screenmob.client.screen -= H.ears
if(H.glasses) screenmob.client.screen -= H.glasses
if(H.w_uniform) screenmob.client.screen -= H.w_uniform
if(H.wear_suit) screenmob.client.screen -= H.wear_suit
if(H.wear_mask) screenmob.client.screen -= H.wear_mask
if(H.wear_neck) screenmob.client.screen -= H.wear_neck
if(H.head) screenmob.client.screen -= H.head
/datum/hud/human/persistant_inventory_update()
/datum/hud/human/persistent_inventory_update(mob/viewer)
if(!mymob)
return
..()
var/mob/living/carbon/human/H = mymob
if(hud_shown)
if(H.s_store)
H.s_store.screen_loc = ui_sstore1
H.client.screen += H.s_store
if(H.wear_id)
H.wear_id.screen_loc = ui_id
H.client.screen += H.wear_id
if(H.belt)
H.belt.screen_loc = ui_belt
H.client.screen += H.belt
if(H.back)
H.back.screen_loc = ui_back
H.client.screen += H.back
if(H.l_store)
H.l_store.screen_loc = ui_storage1
H.client.screen += H.l_store
if(H.r_store)
H.r_store.screen_loc = ui_storage2
H.client.screen += H.r_store
else
if(H.s_store)
H.s_store.screen_loc = null
if(H.wear_id)
H.wear_id.screen_loc = null
if(H.belt)
H.belt.screen_loc = null
if(H.back)
H.back.screen_loc = null
if(H.l_store)
H.l_store.screen_loc = null
if(H.r_store)
H.r_store.screen_loc = null
var/mob/screenmob = viewer || H
if(screenmob.hud_used)
if(screenmob.hud_used.hud_shown)
if(H.s_store)
H.s_store.screen_loc = ui_sstore1
screenmob.client.screen += H.s_store
if(H.wear_id)
H.wear_id.screen_loc = ui_id
screenmob.client.screen += H.wear_id
if(H.belt)
H.belt.screen_loc = ui_belt
screenmob.client.screen += H.belt
if(H.back)
H.back.screen_loc = ui_back
screenmob.client.screen += H.back
if(H.l_store)
H.l_store.screen_loc = ui_storage1
screenmob.client.screen += H.l_store
if(H.r_store)
H.r_store.screen_loc = ui_storage2
screenmob.client.screen += H.r_store
else
if(H.s_store)
screenmob.client.screen -= H.s_store
if(H.wear_id)
screenmob.client.screen -= H.wear_id
if(H.belt)
screenmob.client.screen -= H.belt
if(H.back)
screenmob.client.screen -= H.back
if(H.l_store)
screenmob.client.screen -= H.l_store
if(H.r_store)
screenmob.client.screen -= H.r_store
if(hud_version != HUD_STYLE_NOHUD)
if(H.r_hand)
H.r_hand.screen_loc = ui_rhand
H.client.screen += H.r_hand
if(H.l_hand)
H.l_hand.screen_loc = ui_lhand
H.client.screen += H.l_hand
for(var/obj/item/I in H.held_items)
I.screen_loc = ui_hand_position(H.get_held_index_of_item(I))
screenmob.client.screen += I
else
if(H.r_hand)
H.r_hand.screen_loc = null
if(H.l_hand)
H.l_hand.screen_loc = null
for(var/obj/item/I in H.held_items)
I.screen_loc = null
screenmob.client.screen -= I
/mob/living/carbon/human/verb/toggle_hotkey_verbs()
set category = "OOC"

View File

@@ -3,50 +3,40 @@
var/obj/screen/using
var/obj/screen/inventory/inv_box
using = new /obj/screen/act_intent()
using.icon = ui_style
using.icon_state = mymob.a_intent
using.screen_loc = ui_acti
static_inventory += using
action_intent = using
action_intent = new /obj/screen/act_intent()
action_intent.icon = ui_style
action_intent.icon_state = mymob.a_intent
action_intent.screen_loc = ui_acti
static_inventory += action_intent
using = new /obj/screen/mov_intent()
using.icon = ui_style
using.icon_state = (mymob.m_intent == "run" ? "running" : "walking")
using.icon_state = (mymob.m_intent == MOVE_INTENT_RUN ? "running" : "walking")
using.screen_loc = ui_movi
static_inventory += using
using = new/obj/screen/wheel/talk
using.icon = ui_style
wheels += using
static_inventory += using
using = new /obj/screen/drop()
using.icon = ui_style
using.screen_loc = ui_drop_throw
static_inventory += using
inv_box = new /obj/screen/inventory/hand()
inv_box.name = "right hand"
inv_box.icon = ui_style
inv_box.icon_state = "hand_r"
inv_box.screen_loc = ui_rhand
inv_box.slot_id = slot_r_hand
static_inventory += inv_box
inv_box = new /obj/screen/inventory/hand()
inv_box.name = "left hand"
inv_box.icon = ui_style
inv_box.icon_state = "hand_l"
inv_box.screen_loc = ui_lhand
inv_box.slot_id = slot_l_hand
static_inventory += inv_box
build_hand_slots(ui_style)
using = new /obj/screen/swap_hand()
using.icon = ui_style
using.icon_state = "swap_1_m" //extra wide!
using.screen_loc = ui_swaphand1
using.screen_loc = ui_swaphand_position(owner,1)
static_inventory += using
using = new /obj/screen/swap_hand()
using.icon = ui_style
using.icon_state = "swap_2"
using.screen_loc = ui_swaphand2
using.screen_loc = ui_swaphand_position(owner,2)
static_inventory += using
inv_box = new /obj/screen/inventory()
@@ -58,6 +48,15 @@
inv_box.slot_id = slot_wear_mask
static_inventory += inv_box
inv_box = new /obj/screen/inventory()
inv_box.name = "neck"
inv_box.icon = ui_style
inv_box.icon_state = "neck"
// inv_box.icon_full = "template"
inv_box.screen_loc = ui_monkey_neck
inv_box.slot_id = slot_neck
static_inventory += inv_box
inv_box = new /obj/screen/inventory()
inv_box.name = "head"
inv_box.icon = ui_style
@@ -118,7 +117,7 @@
inv_slots[inv.slot_id] = inv
inv.update_icon()
/datum/hud/monkey/persistant_inventory_update()
/datum/hud/monkey/persistent_inventory_update()
if(!mymob)
return
var/mob/living/carbon/monkey/M = mymob
@@ -130,6 +129,9 @@
if(M.wear_mask)
M.wear_mask.screen_loc = ui_monkey_mask
M.client.screen += M.wear_mask
if(M.wear_neck)
M.wear_neck.screen_loc = ui_monkey_neck
M.client.screen += M.wear_neck
if(M.head)
M.head.screen_loc = ui_monkey_head
M.client.screen += M.head
@@ -142,17 +144,13 @@
M.head.screen_loc = null
if(hud_version != HUD_STYLE_NOHUD)
if(M.r_hand)
M.r_hand.screen_loc = ui_rhand
M.client.screen += M.r_hand
if(M.l_hand)
M.l_hand.screen_loc = ui_lhand
M.client.screen += M.l_hand
for(var/obj/item/I in M.held_items)
I.screen_loc = ui_hand_position(M.get_held_index_of_item(I))
M.client.screen += I
else
if(M.r_hand)
M.r_hand.screen_loc = null
if(M.l_hand)
M.l_hand.screen_loc = null
for(var/obj/item/I in M.held_items)
I.screen_loc = null
M.client.screen -= I
/mob/living/carbon/monkey/create_mob_hud()
if(client && !hud_used)

View File

@@ -7,35 +7,7 @@
mymob.client.screen = list()
mymob.client.screen += mymob.client.void
/mob/living/carbon/brain/create_mob_hud()
/mob/living/brain/create_mob_hud()
if(client && !hud_used)
hud_used = new /datum/hud/brain(src)
/datum/hud/hog_god/New(mob/owner)
..()
healths = new /obj/screen/healths/deity()
infodisplay += healths
deity_power_display = new /obj/screen/deity_power_display()
infodisplay += deity_power_display
deity_follower_display = new /obj/screen/deity_follower_display()
infodisplay += deity_follower_display
/mob/camera/god/create_mob_hud()
if(client && !hud_used)
hud_used = new /datum/hud/hog_god(src)
/obj/screen/deity_power_display
name = "Faith"
icon_state = "deity_power"
screen_loc = ui_deitypower
layer = HUD_LAYER
/obj/screen/deity_follower_display
name = "Followers"
icon_state = "deity_followers"
screen_loc = ui_deityfollowers
layer = HUD_LAYER

View File

@@ -1,254 +1,269 @@
/*
* This file handles all parallax-related business once the parallax itself is initialized with the rest of the HUD
*/
#define PARALLAX_IMAGE_WIDTH 15
#define PARALLAX_IMAGE_TILES (PARALLAX_IMAGE_WIDTH**2)
var/list/parallax_on_clients = list()
/client
var/list/parallax_layers
var/list/parallax_layers_cached
var/static/list/parallax_static_layers_tail = newlist(/obj/screen/parallax_pmaster, /obj/screen/parallax_space_whitifier)
var/atom/movable/movingmob
var/turf/previous_turf
var/dont_animate_parallax //world.time of when we can state animate()ing parallax again
var/last_parallax_shift //world.time of last update
var/parallax_throttle = 0 //ds between updates
var/parallax_movedir = 0
var/parallax_layers_max = 3
var/parallax_animate_timer
/obj/screen/parallax
var/base_offset_x = 0
var/base_offset_y = 0
mouse_opacity = 0
icon = 'icons/turf/space.dmi'
icon_state = "blank"
name = "space parallax"
screen_loc = "CENTER,CENTER"
blend_mode = BLEND_ADD
layer = AREA_LAYER
plane = PLANE_SPACE_PARALLAX
var/parallax_speed = 0
/obj/screen/plane_master
appearance_flags = PLANE_MASTER
screen_loc = "CENTER,CENTER"
/obj/screen/plane_master/parallax_master
plane = PLANE_SPACE_PARALLAX
blend_mode = BLEND_MULTIPLY
color = list(
1,0,0,0,
0,1,0,0,
0,0,1,0,
0,0,0,0,
0,0,0,1)
/obj/screen/plane_master/parallax_spacemaster //Turns space white, causing the parallax to only show in areas with opacity. Somehow
plane = PLANE_SPACE_BACKGROUND
color = list(
0,0,0,0,
0,0,0,0,
0,0,0,0,
1,1,1,1,
0,0,0,0)
/obj/screen/plane_master/parallax_spacemaster/New()
..()
overlays += image(icon = 'icons/mob/screen1.dmi', icon_state = "blank")
/obj/screen/plane_master/parallax_dustmaster
plane = PLANE_SPACE_DUST
color = list(0,0,0,0)
/datum/hud/proc/update_parallax_existence()
if(!parallax_initialized)
return
initialize_parallax()
update_parallax()
update_parallax_values()
/datum/hud/proc/initialize_parallax()
/datum/hud/proc/create_parallax()
var/client/C = mymob.client
if (!apply_parallax_pref())
return
if(!C.parallax_master)
C.parallax_master = PoolOrNew(/obj/screen/plane_master/parallax_master)
if(!C.parallax_spacemaster)
C.parallax_spacemaster = PoolOrNew(/obj/screen/plane_master/parallax_spacemaster)
if(!C.parallax_dustmaster)
C.parallax_dustmaster = PoolOrNew(/obj/screen/plane_master/parallax_dustmaster)
if(!length(C.parallax_layers_cached))
C.parallax_layers_cached = list()
C.parallax_layers_cached += new /obj/screen/parallax_layer/layer_1(null, C.view)
C.parallax_layers_cached += new /obj/screen/parallax_layer/layer_2(null, C.view)
if(!C.parallax.len)
for(var/obj/screen/parallax/bgobj in parallax_icon)
var/obj/screen/parallax/parallax_layer = PoolOrNew(/obj/screen/parallax)
parallax_layer.appearance = bgobj.appearance
parallax_layer.base_offset_x = bgobj.base_offset_x
parallax_layer.base_offset_y = bgobj.base_offset_y
parallax_layer.parallax_speed = bgobj.parallax_speed
parallax_layer.screen_loc = bgobj.screen_loc
C.parallax += parallax_layer
if(bgobj.parallax_speed)
C.parallax_movable += parallax_layer
C.parallax_layers = C.parallax_layers_cached.Copy()
if(!C.parallax_offset.len)
C.parallax_offset["horizontal"] = 0
C.parallax_offset["vertical"] = 0
if (length(C.parallax_layers) > C.parallax_layers_max)
C.parallax_layers.len = C.parallax_layers_max
C.screen |= C.parallax_dustmaster
C.screen |= (C.parallax_layers + C.parallax_static_layers_tail)
/datum/hud/proc/remove_parallax()
var/client/C = mymob.client
C.screen -= (C.parallax_layers_cached + C.parallax_static_layers_tail)
C.parallax_layers = null
/datum/hud/proc/apply_parallax_pref()
var/client/C = mymob.client
switch(C.prefs.parallax)
if (PARALLAX_INSANE)
C.parallax_throttle = FALSE
C.parallax_layers_max = 4
return TRUE
if (PARALLAX_MED)
C.parallax_throttle = PARALLAX_DELAY_MED
C.parallax_layers_max = 2
return TRUE
if (PARALLAX_LOW)
C.parallax_throttle = PARALLAX_DELAY_LOW
C.parallax_layers_max = 1
return TRUE
if (PARALLAX_DISABLE)
return FALSE
else
C.parallax_throttle = PARALLAX_DELAY_DEFAULT
C.parallax_layers_max = 3
return TRUE
/datum/hud/proc/update_parallax_pref()
remove_parallax()
create_parallax()
// This sets which way the current shuttle is moving (returns true if the shuttle has stopped moving so the caller can append their animation)
/datum/hud/proc/set_parallax_movedir(new_parallax_movedir)
. = FALSE
var/client/C = mymob.client
if(new_parallax_movedir == C.parallax_movedir)
return
var/animatedir = new_parallax_movedir
if(new_parallax_movedir == FALSE)
var/animate_time = 0
for(var/thing in C.parallax_layers)
var/obj/screen/parallax_layer/L = thing
L.icon_state = initial(L.icon_state)
L.update_o(C.view)
var/T = PARALLAX_LOOP_TIME / L.speed
if (T > animate_time)
animate_time = T
C.dont_animate_parallax = world.time + min(animate_time, PARALLAX_LOOP_TIME)
animatedir = C.parallax_movedir
var/matrix/newtransform
switch(animatedir)
if(NORTH)
newtransform = matrix(1, 0, 0, 0, 1, 480)
if(SOUTH)
newtransform = matrix(1, 0, 0, 0, 1,-480)
if(EAST)
newtransform = matrix(1, 0, 480, 0, 1, 0)
if(WEST)
newtransform = matrix(1, 0,-480, 0, 1, 0)
var/shortesttimer
for(var/thing in C.parallax_layers)
var/obj/screen/parallax_layer/L = thing
var/T = PARALLAX_LOOP_TIME / L.speed
if (isnull(shortesttimer))
shortesttimer = T
if (T < shortesttimer)
shortesttimer = T
L.transform = newtransform
animate(L, transform = matrix(), time = T, easing = QUAD_EASING | (new_parallax_movedir ? EASE_IN : EASE_OUT), flags = ANIMATION_END_NOW)
if (new_parallax_movedir)
L.transform = newtransform
animate(transform = matrix(), time = T) //queue up another animate so lag doesn't create a shutter
C.parallax_movedir = new_parallax_movedir
if (C.parallax_animate_timer)
deltimer(C.parallax_animate_timer)
C.parallax_animate_timer = addtimer(CALLBACK(src, .proc/update_parallax_motionblur, C, animatedir, new_parallax_movedir, newtransform), min(shortesttimer, PARALLAX_LOOP_TIME), TIMER_CLIENT_TIME|TIMER_STOPPABLE)
/datum/hud/proc/update_parallax_motionblur(client/C, animatedir, new_parallax_movedir, matrix/newtransform)
C.parallax_animate_timer = FALSE
for(var/thing in C.parallax_layers)
var/obj/screen/parallax_layer/L = thing
if (!new_parallax_movedir)
animate(L)
continue
var/newstate = initial(L.icon_state)
if (animatedir)
if(animatedir == NORTH || animatedir == SOUTH)
newstate += "_vertical"
else
newstate += "_horizontal"
var/T = PARALLAX_LOOP_TIME / L.speed
if (newstate in icon_states(L.icon))
L.icon_state = newstate
L.update_o(C.view)
L.transform = newtransform
animate(L, transform = matrix(), time = T, loop = -1, flags = ANIMATION_END_NOW)
/datum/hud/proc/update_parallax()
var/client/C = mymob.client
if(C.prefs.space_parallax)
parallax_on_clients |= C
for(var/obj/screen/parallax/bgobj in C.parallax)
C.screen |= bgobj
C.screen |= C.parallax_master
C.screen |= C.parallax_spacemaster
if(C.prefs.space_dust)
C.parallax_dustmaster.color = list(
1,0,0,0,
0,1,0,0,
0,0,1,0,
0,0,0,1)
else
C.parallax_dustmaster.color = list(0,0,0,0)
else
for(var/obj/screen/parallax/bgobj in C.parallax)
C.screen -= bgobj
parallax_on_clients -= C
C.screen -= C.parallax_master
C.screen -= C.parallax_spacemaster
C.parallax_dustmaster.color = list(0,0,0,0)
/datum/hud/proc/update_parallax_values()
var/client/C = mymob.client
if(!parallax_initialized)
return
if(!(locate(/turf/open/space) in trange(C.view,get_turf(C.eye))))
return
//ACTUALLY MOVING THE PARALLAX
var/turf/posobj = get_turf(C.eye)
var/area/areaobj = posobj.loc
// Update the movement direction of the parallax if necessary (for shuttles)
set_parallax_movedir(areaobj.parallax_movedir)
var/force
if(!C.previous_turf || (C.previous_turf.z != posobj.z))
C.previous_turf = posobj
force = TRUE
if (!force && world.time < C.last_parallax_shift+C.parallax_throttle)
return
//Doing it this way prevents parallax layers from "jumping" when you change Z-Levels.
var/offsetx = C.parallax_offset["horizontal"] + posobj.x - C.previous_turf.x
var/offsety = C.parallax_offset["vertical"] + posobj.y - C.previous_turf.y
C.parallax_offset["horizontal"] = offsetx
C.parallax_offset["vertical"] = offsety
var/offset_x = posobj.x - C.previous_turf.x
var/offset_y = posobj.y - C.previous_turf.y
if(!offset_x && !offset_y && !force)
return
var/last_delay = world.time - C.last_parallax_shift
last_delay = min(last_delay, C.parallax_throttle)
C.previous_turf = posobj
C.last_parallax_shift = world.time
var/maxoffset = 480 //480 = (15 tiles * 32 icon_size * 3 grid size / 2) - (15 tiles * 32 icon size / 2) for centering
var/minoffset = -960 //960 = (15 tiles * 32 icon_size * 3 grid size / 2) + (15 tiles * 32 icon size / 2) for centering
for(var/thing in C.parallax_layers)
var/obj/screen/parallax_layer/L = thing
if (L.view_sized != C.view)
L.update_o(C.view)
var/change_x = offset_x * L.speed
L.offset_x -= change_x
var/change_y = offset_y * L.speed
L.offset_y -= change_y
if(L.offset_x > 240)
L.offset_x -= 480
if(L.offset_x < -240)
L.offset_x += 480
if(L.offset_y > 240)
L.offset_y -= 480
if(L.offset_y < -240)
L.offset_y += 480
for(var/obj/screen/parallax/bgobj in C.parallax_movable)
var/accumulated_offset_x = bgobj.base_offset_x - round(offsetx * bgobj.parallax_speed * C.prefs.parallax_speed)
var/accumulated_offset_y = bgobj.base_offset_y - round(offsety * bgobj.parallax_speed * C.prefs.parallax_speed)
if(accumulated_offset_x > maxoffset)
accumulated_offset_x -= 1440 //3x3 grid, 15 tiles * 32 icon_size * 3 grid size
if(accumulated_offset_x < minoffset)
accumulated_offset_x += 1440
if(!areaobj.parallax_movedir && C.dont_animate_parallax <= world.time && (offset_x || offset_y) && abs(offset_x) <= max(C.parallax_throttle/world.tick_lag+1,1) && abs(offset_y) <= max(C.parallax_throttle/world.tick_lag+1,1) && (round(abs(change_x)) > 1 || round(abs(change_y)) > 1))
L.transform = matrix(1, 0, offset_x*L.speed, 0, 1, offset_y*L.speed)
animate(L, transform=matrix(), time = last_delay)
if(accumulated_offset_y > maxoffset)
accumulated_offset_y -= 1440
if(accumulated_offset_y < minoffset)
accumulated_offset_y += 1440
L.screen_loc = "CENTER-7:[round(L.offset_x,1)],CENTER-7:[round(L.offset_y,1)]"
bgobj.screen_loc = "CENTER:[accumulated_offset_x],CENTER:[accumulated_offset_y]"
/atom/movable/proc/update_parallax_contents()
if(length(client_mobs_in_contents))
for(var/thing in client_mobs_in_contents)
var/mob/M = thing
if(M && M.client && M.hud_used && length(M.client.parallax_layers))
M.hud_used.update_parallax()
//Parallax generation code below
/obj/screen/parallax_layer
icon = 'icons/effects/parallax.dmi'
var/speed = 1
var/offset_x = 0
var/offset_y = 0
var/view_sized
blend_mode = BLEND_ADD
plane = PLANE_SPACE_PARALLAX
screen_loc = "CENTER-7,CENTER-7"
mouse_opacity = 0
#define PARALLAX4_ICON_NUMBER 20
#define PARALLAX3_ICON_NUMBER 14
#define PARALLAX2_ICON_NUMBER 10
/datum/subsystem/parallax/proc/create_global_parallax_icons()
var/list/plane1 = list()
var/list/plane2 = list()
var/list/plane3 = list()
var/list/pixel_x = list()
var/list/pixel_y = list()
var/index = 1
for(var/i = 0 to (PARALLAX_IMAGE_TILES-1))
for(var/j = 1 to 9)
plane1 += rand(1,26)
plane2 += rand(1,26)
plane3 += rand(1,26)
pixel_x += world.icon_size * (i%PARALLAX_IMAGE_WIDTH)
pixel_y += world.icon_size * round(i/PARALLAX_IMAGE_WIDTH)
/obj/screen/parallax_layer/New(view)
..()
if (!view)
view = world.view
update_o(view)
for(var/i in 0 to 8)
var/obj/screen/parallax/parallax_layer = PoolOrNew(/obj/screen/parallax)
/obj/screen/parallax_layer/proc/update_o(view)
if (!view)
view = world.view
var/list/new_overlays = list()
var/count = Ceiling(view/(480/world.icon_size))+1
for(var/x in -count to count)
for(var/y in -count to count)
if(x == 0 && y == 0)
continue
var/image/I = image(icon, null, icon_state)
I.transform = matrix(1, 0, x*480, 0, 1, y*480)
new_overlays += I
var/list/L = list()
for(var/j in 1 to PARALLAX_IMAGE_TILES)
if(plane1[j+i*PARALLAX_IMAGE_TILES] <= PARALLAX4_ICON_NUMBER)
var/image/I = image('icons/turf/space_parallax4.dmi',"[plane1[j+i*PARALLAX_IMAGE_TILES]]")
I.pixel_x = pixel_x[j]
I.pixel_y = pixel_y[j]
L += I
overlays = new_overlays
view_sized = view
parallax_layer.overlays = L
parallax_layer.parallax_speed = 0
parallax_layer.calibrate_parallax(i+1)
parallax_icon[index] = parallax_layer
index++
/obj/screen/parallax_layer/layer_1
icon_state = "layer1"
speed = 0.6
layer = 1
for(var/i in 0 to 8)
var/obj/screen/parallax/parallax_layer = PoolOrNew(/obj/screen/parallax)
/obj/screen/parallax_layer/layer_2
icon_state = "layer2"
speed = 1
layer = 2
var/list/L = list()
for(var/j in 1 to PARALLAX_IMAGE_TILES)
if(plane2[j+i*PARALLAX_IMAGE_TILES] <= PARALLAX3_ICON_NUMBER)
var/image/I = image('icons/turf/space_parallax3.dmi',"[plane2[j+i*PARALLAX_IMAGE_TILES]]")
I.pixel_x = pixel_x[j]
I.pixel_y = pixel_y[j]
L += I
/obj/screen/parallax_pmaster
appearance_flags = PLANE_MASTER
plane = PLANE_SPACE_PARALLAX
blend_mode = BLEND_MULTIPLY
mouse_opacity = FALSE
screen_loc = "CENTER-7,CENTER-7"
parallax_layer.overlays = L
parallax_layer.parallax_speed = 0.5
parallax_layer.calibrate_parallax(i+1)
parallax_icon[index] = parallax_layer
index++
/obj/screen/parallax_space_whitifier
appearance_flags = PLANE_MASTER
plane = PLANE_SPACE
color = list(
0, 0, 0, 0,
0, 0, 0, 0,
0, 0, 0, 0,
1, 1, 1, 1,
0, 0, 0, 0
)
screen_loc = "CENTER-7,CENTER-7"
for(var/i in 0 to 8)
var/obj/screen/parallax/parallax_layer = PoolOrNew(/obj/screen/parallax)
var/list/L = list()
for(var/j in 1 to PARALLAX_IMAGE_TILES)
if(plane3[j+i*PARALLAX_IMAGE_TILES] <= PARALLAX2_ICON_NUMBER)
var/image/I = image('icons/turf/space_parallax2.dmi',"[plane3[j+i*PARALLAX_IMAGE_TILES]]")
I.pixel_x = pixel_x[j]
I.pixel_y = pixel_y[j]
L += I
parallax_layer.overlays = L
parallax_layer.parallax_speed = 1
parallax_layer.calibrate_parallax(i+1)
parallax_icon[index] = parallax_layer
index++
parallax_initialized = 1
/obj/screen/parallax/proc/calibrate_parallax(var/i)
if(!i) return
/* Placement of screen objects
1 2 3
4 5 6
7 8 9
*/
base_offset_x = -PARALLAX_IMAGE_WIDTH*world.icon_size/2
base_offset_y = -PARALLAX_IMAGE_WIDTH*world.icon_size/2
switch(i)
if(1,4,7)
base_offset_x -= world.icon_size*PARALLAX_IMAGE_WIDTH
if(3,6,9)
base_offset_x += world.icon_size*PARALLAX_IMAGE_WIDTH
switch(i)
if(1,2,3)
base_offset_y += world.icon_size*PARALLAX_IMAGE_WIDTH
if(7,8,9)
base_offset_y -= world.icon_size*PARALLAX_IMAGE_WIDTH
screen_loc = "CENTER:[base_offset_x],CENTER:[base_offset_y]"
#undef PARALLAX4_ICON_NUMBER
#undef PARALLAX3_ICON_NUMBER
#undef PARALLAX2_ICON_NUMBER
#undef PARALLAX_IMAGE_WIDTH
#undef PARALLAX_IMAGE_TILES
#undef LOOP_NONE
#undef LOOP_NORMAL
#undef LOOP_REVERSE
#undef LOOP_TIME

View File

@@ -0,0 +1,28 @@
/obj/screen/plane_master
screen_loc = "CENTER"
icon_state = "blank"
appearance_flags = PLANE_MASTER|NO_CLIENT_COLOR
blend_mode = BLEND_OVERLAY
/obj/screen/plane_master/New()
if(blend_mode == BLEND_MULTIPLY)
//What is this? Read http://www.byond.com/forum/?post=2141928
var/image/backdrop = image('icons/mob/screen_gen.dmi', "black")
backdrop.transform = matrix(200, 0, 0, 0, 200, 0)
backdrop.layer = BACKGROUND_LAYER
backdrop.blend_mode = BLEND_OVERLAY
overlays += backdrop
..()
/obj/screen/plane_master/game_world
name = "game world plane master"
plane = GAME_PLANE
blend_mode = BLEND_OVERLAY
/obj/screen/plane_master/lighting
name = "lighting plane master"
plane = LIGHTING_PLANE
blend_mode = BLEND_OVERLAY
// blend_mode = BLEND_MULTIPLY
// color = list(1,0,0,0, 0,1,0,0, 0,0,1,0, 0,0,0,0, 0.1,0.1,0.1,0)
mouse_opacity = 0

View File

@@ -5,9 +5,15 @@
name = "cyborg module"
icon_state = "nomod"
/obj/screen/robot/Click()
if(isobserver(usr))
return 1
/obj/screen/robot/module/Click()
if(..())
return
var/mob/living/silicon/robot/R = usr
if(R.module)
if(R.module.type != /obj/item/weapon/robot_module)
R.hud_used.toggle_show_robot_modules()
return 1
R.pick_module()
@@ -17,6 +23,8 @@
icon_state = "inv1"
/obj/screen/robot/module1/Click()
if(..())
return
var/mob/living/silicon/robot/R = usr
R.toggle_module(1)
@@ -25,6 +33,8 @@
icon_state = "inv2"
/obj/screen/robot/module2/Click()
if(..())
return
var/mob/living/silicon/robot/R = usr
R.toggle_module(2)
@@ -33,6 +43,8 @@
icon_state = "inv3"
/obj/screen/robot/module3/Click()
if(..())
return
var/mob/living/silicon/robot/R = usr
R.toggle_module(3)
@@ -41,6 +53,8 @@
icon_state = "radio"
/obj/screen/robot/radio/Click()
if(..())
return
var/mob/living/silicon/robot/R = usr
R.radio.interact(R)
@@ -49,6 +63,8 @@
icon_state = "store"
/obj/screen/robot/store/Click()
if(..())
return
var/mob/living/silicon/robot/R = usr
R.uneq_active()
@@ -57,6 +73,8 @@
icon_state = "lamp0"
/obj/screen/robot/lamp/Click()
if(..())
return
var/mob/living/silicon/robot/R = usr
R.control_headlamp()
@@ -65,14 +83,24 @@
icon_state = "ionpulse0"
/obj/screen/robot/thrusters/Click()
if(..())
return
var/mob/living/silicon/robot/R = usr
R.toggle_ionpulse()
/datum/hud/robot/New(mob/owner)
/datum/hud/robot
ui_style_icon = 'icons/mob/screen_cyborg.dmi'
/datum/hud/robot/New(mob/owner, ui_style = 'icons/mob/screen_cyborg.dmi')
..()
var/mob/living/silicon/robot/mymobR = mymob
var/obj/screen/using
using = new/obj/screen/wheel/talk
using.screen_loc = ui_borg_talk_wheel
wheels += using
static_inventory += using
//Radio
using = new /obj/screen/robot/radio()
using.screen_loc = ui_borg_radio
@@ -123,19 +151,18 @@
mymobR.thruster_button = using
//Intent
using = new /obj/screen/act_intent/robot()
using.icon_state = mymob.a_intent
static_inventory += using
action_intent = using
action_intent = new /obj/screen/act_intent/robot()
action_intent.icon_state = mymob.a_intent
static_inventory += action_intent
//Health
healths = new /obj/screen/healths/robot()
infodisplay += healths
//Installed Module
mymob.hands = new /obj/screen/robot/module()
mymob.hands.screen_loc = ui_borg_module
static_inventory += mymob.hands
mymobR.hands = new /obj/screen/robot/module()
mymobR.hands.screen_loc = ui_borg_module
static_inventory += mymobR.hands
//Store
module_store_icon = new /obj/screen/robot/store()
@@ -154,50 +181,53 @@
/datum/hud/proc/toggle_show_robot_modules()
if(!isrobot(mymob)) return
if(!iscyborg(mymob)) return
var/mob/living/silicon/robot/r = mymob
var/mob/living/silicon/robot/R = mymob
r.shown_robot_modules = !r.shown_robot_modules
R.shown_robot_modules = !R.shown_robot_modules
update_robot_modules_display()
/datum/hud/proc/update_robot_modules_display()
if(!isrobot(mymob)) return
/datum/hud/proc/update_robot_modules_display(mob/viewer)
if(!iscyborg(mymob)) return
var/mob/living/silicon/robot/r = mymob
var/mob/living/silicon/robot/R = mymob
if(!r.client)
var/mob/screenmob = viewer || R
if(!R.module)
return
if(!r.module)
if(!R.client)
return
if(r.shown_robot_modules && hud_shown)
if(R.shown_robot_modules && screenmob.hud_used.hud_shown)
//Modules display is shown
r.client.screen += module_store_icon //"store" icon
screenmob.client.screen += module_store_icon //"store" icon
if(!r.module.modules)
if(!R.module.modules)
usr << "<span class='danger'>Selected module has no modules to select</span>"
return
if(!r.robot_modules_background)
if(!R.robot_modules_background)
return
var/display_rows = Ceiling(length(r.module.get_inactive_modules()) / 8)
r.robot_modules_background.screen_loc = "CENTER-4:16,SOUTH+1:7 to CENTER+3:16,SOUTH+[display_rows]:7"
r.client.screen += r.robot_modules_background
var/display_rows = Ceiling(length(R.module.get_inactive_modules()) / 8)
R.robot_modules_background.screen_loc = "CENTER-4:16,SOUTH+1:7 to CENTER+3:16,SOUTH+[display_rows]:7"
screenmob.client.screen += R.robot_modules_background
var/x = -4 //Start at CENTER-4,SOUTH+1
var/y = 1
for(var/atom/movable/A in r.module.get_inactive_modules())
for(var/atom/movable/A in R.module.get_inactive_modules())
//Module is not currently active
r.client.screen += A
screenmob.client.screen += A
if(x < 0)
A.screen_loc = "CENTER[x]:16,SOUTH+[y]:7"
else
A.screen_loc = "CENTER+[x]:16,SOUTH+[y]:7"
A.layer = ABOVE_HUD_LAYER
A.plane = ABOVE_HUD_PLANE
x++
if(x == 4)
@@ -206,37 +236,41 @@
else
//Modules display is hidden
r.client.screen -= module_store_icon //"store" icon
screenmob.client.screen -= module_store_icon //"store" icon
for(var/atom/A in r.module.get_inactive_modules())
for(var/atom/A in R.module.get_inactive_modules())
//Module is not currently active
r.client.screen -= A
r.shown_robot_modules = 0
r.client.screen -= r.robot_modules_background
screenmob.client.screen -= A
R.shown_robot_modules = 0
screenmob.client.screen -= R.robot_modules_background
/mob/living/silicon/robot/create_mob_hud()
if(client && !hud_used)
hud_used = new /datum/hud/robot(src)
/datum/hud/robot/persistant_inventory_update()
/datum/hud/robot/persistent_inventory_update(mob/viewer)
if(!mymob)
return
var/mob/living/silicon/robot/R = mymob
if(hud_shown)
if(R.module_state_1)
R.module_state_1.screen_loc = ui_inv1
R.client.screen += R.module_state_1
if(R.module_state_2)
R.module_state_2.screen_loc = ui_inv2
R.client.screen += R.module_state_2
if(R.module_state_3)
R.module_state_3.screen_loc = ui_inv3
R.client.screen += R.module_state_3
else
if(R.module_state_1)
R.module_state_1.screen_loc = null
if(R.module_state_2)
R.module_state_2.screen_loc = null
if(R.module_state_3)
R.module_state_3.screen_loc = null
var/mob/screenmob = viewer || R
if(screenmob.hud_used)
if(screenmob.hud_used.hud_shown)
for(var/i in 1 to R.held_items.len)
var/obj/item/I = R.held_items[i]
if(I)
switch(i)
if(1)
I.screen_loc = ui_inv1
if(2)
I.screen_loc = ui_inv2
if(3)
I.screen_loc = ui_inv3
else
return
screenmob.client.screen += I
else
for(var/obj/item/I in R.held_items)
screenmob.client.screen -= I

View File

@@ -10,15 +10,24 @@
name = ""
icon = 'icons/mob/screen_gen.dmi'
layer = ABOVE_HUD_LAYER
unacidable = 1
plane = ABOVE_HUD_PLANE
resistance_flags = INDESTRUCTIBLE | LAVA_PROOF | FIRE_PROOF | UNACIDABLE | ACID_PROOF
appearance_flags = APPEARANCE_UI
var/obj/master = null //A reference to the object in the slot. Grabs or items, generally.
var/datum/hud/hud = null // A reference to the owner HUD, if any.
/obj/screen/take_damage()
return
/obj/screen/Destroy()
master = null
return ..()
/obj/screen/examine(mob/user)
return
/obj/screen/orbit()
return
/obj/screen/text
icon = null
@@ -30,6 +39,7 @@
/obj/screen/swap_hand
layer = HUD_LAYER
plane = HUD_PLANE
name = "swap hand"
/obj/screen/swap_hand/Click()
@@ -46,23 +56,41 @@
M.swap_hand()
return 1
/obj/screen/inventory/craft
/obj/screen/craft
name = "crafting menu"
icon = 'icons/mob/screen_midnight.dmi'
icon_state = "craft"
screen_loc = ui_crafting
/obj/screen/inventory/craft/Click()
/obj/screen/craft/Click()
var/mob/living/M = usr
if(isobserver(usr))
return
M.OpenCraftingMenu()
/obj/screen/area_creator
name = "create new area"
icon = 'icons/mob/screen_midnight.dmi'
icon_state = "area_edit"
screen_loc = ui_building
/obj/screen/area_creator/Click()
if(usr.incapacitated())
return 1
var/area/A = get_area(usr)
if(!A.outdoors)
usr << "<span class='warning'>There is already a defined structure here.</span>"
return 1
create_area(usr)
/obj/screen/inventory
var/slot_id // The indentifier for the slot. It has nothing to do with ID cards.
var/icon_empty // Icon when empty. For now used only by humans.
var/icon_full // Icon when contains an item. For now used only by humans.
layer = HUD_LAYER
plane = HUD_PLANE
/obj/screen/inventory/Click()
/obj/screen/inventory/Click(location, control, params)
// At this point in client Click() code we have passed the 1/10 sec check and little else
// We don't even know if it's a middle click
if(world.time <= usr.next_move)
@@ -70,11 +98,16 @@
if(usr.incapacitated())
return 1
if (istype(usr.loc,/obj/mecha)) // stops inventory actions in a mech
if(istype(usr.loc,/obj/mecha)) // stops inventory actions in a mech
return 1
if(hud && hud.mymob && slot_id)
var/obj/item/inv_item = hud.mymob.get_item_by_slot(slot_id)
if(inv_item)
return inv_item.Click(location, control, params)
if(usr.attack_ui(slot_id))
usr.update_inv_l_hand(0)
usr.update_inv_r_hand(0)
usr.update_inv_hands()
return 1
/obj/screen/inventory/update_icon()
@@ -91,13 +124,15 @@
var/image/active_overlay
var/image/handcuff_overlay
var/image/blocked_overlay
var/held_index = 0
/obj/screen/inventory/hand/update_icon()
..()
if(!active_overlay)
active_overlay = image("icon"=icon, "icon_state"="hand_active")
if(!handcuff_overlay)
var/state = (slot_id == slot_r_hand) ? "markus" : "gabrielle"
var/state = (!(held_index % 2)) ? "markus" : "gabrielle"
handcuff_overlay = image("icon"='icons/mob/screen_gen.dmi', "icon_state"=state)
if(!blocked_overlay)
blocked_overlay = image("icon"='icons/mob/screen_gen.dmi', "icon_state"="blocked")
@@ -109,19 +144,16 @@
var/mob/living/carbon/C = hud.mymob
if(C.handcuffed)
add_overlay(handcuff_overlay)
if(slot_id == slot_r_hand)
if(!C.has_right_hand())
add_overlay(blocked_overlay)
else if(slot_id == slot_l_hand)
if(!C.has_left_hand())
if(held_index)
if(!C.has_hand_for_held_index(held_index))
add_overlay(blocked_overlay)
if(slot_id == slot_l_hand && hud.mymob.hand)
add_overlay(active_overlay)
else if(slot_id == slot_r_hand && !hud.mymob.hand)
if(held_index == hud.mymob.active_hand_index)
add_overlay(active_overlay)
/obj/screen/inventory/hand/Click()
/obj/screen/inventory/hand/Click(location, control, params)
// At this point in client Click() code we have passed the 1/10 sec check and little else
// We don't even know if it's a middle click
if(world.time <= usr.next_move)
@@ -131,13 +163,12 @@
if (istype(usr.loc,/obj/mecha)) // stops inventory actions in a mech
return 1
if(ismob(usr))
var/mob/M = usr
switch(name)
if("right hand", "r_hand")
M.activate_hand("r")
if("left hand", "l_hand")
M.activate_hand("l")
if(hud.mymob.active_hand_index == held_index)
var/obj/item/I = hud.mymob.get_active_held_item()
if(I)
I.Click(location, control, params)
else
hud.mymob.swap_hand(held_index)
return 1
/obj/screen/close
@@ -155,6 +186,7 @@
icon = 'icons/mob/screen_midnight.dmi'
icon_state = "act_drop"
layer = HUD_LAYER
plane = HUD_PLANE
/obj/screen/drop/Click()
usr.drop_item_v()
@@ -165,25 +197,26 @@
screen_loc = ui_acti
/obj/screen/act_intent/Click(location, control, params)
if(ishuman(usr) && (usr.client.prefs.toggles & INTENT_STYLE))
usr.a_intent_change(INTENT_HOTKEY_RIGHT)
/obj/screen/act_intent/segmented/Click(location, control, params)
if(usr.client.prefs.toggles & INTENT_STYLE)
var/_x = text2num(params2list(params)["icon-x"])
var/_y = text2num(params2list(params)["icon-y"])
if(_x<=16 && _y<=16)
usr.a_intent_change("harm")
usr.a_intent_change(INTENT_HARM)
else if(_x<=16 && _y>=17)
usr.a_intent_change("help")
usr.a_intent_change(INTENT_HELP)
else if(_x>=17 && _y<=16)
usr.a_intent_change("grab")
usr.a_intent_change(INTENT_GRAB)
else if(_x>=17 && _y>=17)
usr.a_intent_change("disarm")
usr.a_intent_change(INTENT_DISARM)
else
usr.a_intent_change("right")
return ..()
/obj/screen/act_intent/alien
icon = 'icons/mob/screen_alien.dmi'
@@ -222,12 +255,10 @@
C << "<span class='warning'>You are not wearing an internals mask!</span>"
return
if(istype(C.l_hand, /obj/item/weapon/tank))
C << "<span class='notice'>You are now running on internals from the [C.l_hand] on your left hand.</span>"
C.internal = C.l_hand
else if(istype(C.r_hand, /obj/item/weapon/tank))
C << "<span class='notice'>You are now running on internals from the [C.r_hand] on your right hand.</span>"
C.internal = C.r_hand
var/obj/item/I = C.is_holding_item_of_type(/obj/item/weapon/tank)
if(I)
C << "<span class='notice'>You are now running on internals from the [I] on your [C.get_held_index_name(C.get_held_index_of_item(I))].</span>"
C.internal = I
else if(ishuman(C))
var/mob/living/carbon/human/H = C
if(istype(H.s_store, /obj/item/weapon/tank))
@@ -261,14 +292,19 @@
icon_state = "running"
/obj/screen/mov_intent/Click()
switch(usr.m_intent)
toggle(usr)
/obj/screen/mov_intent/proc/toggle(mob/user)
if(isobserver(user))
return
switch(user.m_intent)
if("run")
usr.m_intent = "walk"
user.m_intent = MOVE_INTENT_WALK
icon_state = "walking"
if("walk")
usr.m_intent = "run"
user.m_intent = MOVE_INTENT_RUN
icon_state = "running"
usr.update_icons()
user.update_icons()
/obj/screen/pull
name = "stop pulling"
@@ -276,6 +312,8 @@
icon_state = "pull"
/obj/screen/pull/Click()
if(isobserver(usr))
return
usr.stop_pulling()
/obj/screen/pull/update_icon(mob/mymob)
@@ -290,6 +328,7 @@
icon = 'icons/mob/screen_midnight.dmi'
icon_state = "act_resist"
layer = HUD_LAYER
plane = HUD_PLANE
/obj/screen/resist/Click()
if(isliving(usr))
@@ -307,7 +346,7 @@
if (istype(usr.loc,/obj/mecha)) // stops inventory actions in a mech
return 1
if(master)
var/obj/item/I = usr.get_active_hand()
var/obj/item/I = usr.get_active_held_item()
if(I)
master.attackby(I, usr, params)
return 1
@@ -329,55 +368,65 @@
var/selecting = "chest"
/obj/screen/zone_sel/Click(location, control,params)
if(isobserver(usr))
return
var/list/PL = params2list(params)
var/icon_x = text2num(PL["icon-x"])
var/icon_y = text2num(PL["icon-y"])
var/old_selecting = selecting //We're only going to update_icon() if there's been a change
var/choice
switch(icon_y)
if(1 to 9) //Legs
switch(icon_x)
if(10 to 15)
selecting = "r_leg"
choice = "r_leg"
if(17 to 22)
selecting = "l_leg"
choice = "l_leg"
else
return 1
if(10 to 13) //Hands and groin
switch(icon_x)
if(8 to 11)
selecting = "r_arm"
choice = "r_arm"
if(12 to 20)
selecting = "groin"
choice = "groin"
if(21 to 24)
selecting = "l_arm"
choice = "l_arm"
else
return 1
if(14 to 22) //Chest and arms to shoulders
switch(icon_x)
if(8 to 11)
selecting = "r_arm"
choice = "r_arm"
if(12 to 20)
selecting = "chest"
choice = "chest"
if(21 to 24)
selecting = "l_arm"
choice = "l_arm"
else
return 1
if(23 to 30) //Head, but we need to check for eye or mouth
if(icon_x in 12 to 20)
selecting = "head"
choice = "head"
switch(icon_y)
if(23 to 24)
if(icon_x in 15 to 17)
selecting = "mouth"
choice = "mouth"
if(26) //Eyeline, eyes are on 15 and 17
if(icon_x in 14 to 18)
selecting = "eyes"
choice = "eyes"
if(25 to 27)
if(icon_x in 15 to 17)
selecting = "eyes"
choice = "eyes"
if(old_selecting != selecting)
return set_selected_zone(choice, usr)
/obj/screen/zone_sel/proc/set_selected_zone(choice, mob/user)
if(isobserver(user))
return
if(choice != selecting)
selecting = choice
update_icon(usr)
return 1
@@ -404,6 +453,7 @@
blend_mode = BLEND_ADD
screen_loc = "WEST,SOUTH to EAST,NORTH"
layer = FLASH_LAYER
plane = FULLSCREEN_PLANE
/obj/screen/damageoverlay
icon = 'icons/mob/screen_full.dmi'
@@ -413,6 +463,7 @@
screen_loc = "CENTER-7,CENTER-7"
mouse_opacity = 0
layer = UI_DAMAGE_LAYER
plane = FULLSCREEN_PLANE
/obj/screen/healths
name = "health"
@@ -455,6 +506,17 @@
screen_loc = ui_health
mouse_opacity = 0
/obj/screen/healths/clock
icon = 'icons/mob/actions.dmi'
icon_state = "bg_clock"
screen_loc = ui_health
mouse_opacity = 0
/obj/screen/healths/clock/gear
icon = 'icons/mob/clockwork_mobs.dmi'
icon_state = "bg_gear"
screen_loc = ui_internal
/obj/screen/healths/revenant
name = "essence"
icon = 'icons/mob/actions.dmi'
@@ -465,3 +527,140 @@
/obj/screen/healthdoll
name = "health doll"
screen_loc = ui_healthdoll
/obj/screen/wheel
name = "wheel"
layer = HUD_LAYER
plane = HUD_PLANE
icon_state = ""
screen_loc = null //if you make a new wheel, remember to give it a screen_loc
var/list/buttons_names = list() //list of the names for each button, its length is the amount of buttons.
var/toggled = 0 //wheel is hidden/shown
var/wheel_buttons_type //the type of buttons used with this wheel.
var/list/buttons_list = list()
/obj/screen/wheel/New()
..()
build_options()
//we create the buttons for the wheel and place them in a square spiral fashion.
/obj/screen/wheel/proc/build_options()
var/obj/screen/wheel_button/close_wheel/CW = new ()
buttons_list += CW //the close option
CW.wheel = src
var/list/offset_x_list = list()
var/list/offset_y_list = list()
var/num = 1
var/N = 1
var/M = 0
var/sign = -1
my_loop:
while(offset_y_list.len < buttons_names.len)
for(var/i=1, i<=num, i++)
offset_y_list += N
offset_x_list += M
if(offset_y_list.len == buttons_names.len)
break my_loop
if(N != 0)
N = 0
M = -sign
else
N = sign
M = 0
sign = -sign
num++
var/screenx = 8
var/screeny = 8
for(var/i = 1, i <= buttons_names.len, i++)
var/obj/screen/wheel_button/WB = new wheel_buttons_type()
WB.wheel = src
buttons_list += WB
screenx += offset_x_list[i]
screeny += offset_y_list[i]
WB.screen_loc = "[screenx], [screeny]"
set_button(WB, i)
/obj/screen/wheel/proc/set_button(obj/screen/wheel_button/WB, button_number)
WB.name = buttons_names[button_number]
return
/obj/screen/wheel/Destroy()
for(var/obj/screen/S in buttons_list)
qdel(S)
return ..()
/obj/screen/wheel/Click()
if(world.time <= usr.next_move)
return
if(usr.stat)
return
if(isliving(usr))
var/mob/living/L = usr
if(toggled)
L.client.screen -= buttons_list
else
L.client.screen |= buttons_list
toggled = !toggled
/obj/screen/wheel/talk
name = "talk wheel"
icon_state = "talk_wheel"
screen_loc = "11:6,2:-11"
wheel_buttons_type = /obj/screen/wheel_button/talk
buttons_names = list("help","hello","bye","stop","thanks","come","out", "yes", "no")
var/list/word_messages = list(list("Help!","Help me!"), list("Hello.", "Hi."), list("Bye.", "Goodbye."),\
list("Stop!", "Halt!"), list("Thanks.", "Thanks!", "Thank you."), \
list("Come.", "Follow me."), list("Out!", "Go away!", "Get out!"), \
list("Yes.", "Affirmative."), list("No.", "Negative"))
/obj/screen/wheel/talk/set_button(obj/screen/wheel_button/WB, button_number)
..()
var/obj/screen/wheel_button/talk/T = WB //we already know what type the button is exactly.
T.icon_state = "talk_[T.name]"
T.word_messages = word_messages[button_number]
/obj/screen/wheel_button
name = "default wheel button"
screen_loc = "8,8"
layer = HUD_LAYER
plane = HUD_PLANE
mouse_opacity = 2
var/obj/screen/wheel/wheel
/obj/screen/wheel_button/Destroy()
wheel = null
return ..()
/obj/screen/wheel_button/close_wheel
name = "close wheel"
icon_state = "x3"
/obj/screen/wheel_button/close_wheel/Click()
if(isliving(usr))
var/mob/living/L = usr
L.client.screen -= wheel.buttons_list
wheel.toggled = !wheel.toggled
/obj/screen/wheel_button/talk
name = "talk option"
icon_state = "talk_help"
var/talk_cooldown = 0
var/list/word_messages = list()
/obj/screen/wheel_button/talk/Click(location, control,params)
if(isliving(usr))
var/mob/living/L = usr
if(L.stat)
return
if(word_messages.len && talk_cooldown < world.time)
talk_cooldown = world.time + 10
L.say(pick(word_messages))

View File

@@ -68,11 +68,11 @@
var/obj/screen/using
using = new /obj/screen/swarmer/FabricateTrap()
using.screen_loc = ui_rhand
using.screen_loc = ui_hand_position(2)
static_inventory += using
using = new /obj/screen/swarmer/Barricade()
using.screen_loc = ui_lhand
using.screen_loc = ui_hand_position(1)
static_inventory += using
using = new /obj/screen/swarmer/Replicate()

View File

@@ -3,16 +3,22 @@
/obj/item/proc/attack_self(mob/user)
return
/obj/item/proc/pre_attackby(obj/O, mob/living/user, params) //do stuff before attackby!
return TRUE //return FALSE to avoid calling attackby after this proc does stuff
// No comment
/atom/proc/attackby(obj/item/W, mob/user, params)
return
/obj/attackby(obj/item/I, mob/living/user, params)
return I.attack_obj(src, user)
if(unique_rename && istype(I, /obj/item/weapon/pen))
rewrite(user)
else
return I.attack_obj(src, user)
/mob/living/attackby(obj/item/I, mob/user, params)
user.changeNext_move(CLICK_CD_MELEE)
if(user.a_intent == "harm" && stat == DEAD && butcher_results) //can we butcher it?
if(user.a_intent == INTENT_HARM && stat == DEAD && butcher_results) //can we butcher it?
var/sharpness = I.is_sharp()
if(sharpness)
user << "<span class='notice'>You begin to butcher [src]...</span>"
@@ -34,6 +40,7 @@
user.lastattacked = M
M.lastattacker = user
user.do_attack_animation(M)
M.attacked_by(src, user)
add_logs(user, M, "attacked", src.name, "(INTENT: [uppertext(user.a_intent)]) (DAMTYPE: [uppertext(damtype)])")
@@ -48,29 +55,33 @@
user.do_attack_animation(O)
O.attacked_by(src, user)
/atom/movable/proc/attacked_by()
return
/obj/attacked_by(obj/item/I, mob/living/user)
if(I.force)
user.visible_message("<span class='danger'>[user] has hit [src] with [I]!</span>", "<span class='danger'>You hit [src] with [I]!</span>")
visible_message("<span class='danger'>[user] has hit [src] with [I]!</span>", null, null, COMBAT_MESSAGE_RANGE)
//only witnesses close by and the victim see a hit message.
take_damage(I.force, I.damtype, "melee", 1)
/mob/living/attacked_by(obj/item/I, mob/living/user)
if(user != src)
user.do_attack_animation(src)
if(send_item_attack_message(I, user))
if(apply_damage(I.force, I.damtype))
if(I.damtype == BRUTE)
if(prob(33))
I.add_mob_blood(src)
var/turf/location = get_turf(src)
add_splatter_floor(location)
if(get_dist(user, src) <= 1) //people with TK won't get smeared with blood
user.add_mob_blood(src)
return TRUE
send_item_attack_message(I, user)
if(I.force)
apply_damage(I.force, I.damtype)
if(I.damtype == BRUTE)
if(prob(33))
I.add_mob_blood(src)
var/turf/location = get_turf(src)
add_splatter_floor(location)
if(get_dist(user, src) <= 1) //people with TK won't get smeared with blood
user.add_mob_blood(src)
return TRUE //successful attack
/mob/living/simple_animal/attacked_by(obj/item/I, mob/living/user)
if(I.force < force_threshold || I.damtype == STAMINA)
playsound(loc, 'sound/weapons/tap.ogg', I.get_clamped_volume(), 1, -1)
else
return ..()
// Proximity_flag is 1 if this afterattack was called on something adjacent, in your square, or on your person.
// Click parameters is the params string from byond Click() code, see that documentation.
@@ -87,27 +98,17 @@
/mob/living/proc/send_item_attack_message(obj/item/I, mob/living/user, hit_area)
var/message_verb = "attacked"
if(I.attack_verb.len)
if(I.attack_verb && I.attack_verb.len)
message_verb = "[pick(I.attack_verb)]"
else if(!I.force)
return 0
return
var/message_hit_area = ""
if(hit_area)
message_hit_area = " in the [hit_area]"
var/attack_message = "[src] has been [message_verb][message_hit_area] with [I]."
if(user in viewers(src, null))
attack_message = "[user] has [message_verb] [src][message_hit_area] with [I]!"
visible_message("<span class='danger'>[attack_message]</span>",
"<span class='userdanger'>[attack_message]</span>")
visible_message("<span class='danger'>[attack_message]</span>", \
"<span class='userdanger'>[attack_message]</span>", null, COMBAT_MESSAGE_RANGE)
return 1
/mob/living/simple_animal/send_item_attack_message(obj/item/I, mob/living/user, hit_area)
if(!I.force)
user.visible_message("<span class='warning'>[user] gently taps [src] with [I].</span>",\
"<span class='warning'>This weapon is ineffective, it does no damage!</span>")
else if(I.force < force_threshold || I.damtype == STAMINA)
visible_message("<span class='warning'>[I] bounces harmlessly off of [src].</span>",\
"<span class='warning'>[I] bounces harmlessly off of [src]!</span>")
else
return ..()

View File

@@ -15,6 +15,7 @@
// Otherwise jump
else if(A.loc)
loc = get_turf(A)
update_parallax_contents()
/mob/dead/observer/ClickOn(var/atom/A, var/params)
if(client.click_intercept)

View File

@@ -20,7 +20,7 @@
var/override = 0
for(var/datum/mutation/human/HM in dna.mutations)
override += HM.on_attack_hand(src, A)
override += HM.on_attack_hand(src, A, proximity)
if(override)
return
@@ -50,9 +50,8 @@
for(var/datum/mutation/human/HM in dna.mutations)
HM.on_ranged_attack(src, A)
var/turf/T = A
if(istype(T) && get_dist(src,T) <= 1)
src.Move_Pulled(T)
if(isturf(A) && get_dist(src,A) <= 1)
src.Move_Pulled(A)
/*
Animals & All Unspecified
@@ -60,10 +59,6 @@
/mob/living/UnarmedAttack(atom/A)
A.attack_animal(src)
/mob/living/simple_animal/hostile/UnarmedAttack(atom/A)
target = A
AttackingTarget()
/atom/proc/attack_animal(mob/user)
return
/mob/living/RestrainedClickOn(atom/A)
@@ -87,7 +82,7 @@
/mob/living/carbon/monkey/RestrainedClickOn(atom/A)
if(..())
return
if(a_intent != "harm" || !ismob(A))
if(a_intent != INTENT_HARM || !ismob(A))
return
if(is_muzzled())
return
@@ -115,7 +110,7 @@
*/
/mob/living/carbon/alien/UnarmedAttack(atom/A)
A.attack_alien(src)
/atom/proc/attack_alien(mob/user)
/atom/proc/attack_alien(mob/living/carbon/alien/user)
attack_paw(user)
return
/mob/living/carbon/alien/RestrainedClickOn(atom/A)
@@ -139,6 +134,68 @@
/mob/living/simple_animal/slime/RestrainedClickOn(atom/A)
return
/*
Drones
*/
/mob/living/simple_animal/drone/UnarmedAttack(atom/A)
A.attack_drone(src)
/atom/proc/attack_drone(mob/living/simple_animal/drone/user)
attack_hand(user) //defaults to attack_hand. Override it when you don't want drones to do same stuff as humans.
/mob/living/simple_animal/slime/RestrainedClickOn(atom/A)
return
/*
True Devil
*/
/mob/living/carbon/true_devil/UnarmedAttack(atom/A, proximity)
A.attack_hand(src)
/*
Brain
*/
/mob/living/brain/UnarmedAttack(atom/A)//Stops runtimes due to attack_animal being the default
return
/*
pAI
*/
/mob/living/silicon/pai/UnarmedAttack(atom/A)//Stops runtimes due to attack_animal being the default
return
/*
Simple animals
*/
/mob/living/simple_animal/UnarmedAttack(atom/A, proximity)
if(!dextrous)
return ..()
if(!ismob(A))
A.attack_hand(src)
update_inv_hands()
/*
Hostile animals
*/
/mob/living/simple_animal/hostile/UnarmedAttack(atom/A)
target = A
if(dextrous && !is_type_in_typecache(A, environment_target_typecache) && !ismob(A))
..()
else
AttackingTarget()
/*
New Players:
Have no reason to click on anything at all.

View File

@@ -1,11 +1,13 @@
/*
Telekinesis
This needs more thinking out, but I might as well.
*/
var/const/tk_maxrange = 15
/*
Telekinetic attack:
By default, emulate the user's unarmed attack
*/
/atom/proc/attack_tk(mob/user)
@@ -17,6 +19,7 @@ var/const/tk_maxrange = 15
/*
This is similar to item attack_self, but applies to anything
that you can grab with a telekinetic grab.
It is used for manipulating things at range, for example, opening and closing closets.
There are not a lot of defaults at this time, add more where appropriate.
*/
@@ -54,6 +57,7 @@ var/const/tk_maxrange = 15
/*
TK Grab Item (the workhorse of old TK)
* If you have not grabbed something, do a normal tk attack
* If you have something, throw it at the target. If it is already adjacent, do a normal attackby()
* If you click what you are holding, or attack_self(), do an attack_self_tk() on it.
@@ -66,8 +70,9 @@ var/const/tk_maxrange = 15
icon_state = "2"
flags = NOBLUDGEON | ABSTRACT | DROPDEL
//item_state = null
w_class = 10
w_class = WEIGHT_CLASS_GIGANTIC
layer = ABOVE_HUD_LAYER
plane = ABOVE_HUD_PLANE
var/last_throw = 0
var/atom/movable/focus = null
@@ -82,11 +87,13 @@ var/const/tk_maxrange = 15
//stops TK grabs being equipped anywhere but into hands
/obj/item/tk_grab/equipped(mob/user, slot)
if( (slot == slot_l_hand) || (slot== slot_r_hand) )
if(slot == slot_hands)
return
qdel(src)
return
/obj/item/tk_grab/attack_hand(mob/user)
return
/obj/item/tk_grab/attack_self(mob/user)
if(!focus)
@@ -95,6 +102,7 @@ var/const/tk_maxrange = 15
qdel(src)
return
focus.attack_self_tk(user)
update_icon()
/obj/item/tk_grab/afterattack(atom/target, mob/living/carbon/user, proximity, params)//TODO: go over this
if(!target || !user)
@@ -131,11 +139,13 @@ var/const/tk_maxrange = 15
var/resolved = target.attackby(I, user, params)
if(!resolved && target && I)
I.afterattack(target,user,1) // for splashing with beakers
update_icon()
else
apply_focus_overlay()
focus.throw_at(target, 10, 1,user)
last_throw = world.time
user.changeNext_move(CLICK_CD_MELEE)
update_icon()
/proc/tkMaxRangeCheck(mob/user, atom/target, atom/focus)
var/d = get_dist(user, target)
@@ -165,17 +175,7 @@ var/const/tk_maxrange = 15
/obj/item/tk_grab/proc/apply_focus_overlay()
if(!focus)
return
var/obj/effect/overlay/O = new /obj/effect/overlay(locate(focus.x,focus.y,focus.z))
O.name = "sparkles"
O.anchored = 1
O.density = 0
O.layer = FLY_LAYER
O.setDir(pick(cardinal))
O.icon = 'icons/effects/effects.dmi'
O.icon_state = "nothing"
flick("empdisable",O)
spawn(5)
qdel(O)
new /obj/effect/overlay/temp/telekinesis(get_turf(focus))
/obj/item/tk_grab/update_icon()
@@ -185,7 +185,7 @@ var/const/tk_maxrange = 15
return
/obj/item/tk_grab/suicide_act(mob/user)
user.visible_message("<span class='suicide'>[user] is using \his telekinesis to choke \himself! It looks like \he's trying to commit suicide.</span>")
user.visible_message("<span class='suicide'>[user] is using [user.p_their()] telekinesis to choke [user.p_them()]self! It looks like [user.p_theyre()] trying to commit suicide!</span>")
return (OXYLOSS)
/*Not quite done likely needs to use something thats not get_step_to
@@ -213,4 +213,5 @@ var/const/tk_maxrange = 15
var/X = source:x
var/Y = source:y
var/Z = source:z
*/
*/