-
Notifications
You must be signed in to change notification settings - Fork 8
/
Copy pathMobs.dm
9540 lines (8469 loc) · 249 KB
/
Mobs.dm
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
mob
Bump(atom/a)
if(isobj(a))
var/obj/O = a
if(O.density && O.icon_state == "gate" && src.client == null && src.Humanoid)
if(O.Type != "Busy")
O.GateFunctions("Open")
if(O.density && O.Type == "Hole" && O.GoesTo)
src.overlays -= /obj/Misc/Swim/
src.InWater = 0
var/Fall = 100 - src.Agility
if(src.client == null && src.Humanoid)
Fall = 0
var/Falls = prob(Fall)
if(Falls)
view(6,src) << "<font color = yellow>[src] falls down a Hole!<br>"
src.Move(O.GoesTo)
src.overlays -= /obj/Misc/Bubbles/
src.overlays -= /obj/Misc/Swim/
src.InWater = 0
if(src.Dead == 0)
src.HitObject()
else
if(src.client == null)
view(6,src) << "<font color = yellow>[src] avoids the Hole!<br>"
src.Move(O.loc)
if(src.UnderTK)
if(a.density && a != src.LastHit)
src.LastHit = a
var/mob/M = src.UnderTK
view(6,src) << "<font color = red>[M] slams [src] into a [a]!"
M.Sleep -= 3
var/Dmg = M.Intelligence / 5
if(ismob(a))
var/mob/Z = a
if(Z.Stunned == 0)
var/Stun = prob(25)
if(Stun && Z.Fainted == 0)
Z.Stunned = 1
Z.CanMove = 0
Z.Stun()
view(6,src) << "<font color=red>[Z] has been stunned!<br>"
if(M.client)
if(M.client.eye != M)
M.Sleep -= 5
if(src.Stunned == 0)
var/Stun = prob(25)
if(Stun && src.Fainted == 0)
src.Stunned = 1
src.CanMove = 0
src.Stun()
view(6,src) << "<font color=red>[src] has been stunned!<br>"
if(src.Humanoid)
if(src.Weapon)
var/Drop = prob(100 - src.Agility * 2)
if(Drop)
var/obj/I = src.Weapon
view(src) << "<font color = red>[src] loses hold of their [I]!<br>"
src.overlays-=image(I.icon,I.icon_state,I.ItemLayer)
I.Move(src.loc)
I.overlays = null
I.suffix = null
I.icon_state = I.CarryState
src.Weight -= I.Weight
src.Weapon = null
if(src.client)
src.client.screen -= I
if(I.Delete)
del(I)
if(src.Weapon2)
var/Drop = prob(100 - src.Agility * 2)
if(Drop)
var/obj/I = src.Weapon2
view(src) << "<font color = red>[src] loses hold of their [I]!<br>"
src.overlays-=image(I.icon,I.icon_state,I.ItemLayer)
src.overlays-=image(I.icon,"[I.icon_state] left",I.ItemLayer)
I.Move(src.loc)
I.overlays = null
I.suffix = null
I.icon_state = I.CarryState
src.Weight -= I.Weight
src.Weapon2 = null
if(src.client)
src.client.screen -= I
if(I.Delete)
del(I)
if(src.LeftLeg && src.Race != "Snakeman")
var/Harm = 33
if(src.WLeftFoot)
var/obj/O = src.WLeftFoot
Harm -= O.Defence
var/Harms = prob(Harm)
if(Harms)
src.Blood -= Dmg / 1.5
src.LeftLeg -= Dmg
if(src.LeftLeg <= 10)
src.LeftLeg = 10
src.AddGore("LeftLeg",src.Race)
src.Pain += Dmg / 2
src.Bleed()
view(6,src) << "<font color=red>[src]'s Left Leg is hurt!"
if(src.RightLeg && src.Race != "Snakeman")
var/Harm = 33
if(src.WRightFoot)
var/obj/O = src.WRightFoot
Harm -= O.Defence
var/Harms = prob(Harm)
if(Harms)
src.Blood -= Dmg / 1.5
src.RightLeg -= Dmg
if(src.RightLeg <= 10)
src.RightLeg = 10
src.AddGore("RightLeg",src.Race)
src.Pain += Dmg / 2
src.Bleed()
view(6,src) << "<font color=red>[src]'s Right Leg is hurt!"
if(src.LeftArm)
var/Harm = 33
if(src.WLeftHand)
var/obj/O = src.WLeftHand
Harm -= O.Defence
var/Harms = prob(Harm)
if(Harms)
src.Blood -= Dmg / 1.5
src.LeftArm -= Dmg
if(src.LeftArm <= 10)
src.LeftArm = 10
src.AddGore("LeftArm",src.Race)
src.Pain += Dmg / 2
src.Bleed()
view(6,src) << "<font color=red>[src]'s Left Arm is hurt!"
if(src.RightArm)
var/Harm = 33
if(src.WRightHand)
var/obj/O = src.WRightHand
Harm -= O.Defence
var/Harms = prob(Harm)
if(Harms)
src.Blood -= Dmg / 1.5
src.RightArm -= Dmg
if(src.RightArm <= 10)
src.RightArm = 10
src.AddGore("RightArm",src.Race)
src.Pain += Dmg / 2
src.Bleed()
view(6,src) << "<font color=red>[src]'s Right Arm is hurt!"
else
var/Harm = prob(50)
if(Harm)
view(6,src) << "<font color=red>[src] is hurt by [M]'s powers!"
src.HP -= Dmg
src.Blood -= Dmg / 1.5
src.Pain += Dmg / 2
src.Bleed()
if(src.HP <= 0)
view(6,src) << "<font color=red>[src] has been killed by [src.UnderTK]!<br>"
src.Death()
M.overlays -= /obj/Misc/SpellEffects/Dispel
if(src.client && usr.Function == "Pull")
if(ismob(a))
var/mob/M = a
if(M.client && M.suffix == null && M.Sleeping == 0)
step(M,src.dir)
if(M.Owner == usr)
step(M,src.dir)
if(isobj(a))
var/obj/O = a
if(O.suffix == null && O.Target == null)
step(O,src.dir)
if(isturf(a))
..()
if(src.client == null)
if(isobj(a))
var/obj/O = a
if(O.suffix == null)
step(O,src.dir)
if(O != src.Target)
step_rand(src)
if(isturf(a))
var/turf/T = a
if(T != src.Target)
step_rand(src)
if(ismob(a))
var/mob/M = a
if(M != src.Target)
step_rand(src)
Click()
if(src != usr)
if(usr.Function == "Examine")
if(usr.CanExamine)
var/CanSee = 0
if(usr.RightEye)
CanSee = 1
if(usr.LeftEye)
CanSee = 1
if(CanSee)
usr << "<font color = teal>You take a good look at [src].<br>"
for(var/obj/Items/Armour/Back/B in src)
if(B.Type == "Conceals" && B.suffix == "Equip")
usr << "<font color = teal>[src] appears to be wearing a [B], so you've little idea what else they might be wearing."
return
for(var/obj/Items/Armour/A in src)
if(A.suffix == "Equip")
usr << "<font color = teal>[src] appears to be wearing a [A]."
for(var/obj/Items/Weapons/W in src)
if(W.suffix == "Equip")
usr << "<font color = teal>[src] appears to be holding a [W]."
if(src.Bleed)
var/ChanceBlood = 0 + usr.Intelligence * 2 + usr.FirstAidSkill
var/ChanceToSpotBlood = 0
ChanceToSpotBlood = prob(ChanceBlood)
if(ChanceToSpotBlood)
usr << "<font color = red><br>[src] appears to be [src.Bleed] bleeding.<br>"
if(ChanceToSpotBlood == 0)
usr << "<font color = red><br>[src] appears to be bleeding, but your not sure how bad<br>"
var/ChanceStr = 0
var/StrMsg = null
ChanceStr = prob(usr.Intelligence * 3)
if(ChanceStr)
if(src.Strength <= usr.Strength / 1.1)
StrMsg = "<font color = blue><br>[src] looks a tiny bit weaker than you.<br>"
if(src.Strength <= usr.Strength / 1.2)
StrMsg = "<font color = blue><br>[src] looks a little weaker than you.<br>"
if(src.Strength <= usr.Strength / 1.5)
StrMsg = "<font color = blue><br>[src] looks alot weaker than you.<br>"
if(src.Strength <= usr.Strength / 2)
StrMsg = "<font color = blue><br>[src] looks terribly weaker than you.<br>"
if(src.Strength <= usr.Strength / 3)
StrMsg = "<font color = blue><br>[src] looks pathetic compared to your strength.<br>"
if(usr.Strength <= src.Strength / 1.1)
StrMsg = "<font color = blue><br>[src] looks a tiny bit stronger than you.<br>"
if(usr.Strength <= src.Strength / 1.2)
StrMsg = "<font color = blue><br>[src] looks a little bit stronger than you.<br>"
if(usr.Strength <= src.Strength / 1.5)
StrMsg = "<font color = blue><br>[src] looks a alot stronger than you.<br>"
if(usr.Strength <= src.Strength / 2)
StrMsg = "<font color = blue><br>[src] looks immensely stronger than you.<br>"
if(usr.Strength <= src.Strength / 3)
StrMsg = "<font color = blue><br>[src] looks mighty compared to your strength.<br>"
usr << "[StrMsg]"
else
usr << "<font color = blue><br>Your not sure how strong [src] is compared to you.<br>"
var/ChanceEnd = 0
var/EndMsg = null
ChanceEnd = prob(usr.Intelligence * 3)
if(ChanceEnd)
if(src.Endurance <= usr.Endurance / 1.1)
EndMsg = "<font color = blue><br>[src] looks a tiny bit less endurant than you.<br>"
if(src.Endurance <= usr.Endurance / 1.2)
EndMsg = "<font color = blue><br>[src] looks a little less endurant than you.<br>"
if(src.Endurance <= usr.Endurance / 1.5)
EndMsg = "<font color = blue><br>[src] looks alot less endurant than you.<br>"
if(src.Endurance <= usr.Endurance / 2)
EndMsg = "<font color = blue><br>[src] looks terribly less endurant than you.<br>"
if(src.Endurance <= usr.Endurance / 3)
EndMsg = "<font color = blue><br>[src] looks flimsy compared to your endurance.<br>"
if(usr.Endurance <= src.Endurance / 1.1)
EndMsg = "<font color = blue><br>[src] looks a tiny bit more endurant than you.<br>"
if(usr.Endurance <= src.Endurance / 1.2)
EndMsg = "<font color = blue><br>[src] looks a little bit more endurant than you.<br>"
if(usr.Endurance <= src.Endurance / 1.5)
EndMsg = "<font color = blue><br>[src] looks a alot more endurant than you.<br>"
if(usr.Endurance <= src.Endurance / 2)
EndMsg = "<font color = blue><br>[src] looks immensely more endurant than you.<br>"
if(usr.Endurance <= src.Endurance / 3)
EndMsg = "<font color = blue><br>[src] looks as tough as a mountain compared to your endurance.<br>"
usr << "[EndMsg]"
else
usr << "<font color = blue><br>Your not sure how endurant [src] is compared to you.<br>"
var/ChanceAgil = 0
var/AgilMsg = null
ChanceAgil = prob(usr.Intelligence * 3)
if(ChanceAgil)
if(src.Agility <= usr.Agility / 1.1)
AgilMsg = "<font color = blue><br>[src] looks a tiny bit less agile than you.<br>"
if(src.Agility <= usr.Agility / 1.2)
AgilMsg = "<font color = blue><br>[src] looks a little less agile than you.<br>"
if(src.Agility <= usr.Agility / 1.5)
AgilMsg = "<font color = blue><br>[src] looks alot less agile than you.<br>"
if(src.Agility <= usr.Agility / 2)
AgilMsg = "<font color = blue><br>[src] looks terribly less agile than you.<br>"
if(src.Agility <= usr.Agility / 3)
AgilMsg = "<font color = blue><br>[src] looks slow compared to your agility.<br>"
if(usr.Agility <= src.Agility / 1.1)
AgilMsg = "<font color = blue><br>[src] looks a tiny bit more agile than you.<br>"
if(usr.Agility <= src.Agility / 1.2)
AgilMsg = "<font color = blue><br>[src] looks a little bit more agile than you.<br>"
if(usr.Agility <= src.Agility / 1.5)
AgilMsg = "<font color = blue><br>[src] looks a alot more agile than you.<br>"
if(usr.Agility <= src.Agility / 2)
AgilMsg = "<font color = blue><br>[src] looks immensely more agile than you.<br>"
if(usr.Agility <= src.Agility / 3)
AgilMsg = "<font color = blue><br>[src] looks super-agile compared to you.<br>"
usr << "[AgilMsg]"
else
usr << "<font color = blue><br>Your not sure how agile [src] is compared to you.<br>"
var/ChanceInt = 0
var/IntMsg = null
ChanceInt = prob(usr.Intelligence * 3)
if(ChanceInt)
if(src.Intelligence <= usr.Intelligence / 1.1)
IntMsg = "<font color = blue><br>[src] looks a tiny bit less intelligent than you.<br>"
if(src.Intelligence <= usr.Intelligence / 1.2)
IntMsg = "<font color = blue><br>[src] looks a little less intelligent than you.<br>"
if(src.Intelligence <= usr.Intelligence / 1.5)
IntMsg = "<font color = blue><br>[src] looks alot less intelligent than you.<br>"
if(src.Intelligence <= usr.Intelligence / 2)
IntMsg = "<font color = blue><br>[src] looks terribly less intelligent than you.<br>"
if(src.Intelligence <= usr.Intelligence / 3)
IntMsg = "<font color = blue><br>[src] looks stupid compared to your intelligence.<br>"
if(usr.Intelligence <= src.Intelligence / 1.1)
IntMsg = "<font color = blue><br>[src] looks a tiny bit more intelligent than you.<br>"
if(usr.Intelligence <= src.Intelligence / 1.2)
IntMsg = "<font color = blue><br>[src] looks a little bit more intelligent than you.<br>"
if(usr.Intelligence <= src.Intelligence / 1.5)
IntMsg = "<font color = blue><br>[src] looks a alot more intelligent than you.<br>"
if(usr.Intelligence <= src.Intelligence / 2)
IntMsg = "<font color = blue><br>[src] looks immensely more intelligent than you.<br>"
if(usr.Intelligence <= src.Intelligence / 3)
IntMsg = "<font color = blue><br>[src] looks like a Genius compared to your intelligence.<br>"
usr << "[IntMsg]"
else
usr << "<font color = blue><br>Your not sure how intelligent [src] is compared to you.<br>"
usr.CanExamine = 0
var/GainInt = prob(22 - usr.Intelligence / 3)
if(GainInt && usr.Intelligence <= usr.IntCap && usr.Intelligence <= WorldIntCap && usr.Intelligence <= usr.IntelligenceMax)
usr.Intelligence += usr.IntelligenceMulti / 4
spawn(100)
if(usr)
usr.CanExamine = 1
return
else
usr << "<font color = blue>Must wait a little while before Examining again.<br>"
return
if(usr.Function == "Combat")
var/Display = 1
if(usr.Target)
if(usr.Target == src)
Display = 0
var/mob/m = usr.Target
usr.client.images -= m.TargetIcon
if(usr.Target != src)
usr.Target = src
if(usr.name != "Unknown")
src.HateList += usr.name
usr << "<b>You target [src]!<br>"
for(var/mob/M in view(usr))
if(M.Race == src.Race && M.Target == null && M.client == null && usr.Race == src.Race)
var/NotEnemy = 1
if(src.Faction in M.HateList)
NotEnemy = 0
if(NotEnemy == 1)
M.Target = usr
if(usr.name != "Unknown")
M.HateList += usr.name
if(src.client && Display)
view(usr) << "<font color = yellow> ([usr.OrginalName])[usr] readies for combat while facing in [src]'s direction!<br>"
if(src.client)
usr.Log_player("([usr.key])[usr] - [usr.OrginalName] Targets [src] to Attack.")
usr.client.images += src.TargetIcon
if(usr.Function == "Pull")
if(src.Fainted)
if(src in range(1,usr))
if(usr.Pull == src)
usr.Pull = null
if(src.Pull == usr)
src.Pull = null
view(usr) << "<b>[usr] stops pulling [src]<br>"
return
if(src.suffix == null)
if(usr.Pull == null)
usr.Pull = src
src.Pull = usr
usr.Pull()
view(usr) << "<b>[usr] starts pulling [src]<br>"
return
if(usr.Function == "Interact" && usr.Ref)
var/obj/O = usr.Ref
if(O in usr)
if(O.Dura >= 1 && usr.Job == null && O.suffix == "Equip" && src == usr && O.ObjectType == "Dagger" && usr.Hair && O.Type == "CutsHair")
view(usr) << "<font color = yellow>[usr] cuts their hair!<br>"
usr.overlays -= usr.Hair
usr.Hair = null
if(usr.Gender == "Female")
var/obj/Misc/Hairs/Long/H = new
usr.Hair = H
if(usr.WHead == null)
usr.overlays += usr.Hair
return
if(O.Dura >= 1 && usr.Job == null && O.suffix == "Equip" && src == usr && O.ObjectType == "Dagger" && usr.Beard)
if(usr.Race == "Stahlite")
usr << "<font color = red>Your character would rather die a thousand painful deaths than shave his own beard off, shame on you...<br>"
return
view(usr) << "<font color = yellow>[usr] shaves their beard off using a [O]!<br>"
usr.overlays -= usr.Beard
usr.Beard = null
return
if(src in range(1,usr))
if(usr.Function == "Interact" && usr.Ref == null && src.client == null)
if(usr.name in src.HateList)
if(usr.Faction == src.Faction)
var/CanPay = 0
for(var/obj/Items/Currency/GoldCoin/C in usr)
if(C.Type >= 9)
CanPay = 1
var/CoinsAlready = 0
for(var/obj/Items/Currency/GoldCoin/G in src)
CoinsAlready = 1
if(CoinsAlready == 0)
var/obj/Items/Currency/GoldCoin/G = new
G.Type = 10
C.Type -= 10
G.CoinAdjust()
C.CoinAdjust()
G.Move(src)
G.suffix = "Carried"
G.name = "[G.Type] Gold Coins"
C.name = "[C.Type] Gold Coins"
else
for(var/obj/Items/Currency/GoldCoin/G in src)
G.Type += 10
C.Type -= 10
G.CoinAdjust()
C.CoinAdjust()
C.name = "[C.Type] Gold Coins"
G.name = "[G.Type] Gold Coins"
if(C.Type <= 0)
del(C)
if(CanPay)
hearers(8,usr) << "<font color = yellow>[usr] pays [src] a fee of ten Gold Coins as part of a fine.<br>"
src.HateList -= usr.name
if(src.Target == usr)
src.Target = null
if(usr.Target == src)
usr.Target = null
return
else
usr << "<font color = red>You dont have enough coins to pay off your fine!<br>"
return
if(usr.Function == "Interact" && usr.Ref == null && src.client)
if(src != usr)
if(usr in range(1,src))
if(src.Age <= 10 && usr.Age <= 10)
range(8,usr) << "<font color = yellow>([usr.OrginalName])[usr] Asks [src], a [src.Age] year old [src.Gender], to Mate. But they are both far too young!<br>"
usr << "<font color = teal>[src] and you, must be at least 11 to Mate!<br>"
return
if(src.Age <= 10)
range(8,usr) << "<font color = yellow>([usr.OrginalName])[usr] Asks [src], a [src.Age] year old [src.Gender], to Mate. But [src] is far too young!<br>"
usr << "<font color = teal>[src] must be at least 11 to Mate!<br>"
return
if(usr.Age <= 10)
range(8,usr) << "<font color = yellow>([usr.OrginalName])[usr] Asks [src], a [src.Age] year old [src.Gender], to Mate. But [src] is far too young!<br>"
usr << "<font color = teal>[src] must be at least 11 to Mate!<br>"
return
var/Mate = 0
if(src.Gender == "Male" && usr.Gender == "Female" && usr.PregType == "Womb")
Mate = 1
if(src.Gender == "Female" && usr.Gender == "Male" && src.PregType == "Womb")
Mate = 1
if(Mate && src.client)
var/list/menu = new()
menu += "Yes"
menu += "No"
var/Result = input(src,"([usr.OrginalName])[usr] has offered to Mate with you, do you accept?", "Choose", null) in menu
if(Result == "Yes")
range(8,usr) << "<font color = yellow>[src] accepts [usr] in their offer to Mate, and....off they go.<br>"
if(usr.Gender == "Female" && usr.Preg == 0)
if(usr.PregType == "Womb")
usr.Preg = 2
else
if(usr.Race == "Frogman")
var/mob/NPC/Misc/FrogEgg/E = new
Players += E
E.Move(usr.loc)
E.FatherStrength = src.Strength / 8
E.FatherAgility = src.Agility / 8
E.FatherEndurance = src.Endurance / 8
E.Strength += usr.Strength / 8
E.Endurance += usr.Endurance / 8
E.Agility += usr.Agility / 8
E.Preg = 2
if(usr.Race == "Snakeman")
var/mob/NPC/Misc/SnakeEgg/E = new
Players += E
E.Move(usr.loc)
E.FatherStrength = src.Strength / 8
E.FatherAgility = src.Agility / 8
E.FatherEndurance = src.Endurance / 8
E.Strength += usr.Strength / 8
E.Endurance += usr.Endurance / 8
E.Agility += usr.Agility / 8
E.Preg = 2
usr.Preg = 3
usr.BirthTimer()
usr.FatherStrength = src.Strength / 8
usr.FatherAgility = src.Agility / 8
usr.FatherEndurance = src.Endurance / 8
return
if(src.Gender == "Female" && src.Preg == 0 && src.client)
if(src.PregType == "Womb")
src.Preg = 2
else
if(src.Race == "Frogman")
var/mob/NPC/Misc/FrogEgg/E = new
Players += E
E.Move(usr.loc)
E.FatherStrength = usr.Strength / 8
E.FatherAgility = usr.Agility / 8
E.FatherEndurance = usr.Endurance / 8
E.Strength += src.Strength / 8
E.Endurance += src.Endurance / 8
E.Agility += src.Agility / 8
E.Preg = 2
if(src.Race == "Snakeman")
var/mob/NPC/Misc/SnakeEgg/E = new
Players += E
E.Move(usr.loc)
E.FatherStrength = usr.Strength / 8
E.FatherAgility = usr.Agility / 8
E.FatherEndurance = usr.Endurance / 8
E.Strength += src.Strength / 8
E.Endurance += src.Endurance / 8
E.Agility += src.Agility / 8
E.Preg = 2
src.Preg = 3
src.BirthTimer()
src.FatherStrength = usr.Strength / 8
src.FatherAgility = usr.Agility / 8
src.FatherEndurance = usr.Endurance / 8
return
if(Result == "No")
range(8,usr) << "<font color = yellow>[usr] Asked [src] to Mate, but sadly, was rejected.<br>"
return
else
range(8,usr) << "<font color = yellow>[usr] asked to Mate with [src], but [src] was either the same sex as them, or reproduced in a different way.<br>"
return
NPC
Fuel = 100
Misc
NewBorn
FrogEgg
icon = 'misc.dmi'
icon_state = "frog egg"
Race = "Frogman"
density = 0
SnakeEgg
icon = 'misc.dmi'
icon_state = "snake egg"
Race = "Snakeman"
density = 0
Good
Human_Merchant
icon = 'human.dmi'
icon_state = "N"
Type = "Merchant"
name = "{NPC} Merchant"
Race = "Human"
Head = 110
Torso = 110
LeftArm = 110
RightArm = 110
LeftLeg = 110
RightLeg = 110
Skull = 110
Brain = 110
LeftEye = 110
RightEye = 110
LeftEar = 110
RightEar = 110
Teeth = 110
Nose = 110
Tongue = 110
Throat = 110
Heart = 110
LeftLung = 110
RightLung = 110
Spleen = 110
Intestine = 110
LeftKidney = 110
RightKidney = 110
Liver = 110
Bladder = 110
Stomach = 110
Strength = 25
Agility = 25
Endurance = 25
Intelligence = 25
StrengthMulti = 0.2
AgilityMulti = 0.2
EnduranceMulti = 0.2
IntelligenceMulti = 0.2
SwordSkill = 25
AxeSkill = 25
SpearSkill = 25
BluntSkill = 25
RangedSkill = 25
DaggerSkill = 25
UnarmedSkill = 25
SwordSkillMulti = 0.3
AxeSkillMulti = 0.3
SpearSkillMulti = 0.3
BluntSkillMulti = 0.3
RangedSkillMulti = 0.3
DaggerSkillMulti = 0.3
UnarmedSkillMulti = 0.3
Blood = 110
BloodMax = 110
BloodColour = /obj/Misc/Gore/BloodSplat/
BloodWallColour = /obj/Misc/Gore/WallBloodSplat/
Faction = "Human Empire"
HateList = list("Illithid Cultists","Lizardman Tribes","Gremlin Hordes","Kobold Hordes","Dragons","Undead","Chaos","Demonic Legions","Dangerous Beasts","Ratling Hordes","Cyclops Hordes","Goblin Hordes","Spider Hordes")
Click()
if(usr.Function == "Interact" && src in range(2,usr))
if(usr.Faction in src.HateList)
return
if(usr.name in src.HateList)
return
var/CanUnderstand = 0
var/obj/Speaking = null
if(usr.CurrentLanguage)
Speaking = usr.CurrentLanguage
for(var/obj/L in src.LangKnow)
if(L.name == Speaking.name)
if(L.SpeakPercent > Speaking.SpeakPercent / 1.5)
CanUnderstand = 1
src.CurrentLanguage = usr.CurrentLanguage
if(CanUnderstand)
src.Speak("Greetings and welcome to my shop!",7)
for(var/obj/I in usr)
if(I in src.Selling)
var/Val = 1
if(I.Material == "Wood")
Val += 1
if(I.Material == "Stone")
Val += 1
if(I.Material == "Iron")
Val += 10
if(I.Material == "Copper")
Val += 5
if(I.Material == "Silver")
Val += 15
if(I.Material == "Gold")
Val += 20
if(I.Quality)
Val += I.Quality / 1.5
if(I.Defence)
Val += I.Defence / 2
var/RoundedVal = round(Val)
src.Speak("Ah, I see you've chosen a [I], a fine choice indeed! That item has a total Value of about [RoundedVal] Gold Coins.",7)
var/list/menu = new()
menu += "Buy"
menu += "Dont Buy"
var/Result = input(usr,"[src] says - Would you like to purchase the [I] for [RoundedVal] Gold Coins?", "Choose", null) in menu
if(Result == "Dont Buy")
return
if(Result == "Buy")
for(var/obj/Items/Currency/GoldCoin/Gold in usr)
if(Gold.Type >= RoundedVal)
var/CoinsAlready = 0
for(var/obj/Items/Currency/GoldCoin/C in src)
CoinsAlready = 1
if(CoinsAlready == 0)
var/obj/Items/Currency/GoldCoin/Coin = new
Coin.Type = RoundedVal
Gold.Type -= RoundedVal
Coin.CoinAdjust()
Gold.CoinAdjust()
Gold.Move(src)
Coin.suffix = "Carried"
Coin.name = "[Coin.Type] Gold Coins"
Gold.name = "[Gold.Type] Gold Coins"
else
for(var/obj/Items/Currency/GoldCoin/Coin in src)
Coin.Type += RoundedVal
Gold.Type -= RoundedVal
Coin.CoinAdjust()
Gold.CoinAdjust()
Gold.name = "[Gold.Type] Gold Coins"
Coin.name = "[Coin.Type] Gold Coins"
if(Gold.Type == 0)
del(Gold)
usr.DeleteInventoryMenu()
if(usr.InvenUp)
usr.CreateInventory()
src.Selling -= I
if(I.ObjectTag == "Weapon")
I.CanBeCrafted = 1
if(I.ObjectTag == "Armour")
I.CanBeCrafted = 1
src.Speak("Thank you, come again!.",7)
else
src.Speak("You dont have [RoundedVal] Gold Coins so you cant buy the [I].",7)
else
usr << "<font color = yellow>[src] seems to have no idea what your saying.<br>"
return
New()
spawn(10)
var/image/I = new('Target.dmi',src)
src.TargetIcon = I
src.DeadIcon = src.icon
src.Attack()
src.BloodFlow()
src.Regen()
var/Gen = rand(1,2)
if(Gen == 1)
src.Gender = "Male"
if(Gen == 2)
src.Gender = "Female"
src.icon = 'human(F).dmi'
src.GiveHair()
var/obj/Items/Armour/UpperBody/LeatherVest/V = new
src.WUpperBody = V
V.suffix = "Equip"
V.Move(src)
var/obj/Items/Armour/Legs/LeatherLeggings/LL = new
src.WLegs = LL
LL.suffix = "Equip"
LL.Move(src)
var/obj/Items/Armour/LeftFoot/LeatherBootLeft/LBL = new
src.WLeftFoot = LBL
LBL.suffix = "Equip"
LBL.Move(src)
var/obj/Items/Armour/RightFoot/LeatherBootRight/LBR = new
src.WRightFoot = LBR
LBR.suffix = "Equip"
LBR.Move(src)
var/obj/Items/Armour/LeftArm/LeatherGloveLeft/LGL = new
src.WLeftHand = LGL
LGL.suffix = "Equip"
LGL.Move(src)
var/obj/Items/Armour/RightArm/LeatherGloveRight/LGR = new
src.WRightHand = LGR
LGR.suffix = "Equip"
LGR.Move(src)
for(var/obj/Items/Z in src)
Z.Dura = 100
Z.icon_state = Z.EquipState
Z.layer = Z.ItemLayer
src.overlays+=image(LGR.icon,LGR.icon_state,LGR.ItemLayer)
src.overlays+=image(LGL.icon,LGL.icon_state,LGL.ItemLayer)
src.overlays+=image(LBR.icon,LBR.icon_state,LBR.ItemLayer)
src.overlays+=image(LBL.icon,LBL.icon_state,LBL.ItemLayer)
src.overlays+=image(LL.icon,LL.icon_state,LL.ItemLayer)
src.overlays+=image(V.icon,V.icon_state,V.ItemLayer)
src.GiveRaceLanguages()
src.Selling = list()
for(var/obj/Items/It in oview(7,src))
var/Add = 1
if(It in src.Selling)
Add = 0
if(Add)
src.Selling += It
Human_Villager_Black
icon = 'human black.dmi'
icon_state = "N"
Type = "Town"
Race = "Human"
Head = 110
Torso = 110
LeftArm = 110
RightArm = 110
LeftLeg = 110
RightLeg = 110
Skull = 110
Brain = 110
LeftEye = 110
RightEye = 110
LeftEar = 110
RightEar = 110
Teeth = 110
Nose = 110
Tongue = 110
Throat = 110
Heart = 110
LeftLung = 110
RightLung = 110
Spleen = 110
Intestine = 110
LeftKidney = 110
RightKidney = 110
Liver = 110
Bladder = 110
Stomach = 110
Strength = 8
Agility = 8
Endurance = 8
Intelligence = 6
StrengthMulti = 0.3
AgilityMulti = 0.3
EnduranceMulti = 0.3
IntelligenceMulti = 0.2
SwordSkill = 10
AxeSkill = 5
SpearSkill = 5
BluntSkill = 5
RangedSkill = 5
DaggerSkill = 5
UnarmedSkill = 5
SwordSkillMulti = 0.5
AxeSkillMulti = 0.3
SpearSkillMulti = 0.3
BluntSkillMulti = 0.3
RangedSkillMulti = 0.3
DaggerSkillMulti = 0.3
UnarmedSkillMulti = 0.3
Blood = 110
BloodMax = 110
BloodColour = /obj/Misc/Gore/BloodSplat/
BloodWallColour = /obj/Misc/Gore/WallBloodSplat/
Faction = "Human Empire"
HateList = list("Illithid Cultists","Lizardman Tribes","Gremlin Hordes","Kobold Hordes","Dragons","Undead","Chaos","Demonic Legions","Dangerous Beasts","Ratling Hordes","Cyclops Hordes","Goblin Hordes","Spider Hordes")
New()
var/image/I = new('Target.dmi',src)
src.TargetIcon = I
src.DeadIcon = src.icon
src.Attack()
src.BloodFlow()
src.Regen()
src.AnimalAI()
src.GiveName()
var/Gen = rand(1,2)
if(Gen == 1)
src.Gender = "Male"
if(Gen == 2)
src.Gender = "Female"
src.icon = 'human black(F).dmi'
src.GiveHair()
var/obj/Items/Armour/Chest/DesertRobe/LV = new
src.WChest = LV
LV.suffix = "Equip"
LV.Move(src)
var/obj/Items/Armour/Legs/LeatherLeggings/LL = new
src.WLegs = LL
LL.suffix = "Equip"
LL.Move(src)
var/obj/Items/Armour/LeftFoot/LeatherBootLeft/LBL = new
src.WLeftFoot = LBL
LBL.suffix = "Equip"
LBL.Move(src)
var/obj/Items/Armour/RightFoot/LeatherBootRight/LBR = new
src.WRightFoot = LBR
LBR.suffix = "Equip"
LBR.Move(src)
var/obj/Items/Armour/LeftArm/LeatherGloveLeft/LGL = new
src.WLeftHand = LGL
LGL.suffix = "Equip"
LGL.Move(src)
var/obj/Items/Armour/RightArm/LeatherGloveRight/LGR = new
src.WRightHand = LGR
LGR.suffix = "Equip"
LGR.Move(src)
for(var/obj/Items/Z in src)
Z.Dura = 100
Z.icon_state = Z.EquipState
Z.layer = Z.ItemLayer
src.overlays+=image(LGR.icon,LGR.icon_state,LGR.ItemLayer)
src.overlays+=image(LGL.icon,LGL.icon_state,LGL.ItemLayer)
src.overlays+=image(LBR.icon,LBR.icon_state,LBR.ItemLayer)
src.overlays+=image(LBL.icon,LBL.icon_state,LBL.ItemLayer)
src.overlays+=image(LL.icon,LL.icon_state,LL.ItemLayer)
src.overlays+=image(LV.icon,LV.icon_state,LV.ItemLayer)
var/obj/Items/Currency/GoldCoin/Gold = new
Gold.Move(src)
Gold.suffix = "Carried"
Gold.Type = rand(2,5)
Gold.name = "[Gold.Type] Gold Coins"
Gold.CoinAdjust()
Human_Villager_Black
icon = 'human black.dmi'
icon_state = "N"
Type = "Town"
Race = "Human"
Head = 110
Torso = 110
LeftArm = 110
RightArm = 110
LeftLeg = 110
RightLeg = 110
Skull = 110
Brain = 110
LeftEye = 110
RightEye = 110
LeftEar = 110
RightEar = 110
Teeth = 110
Nose = 110
Tongue = 110
Throat = 110
Heart = 110
LeftLung = 110
RightLung = 110
Spleen = 110
Intestine = 110
LeftKidney = 110
RightKidney = 110
Liver = 110
Bladder = 110
Stomach = 110
Strength = 8
Agility = 8
Endurance = 8
Intelligence = 6
StrengthMulti = 0.3
AgilityMulti = 0.3
EnduranceMulti = 0.3
IntelligenceMulti = 0.2
SwordSkill = 10
AxeSkill = 5
SpearSkill = 5
BluntSkill = 5
RangedSkill = 5
DaggerSkill = 5
UnarmedSkill = 5
SwordSkillMulti = 0.5
AxeSkillMulti = 0.3
SpearSkillMulti = 0.3
BluntSkillMulti = 0.3
RangedSkillMulti = 0.3
DaggerSkillMulti = 0.3
UnarmedSkillMulti = 0.3
Blood = 110
BloodMax = 110
BloodColour = /obj/Misc/Gore/BloodSplat/
BloodWallColour = /obj/Misc/Gore/WallBloodSplat/
Faction = "Human Empire"
HateList = list("Illithid Cultists","Lizardman Tribes","Gremlin Hordes","Kobold Hordes","Dragons","Undead","Chaos","Demonic Legions","Dangerous Beasts","Ratling Hordes","Cyclops Hordes","Goblin Hordes","Spider Hordes")
New()
var/image/I = new('Target.dmi',src)
src.TargetIcon = I
src.DeadIcon = src.icon
src.Attack()
src.BloodFlow()
src.Regen()
src.AnimalAI()
src.GiveName()
var/Gen = rand(1,2)
if(Gen == 1)
src.Gender = "Male"
if(Gen == 2)
src.Gender = "Female"
src.icon = 'human black(F).dmi'
src.GiveHair()
var/obj/Items/Armour/Chest/DesertRobe/LV = new
src.WChest = LV
LV.suffix = "Equip"
LV.Move(src)
var/obj/Items/Armour/Legs/LeatherLeggings/LL = new
src.WLegs = LL
LL.suffix = "Equip"
LL.Move(src)
var/obj/Items/Armour/LeftFoot/LeatherBootLeft/LBL = new
src.WLeftFoot = LBL
LBL.suffix = "Equip"
LBL.Move(src)
var/obj/Items/Armour/RightFoot/LeatherBootRight/LBR = new
src.WRightFoot = LBR
LBR.suffix = "Equip"
LBR.Move(src)
var/obj/Items/Armour/LeftArm/LeatherGloveLeft/LGL = new
src.WLeftHand = LGL
LGL.suffix = "Equip"
LGL.Move(src)
var/obj/Items/Armour/RightArm/LeatherGloveRight/LGR = new
src.WRightHand = LGR
LGR.suffix = "Equip"
LGR.Move(src)
for(var/obj/Items/Z in src)
Z.Dura = 100
Z.icon_state = Z.EquipState