Advertisement
Guest User

New Pirate Code Commented

a guest
May 19th, 2019
103
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 5.77 KB | None | 0 0
  1. // Purpose of script is to change comms messages job indicator and words from english to pirate
  2. // written by xIAMTHELAWx
  3. // 19MAY2019
  4. // currently doesnt change message words to pirate words
  5.  
  6. def process_signal(sig) {
  7.  
  8. // load the word changing base into pword
  9. $pword = "ai/Navigator#are/argh#arrest/blow the man down#arrested/hung from the Yard Arm#ashwalker/native#ashwalkers/natives#assistant/scallywag#atmos/gunpowder#atmospherics/gunpowder#bar/Rum Wagon#bartender/grog master#bathroom/head#baton/cutlass#batonning/cutlassing#beepsky/Jack Ketch#blob/Terror of the Deep#bomb/ordnance#botanist/rum runner#botanists/rum runners#braindead/taking a caulk#bridge/Quarterdeck#brig/gangplank#brigged/was made to walk the plank#call/Oye!#captain/Cap'n#cash/booty#ce/chief sailmaker#chapel/scuttlebutt#chaplain/seadog#chef/galley cook#chefs/galley cooks#chemist/gunner#chemistry/gunners well#chemists/gunners#clean/swab#cleaning/swabbing#clone/show a leg#cloned/shown a leg#clown/Scurvy Dog#cmo/chief surgeon#come/git#cook/galley cook#cooks/galley cooks#credits/booty#crew/mateys#crewmember/mate#curator/bookey#dead/at davy jones locker#detective/snitch#die/go to davy jones locker#dieing/going to davy jones locker#disease/scurvy#doc/Surgeon#docs/surgeons#doctor/surgeon#doctors/surgeons#door/hatch#dude/lad#engi/Sailmaker#engie/Sailmaker#engine/sails#engineer/sailmaker#engineering/Main Mast#engineers/sailmakers#escape/the poop deck#execute/keelhaul#executed/keelhauled#fix/overhaul#fixed/overhauled#floor/deck#food/grub#friend/matey#genetecist/Ol Cranky#genetecists/Ol Crankys#get/git#girl/lassie#gun/blunderbuss#guy/lad#hallway/passageway#harm-batoned/ran me through with a Cutlass#harm-batonning/running me through with a Cutlass#heaven/davy jones' locker#hello/Ahoy Matey!#hello/Yo Ho Ho#help/Blimey pick me up!#hey/Arr!#hi/Yo Ho Ho#hit/flog#hitting/floggin#hop/Crewmaster#hos/first mate#hydro/distillery#hydroponics/distillery#i/aye#is/ish#janitor/swabber#janitors/swabbers#kill/run em through#kitchen/galley#laser/blunderbuss#law/pirates code#law2/Ye Gotta#lawyer/Hornswaggler#library/Gamblin Den#lie/gundeck#lieing/gundecking#lier/gundecker#ling/interloper#maintenance/bilge#medbay/Chop Shop#medical/Chop Shop#mime/shark bait#mine/pillage#miner/boatswain#minerals/booty#miners/boatswains#mining/Jacob's Ladder#money/treasure#mop/swab#mopping/swabbing#my/meh#ninja/privateer#operative/Sail Ho!#operatives/Sails Ho!#order/pillage#paramedic/boarder#paramedics/boarders#plasma/gunpowder#psychiatrist/Ol Kooky#qm/Quartermaster#quiet/becalmed#rd/chief gunners mate#release/parley#released/parleyed#rev/mutineer#revolution/mutiny#revs/mutineers#robotics/tinkerers workshop#robotocist/tinkerer#robotocists/tinkerers#scientist/gunners mate#scientists/gunners mates#sec/shore patrol#security/shore patrol#shuttle/Cockboat#shuttle/scuttle the ship#signal/lookout#sling/demon#slings/demons#slip/run a rig#slipped/ran a rig#slipping/running a rig#space/sea#spaced/marooned#station/Jolly Roger#steal/plunder#stealing/plundering#stole/plundered#stolen/plundered#stop/Avast!#stuff/booty#sure/aye#syndicate/british#syndicates/the British#taser/blunderbuss#tasered/blunderbussed#tcomms/Lookout Nest#telecomms/Lookouts Nest#this/tis#toilet/head#toilets/head#tourist/landlubber#toxin/gunpowder#toxins/gunwell#traitor/son of a biscuit eater#trick/run a rig#tricked/ran a rig#turret/cannon#turrets/cannons#valid/has a letter of marque#vault/booty#virologist/bilge rat#virus/scurvy#wall/bulkhead#wanted/a picaroon#warden/Ol Salty#wizard/scourge of the seven seas#woah/Blimey!#wow/shiver me timbers#yeah/yarh#yep/aye aye#yes/aye aye#you/ye#" ;
  10.  
  11. // load the job changing base into pjob
  12. $pjob = "AI/Navigator#Assistant/Scallywag#Atmospheric Technician/Powder Monkey#Bartender/Grog Master#Botanist/Rum Runner#Captain/Cap'n#Cargo Technician/Cabin Boy#Chaplain/Seadog#Chef/Galley Cook#Chemist/Gunner#Chief Engineer/Chief Sailmaker#Chief Medical Officer/Chief Surgeon#Clown/Scurvy Dog#Cook/Galley Cook#Curator/Bookey#Detective/Snitch#Genetecist/Ol Cranky#Head of Personnel/Crewmaster#Head of Security/First Mate#Janitor/Swabber#Lawyer/Hornswaggler#Medical Doctor/Surgeon#Mime/Shark Bait#Paramedic/Boarder#Psychiatrist/Ol Kooky#Research Director/Chief Gunners Mate#Robotocist/Tinkerer#Scientist/Gunners Mate#Security Officer/Shore Patrol#Shaft Miner/Boatswain#Signal Technician/Lookout#Station Engineer/Sailmaker#Tourist/Landlubber#Virologist/Bilge rat#Warden/Ol Salty#" ;
  13.  
  14. sig.content = lower(sig.content) ;
  15.  
  16. // explode the message content into expsc array and set message change controllers to default
  17. $expsc = explode(sig.content, " ");
  18. $expscn = 1 ;
  19. $pwstop = 1 ;
  20. $pwordn = 1 ;
  21.  
  22. // explode pword string into the exppw array
  23. $exppw = explode($pword, "#") ;
  24.  
  25. // explode pjob string into the exppj array and set job change controllers to default
  26. $pjobn = 1 ;
  27. $pjobstop = 1 ;
  28. $exppj = explode($pjob, "#") ;
  29.  
  30. // job change loop, currently works just fine
  31. while($pjobn < length($exppj)) {
  32. $exppji = explode($exppj[$pjobn], "/") ;
  33. if($exppji[1] == sig.job ) {
  34. sig.job = $exppji[2] ;
  35. }
  36. $pjobn = $pjobn + 1 ;
  37. }
  38.  
  39. // word change loop, currently doesnt change the entries in expsc[$expscn] to pirate words
  40. while($expscn <= length($expsc)) {
  41. $exppwi = explode($exppw[$pwordn], "/") ;
  42. if($exppwi[1] == $expsc[$expscn]) {
  43. $expsc[$expscn] = $exppwi[2] ;
  44. $expscn = $expscn + 1 ;
  45. $pwordn = 1 ;
  46. }
  47. if($pwordn > length($exppw)) {
  48. $expscn = $expscn + 1 ;
  49. $pwordn = 1 ;
  50. }
  51. $pwordn = $pwordn + 1 ;
  52. }
  53.  
  54. // message content builder loop, currently builds out the original message
  55. $expscn = 1 ;
  56. $sp = " " ;
  57. sig.content = "" ;
  58. while($expscn <= length($expsc)) {
  59. sig.content = sig.content + $expsc[$expscn] + $sp ;
  60. $expscn = $expscn + 1 ;
  61. }
  62.  
  63.  
  64. // add job indicator and return content
  65. sig.source = sig.source + " (" + sig.job + ")" ;
  66. sig.content = proper(sig.content) ;
  67. return(sig);
  68. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement