-Aliens can acid turf. The only turf they cannot acid are r_walls. I just used a typecheck because I didn't see the need for types of turf needing to be unacidable, but if so I'll make a variable for it.

-Made a proc which will select active candidates.

BALANCE STUFF

-Acid is less random.
-Humans being disarmed by Aliens is no longer a random duration, instead it is a constant 10, instead of the random 10 to 15.
-Facehugger throw range was reduced to 5.
-Laying eggs costs 75 plasma (from 50) and secreting resin costs 75 plasma (from 100).
-Reduced stun duration of Alien disarm to Cyborgs. From 10 to 7.

git-svn-id: http://tgstation13.googlecode.com/svn/trunk@4949 316c924e-a436-60f5-8080-3fe189b3f50e
This commit is contained in:
giacomand@gmail.com
2012-10-24 16:39:46 +00:00
parent 7b720a20b6
commit 28a04fbb9d
11 changed files with 92 additions and 56 deletions

View File

@@ -280,3 +280,32 @@ proc/isInSight(var/atom/A, var/atom/B)
if(M.ckey == lowertext(key))
return M
return null
// Will return a list of active candidates. It increases the buffer 5 times until it finds a candidate which is active within the buffer.
/proc/get_active_candidates(var/buffer = 1)
var/list/candidates = list() //List of candidate KEYS to assume control of the new larva ~Carn
var/i = 0
while(candidates.len <= 0 && i < 5)
for(var/mob/dead/observer/G in player_list)
if(((G.client.inactivity/10)/60) <= buffer + i) // the most active players are more likely to become an alien
if(!(G.mind && G.mind.current && G.mind.current.stat != DEAD))
candidates += G.key
i++
return candidates
// Same as above but for alien candidates.
/proc/get_alien_candidates()
var/list/candidates = list() //List of candidate KEYS to assume control of the new larva ~Carn
var/i = 0
while(candidates.len <= 0 && i < 5)
for(var/mob/dead/observer/G in player_list)
if(G.client.be_alien)
if(((G.client.inactivity/10)/60) <= ALIEN_SELECT_AFK_BUFFER + i) // the most active players are more likely to become an alien
if(!(G.mind && G.mind.current && G.mind.current.stat != DEAD))
candidates += G.key
i++
return candidates

View File

@@ -43,16 +43,7 @@
/datum/disease/alien_embryo/stage_act()
..()
switch(stage)
if(2)
if(prob(1))
affected_mob.emote("sneeze")
if(prob(1))
affected_mob.emote("cough")
if(prob(1))
affected_mob << "\red Your throat feels sore."
if(prob(1))
affected_mob << "\red Mucous runs down the back of your throat."
if(3)
if(2, 3)
if(prob(1))
affected_mob.emote("sneeze")
if(prob(1))
@@ -81,16 +72,7 @@
affected_mob.updatehealth()
if(prob(50))
if(gibbed != 0) return 0
var/list/candidates = list() //List of candidate KEYS to assume control of the new larva ~Carn
var/i = 0
while(candidates.len <= 0 && i < 5)
for(var/mob/dead/observer/G in player_list)
if(G.client.be_alien)
if(((G.client.inactivity/10)/60) <= ALIEN_SELECT_AFK_BUFFER + i) // the most active players are more likely to become an alien
if(!(G.mind && G.mind.current && G.mind.current.stat != DEAD))
candidates += G.key
i++
var/list/candidates = get_alien_candidates()
var/mob/living/carbon/alien/larva/new_xeno = new(affected_mob.loc)
if(candidates.len)
new_xeno.key = pick(candidates)

View File

@@ -269,17 +269,9 @@
if(temp_vent.network.normal_members.len > 50) // Stops Aliens getting stuck in small networks. See: Security, Virology
vents += temp_vent
var/list/candidates = list() //List of candidate KEYs to control the new larvae. ~Carn
var/i = 0
while(candidates.len <= 0 && i < 5)
for(var/mob/dead/observer/G in player_list)
if(G.client.be_alien)
if(((G.client.inactivity/10)/60) <= ALIEN_SELECT_AFK_BUFFER + i) // the most active players are more likely to become an alien
if(!(G.mind && G.mind.current && G.mind.current.stat != DEAD))
candidates += G.key
i++
var/list/candidates = get_alien_candidates()
if(prob(33)) spawncount++ //sometimes, have two larvae spawn instead of one
if(prob(40)) spawncount++ //sometimes, have two larvae spawn instead of one
while((spawncount >= 1) && vents.len && candidates.len)
var/obj/vent = pick(vents)

View File

@@ -299,24 +299,31 @@ Alien plants should do something if theres a lot of poison
opacity = 0
anchored = 1
var/obj/target
var/atom/target
var/ticks = 0
/obj/effect/alien/acid/proc/tick()
if(!target)
del(src)
ticks += 1
for(var/mob/O in hearers(src, null))
O.show_message("\green <B>[src.target] sizzles and begins to melt under the bubbling mess of acid!</B>", 1)
if(prob(ticks*10))
if(ticks >= 3)
for(var/mob/O in hearers(src, null))
O.show_message("\green <B>[src.target] collapses under its own weight into a puddle of goop and undigested debris!</B>", 1)
// if(target.occupant) //I tried to fix mechas-with-humans-getting-deleted. Made them unacidable for now.
// target.ex_act(1)
del(target)
if(istype(target, /turf/simulated/wall)) // I hate turf code.
var/turf/simulated/wall/W = target
W.dismantle_wall(1)
else
del(target)
del(src)
return
spawn(rand(200, 400)) tick()
spawn(rand(100, 150)) tick()
/*
* Egg

View File

@@ -80,25 +80,38 @@ Doesn't work on other aliens/AI.*/
The first proc defines the acid throw function while the other two work in the game itself. Probably a good idea to revise this later.
I kind of like the right click only--the window version can get a little confusing. Perhaps something telling the alien they need to right click?
/N*/
/obj/proc/acid(user as mob)
var/obj/effect/alien/acid/A = new(src.loc)
A.target = src
/proc/acid(user as mob, var/atom/O as obj|turf)
var/obj/effect/alien/acid/A = new(get_turf(O))
A.target = O
for(var/mob/M in viewers(src, null))
M.show_message(text("\green <B>[user] vomits globs of vile stuff all over [src]. It begins to sizzle and melt under the bubbling mess of acid!</B>"), 1)
M.show_message(text("\green <B>[user] vomits globs of vile stuff all over [O]. It begins to sizzle and melt under the bubbling mess of acid!</B>"), 1)
A.tick()
/mob/living/carbon/alien/humanoid/proc/corrosive_acid(obj/O as obj in oview(1)) //If they right click to corrode, an error will flash if its an invalid target./N
/mob/living/carbon/alien/humanoid/proc/corrosive_acid(O as obj|turf in oview(1)) //If they right click to corrode, an error will flash if its an invalid target./N
set name = "Corrossive Acid (200)"
set desc = "Drench an object in acid, destroying it over time."
set category = "Alien"
if(powerc(200))
if(O in oview(1))
if(O.unacidable) //So the aliens don't destroy energy fields/singularies/other aliens/etc with their acid.
src << "\green You cannot dissolve this object."
else
adjustToxLoss(-200)
O.acid(src)
// OBJ CHECK
if(isobj(O))
var/obj/I = O
if(I.unacidable) //So the aliens don't destroy energy fields/singularies/other aliens/etc with their acid.
src << "\green You cannot dissolve this object."
return
// TURF CHECK
else if(isturf(O))
var/turf/T = O
if(istype(T, /turf/simulated/wall/r_wall))
src << "\green You cannot dissolve this object."
return
else// Not a type we can acid.
return
adjustToxLoss(-200)
acid(src, O)
else
src << "\green Target is too far away."
return
@@ -143,14 +156,14 @@ I kind of like the right click only--the window version can get a little confusi
return
/mob/living/carbon/alien/humanoid/proc/resin() // -- TLE
set name = "Secrete Resin (100)"
set name = "Secrete Resin (75)"
set desc = "Secrete tough malleable resin."
set category = "Alien"
if(powerc(100))
if(powerc(75))
var/choice = input("Choose what you wish to shape.","Resin building") as null|anything in list("resin door","resin wall","resin membrane","resin nest") //would do it through typesof but then the player choice would have the type path and we don't want the internal workings to be exposed ICly - Urist
if(!choice || !powerc(100)) return
adjustToxLoss(-100)
if(!choice || !powerc(75)) return
adjustToxLoss(-75)
src << "\green You shape a [choice]."
for(var/mob/O in viewers(src, null))
O.show_message(text("\red <B>[src] vomits up a thick purple substance and begins to shape it!</B>"), 1)

View File

@@ -56,7 +56,7 @@
//Queen verbs
/mob/living/carbon/alien/humanoid/queen/verb/lay_egg()
set name = "Lay Egg (50)"
set name = "Lay Egg (75)"
set desc = "Lay an egg to produce huggers to impregnate prey with."
set category = "Alien"
@@ -64,8 +64,8 @@
src << "There's already an egg here."
return
if(powerc(50,1))//Can't plant eggs on spess tiles. That's silly.
adjustToxLoss(-50)
if(powerc(75,1))//Can't plant eggs on spess tiles. That's silly.
adjustToxLoss(-75)
for(var/mob/O in viewers(src, null))
O.show_message(text("\green <B>[src] has laid an egg!</B>"), 1)
new /obj/effect/alien/egg(loc)

View File

@@ -16,6 +16,7 @@ var/const/MAX_ACTIVE_TIME = 400
item_state = "facehugger"
w_class = 1 //note: can be picked up by aliens unlike most other items of w_class below 4
flags = FPRINT|TABLEPASS|MASKCOVERSMOUTH|MASKCOVERSEYES
throw_range = 5
var/stat = CONSCIOUS //UNCONSCIOUS is the idle state in this case

View File

@@ -49,7 +49,7 @@
var/randn = rand(1, 100)
if (randn <= 90)
playsound(loc, 'sound/weapons/pierce.ogg', 25, 1, -1)
Weaken(rand(10,15))
Weaken(10)
for(var/mob/O in viewers(src, null))
if ((O.client && !( O.blinded )))
O.show_message(text("\red <B>[] has tackled down []!</B>", M, src), 1)

View File

@@ -309,7 +309,7 @@
playsound(loc, 'sound/weapons/pierce.ogg', 25, 1, -1)
var/damage = 5
if(prob(95))
Weaken(rand(10,15))
Weaken(15)
for(var/mob/O in viewers(src, null))
if ((O.client && !( O.blinded )))
O.show_message(text("\red <B>[] has tackled down [name]!</B>", M), 1)

View File

@@ -623,7 +623,7 @@
if ("disarm")
if(!(lying))
if (rand(1,100) <= 85)
Stun(10)
Stun(7)
step(src,get_dir(M,src))
spawn(5) step(src,get_dir(M,src))
playsound(loc, 'sound/weapons/pierce.ogg', 50, 1, -1)

View File

@@ -48,6 +48,18 @@ Stuff which is in development and not yet visible to players or just code relate
should be listed in the changelog upon commit tho. Thanks. -->
<!-- To take advantage of the pretty new format (well it was new when I wrote this anyway), open the "add-to-changelog.html" file in any browser and add the stuff and then generate the html code and paste it here -->
<div class="commit sansserif">
<h2 class="date">24 October 2012</h2>
<h3 class="author">Giacom updated:</h3>
<ul class="changes bgimages16">
<li class="rscadd">Aliens can now acid walls and floors! Not R-Walls though.</li>
<li class="tweak">Facehugger throw range reduced to 5, so aim at humans that are 2 tiles apart from the edge of your screen.</li>
<li class="tweak">Making eggs is a little more expensive but secreting resin is cheaper. (Both cost 75 now)</li>
<li class="tweak">Aliens no longer have a random duration of stunning humans, it's a constant value now of the lower based value.</li>
<li class="tweak">Acid is less random and will be more reliable. Don't bother aciding stuff more than once, as it will waste plasma.</li>
</ul>
</div>
<div class="commit sansserif">
<h2 class="date">18 October 2012</h2>
<h3 class="author">Giacom updated:</h3>