ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/deliantra/maps/python/misc/CFInsulter.py
Revision: 1.1.1.1 (vendor branch)
Committed: Sun Feb 5 00:02:09 2006 UTC (18 years, 3 months ago) by root
Content type: text/x-python
Branch: UPSTREAM, MAIN
CVS Tags: post_fixaltar, last_stable, post_fixaltar2, rel-2_82, rel-2_81, rel-2_80, pre_coinconvert, UPSTREAM_2006_03_15, rel-3_0, rel-2_6, rel-2_7, rel-2_4, rel-2_5, rel-2_2, rel-2_0, rel-2_1, rel-2_72, rel-2_73, rel-2_71, rel-2_76, rel-2_77, rel-2_74, rel-2_75, rel-2_54, rel-2_55, rel-2_56, rel-2_79, UPSTREAM_2006_02_01, rel-2_53, pre_material_cfarch_normalize_run, rel-2_32, pre_fixconverter, post_coinconvert, pre_fixaltar2, pre_map_rename, UPSTREAM_2006_02_22, rel-2_90, rel-2_92, rel-2_93, rel-2_78, post_fixconverter, pre_fixaltar, rel-2_61, rel-2_43, rel-2_42, rel-2_41, HEAD
Changes since 1.1: +0 -0 lines
Log Message:
Initial Import

File Contents

# Content
1 # CFInsulter.py (formerly shakeinsult.py)
2 # This is an adaptation of Nick Hodges' Shakspearean Insult Generator in python.
3 #
4 # "This is available under a BSD style license. Once I said I would never
5 # write any non-GPL stuff for fun. Oh well. Just let me know if you use it."
6 # http://www.zope.org/Members/tfarrell/shakeinsult
7 #
8 #
9 # Adapted for use in Crossfire by Todd Mitchell
10 #
11 # Please help by adding new styles of insults to this fine script.
12
13 import Crossfire
14 from random import choice
15
16 def Insult(style):
17
18 ##SHAKESPEAR STYLE
19
20 if style == "shakespear":
21 adj1 = ['artless', 'bawdy', 'beslubbering', 'bootless', 'churlish', 'cockered', 'clouted', 'craven', 'currish', 'dankish', 'dissembling', 'droning', 'errant', 'fawning', 'fobbing', 'froward', 'frothy', 'gleeking', 'goatish', 'gorbellied', 'impertinent', 'infectious', 'jarring', 'loggerheaded', 'lumpish', 'mammering', 'mangled', 'mewling', 'paunchy', 'pribbling', 'puking', 'puny', 'qualling', 'rank', 'reeky', 'roguish', 'ruttish', 'saucy', 'spleeny', 'spongy', 'surly', 'tottering', 'unmuzzled', 'vain', 'venomed', 'villainous', 'warped', 'wayward', 'weedy', 'yeasty', 'vomiting', 'vulturous', 'contemptuous', 'groping', 'miniscule', 'quivering', 'shivering', 'trembling', 'miserable', 'licentious', 'cowering', 'sulking', 'gloating', 'murmuring', 'audacious', 'befouling', 'insolent', 'murky', 'pitiable', 'wretched', 'dolorous', 'lamentable', 'inadequate', 'contemptible', 'paltry', 'measly', 'meager', 'paltry', 'inadequate', 'insignificant', 'empty', 'inferior', 'pathetic', 'atrocious', 'execrable', 'damnable', 'repugnant', 'repulsive', 'revolting', 'repellent', 'offensive', 'disgusting', 'horrid', 'horrible', 'obscene', 'beastly', 'vile', 'abominable', 'pitiful', 'wrangled', 'whoring']
22 adj2 = ['base-court', 'bat-fowling', 'beef-witted', 'beetle-headed', 'boil-brained', 'clapper-clawed','clay-brained', 'common-kissing', 'crook-pated', 'dismal-dreaming', 'dizzy-eyed', 'doghearted', 'dread-bolted', 'earth-vexing', 'elf-skinned', 'fat-kidneyed', 'fen-sucked', 'flap-mouthed', 'fly-bitten', 'folly-fallen', 'fool-born', 'full-gorged', 'guts-griping', 'half-faced', 'hasty-witted', 'hedge-born', 'hell-hated', 'idle-headed', 'ill-breeding', 'ill-nurtured', 'knotty-pated', 'milk-livered', 'motley-minded', 'onion-eyed', 'plume-plucked', 'pottle-deep', 'pox-marked', 'reeling-ripe', 'rough-hewn', 'rude-growing', 'rump-fed', 'shard-borne', 'sheep-biting', 'spur-galled', 'swag-bellied', 'tardy-gaited', 'tickle-brained', 'toad-spotted', 'unchin-snouted', 'weather-bitten', 'weather-beaten', 'mutton-eating', 'coffee-nosed', 'malodorous']
23 noun = ['apple-john', 'baggage', 'barnacle', 'bladder', 'boar-pig', 'bugbear', 'bum-bailey', 'canker-blossom', 'clack-dish', 'clotpole', 'coxcomb', 'codpiece', 'death-token', 'dewberry', 'flap-dragon', 'flax-wench', 'flirt-gill', 'foot-licker', 'fustilarian', 'giglet', 'gudgeon', 'haggard', 'harpy', 'hedge-pig', 'horn-beast', 'hugger-mugger', 'joithead', 'lewdster', 'lout', 'maggot-pie', 'malt-worm', 'mammet', 'measle', 'minnow', 'miscreant', 'moldwarp', 'mumble-news', 'nut-hook', 'pigeon-egg', 'pignut', 'puttock', 'pumpion', 'ratsbane', 'scut', 'skainsmate', 'strumpet', 'varlet', 'vassal', 'whey-face', 'wagtail', 'phlegm-barrel', 'numb-skull', 'lip-infection', 'blood-clot', 'boar-tick', 'pervert']
24 prefixA = ['Thou art a','Thy Mother is a', 'Thou']
25 prefixAn = ['Thou art an', 'Thy Mother is an', 'Thou']
26
27 ##TEXAS STYLE
28
29 elif style == "texas":
30 adj1 = ['stewpid', 'uglee', 'pea brained', 'dung-headed', 'beady-eyed', 'hatless', 'witless', 'dumb']
31 adj2 = ['horse-knappin', 'hog-lickin', 'knock-kneed', 'jug-eared', 'pie-headed', 'snaggle-toothed', 'brown-nosed', 'lilly-livered' ]
32 noun = ['dipshit', 'city-slicker', 'root-head', 'cow-pie', 'greenhorn', 'idgit']
33 prefixA = ['Yer a','Yer Mama\'s a', 'Yew']
34 prefixAn = ['Yer an', 'Yer Mama\'s an', 'Yew']
35
36 ##DWARVEN STYLE
37
38 elif style == "dwarf":
39 adj1 = ['beardless', 'puny', 'shaven']
40 adj2 = ['elf-footed', 'dull-axed', 'tin-shielded' ]
41 noun = ['orc-lover', 'gobiln-kisser', 'tree-embracer']
42 prefixA = ['You are a','Your Matron\'s a', 'You']
43 prefixAn = ['You are an', 'Your Matron\'s an', 'You']
44
45 ##NO STYLE
46 else:
47 return "No such style stupid."
48
49 vowels = ['a', 'e', 'i', 'o', 'u']
50 isvowel = 0
51
52 rnoun = choice(noun)
53 radj1 = choice(adj1)
54 radj2 = choice(adj2)
55
56 for letter in vowels:
57 if (radj1[0] == letter):
58 rprefix = choice(prefixAn)
59 isvowel = 1
60 if (isvowel == 0):
61 rprefix = choice(prefixA)
62 insult = "%s %s %s %s!" % (rprefix, radj1, radj2, rnoun)
63 return insult
64
65
66 activator=Crossfire.WhoIsActivator()
67 whoami=Crossfire.WhoAmI()
68 #style of insult desired to hurl in event options
69 style = Crossfire.ScriptParameters() # 1 is apply event
70
71 activator.Write(Insult(style))