From 12926decd2af8d0b34b632b2d0b55fc9aa134291 Mon Sep 17 00:00:00 2001 From: Yohann Ferreira Date: Thu, 30 Dec 2010 00:38:15 +0100 Subject: Added new example files needed to start a more complete feature-showing map. I also replaced certain files with newer version, just as the items.xml file. And I started to split test npcs from the tmwserv repository into reusable pieces. Big but trivial. Part of the Mana-Mantis issue: #231. --- example/clientdata/effects.xml | 29 +++ example/clientdata/emotes.xml | 101 ++++++++++ .../items/equipment/chest/chest-leathershirt.png | Bin 0 -> 684 bytes .../items/equipment/weapons/weapon-bow-bow.png | Bin 0 -> 666 bytes .../items/equipment/weapons/weapon-sword-sword.png | Bin 0 -> 827 bytes example/clientdata/graphics/items/unknown.png | Bin 0 -> 540 bytes .../graphics/items/usable/usable-candy.png | Bin 0 -> 562 bytes .../items/usable/usable-minor-health-potion.png | Bin 0 -> 311 bytes .../items/usable/usable-regenerative-trinket.png | Bin 0 -> 840 bytes .../items/usable/usable-token-of-speed.png | Bin 0 -> 1103 bytes .../clientdata/graphics/particles/arrow-down.png | Bin 0 -> 380 bytes .../clientdata/graphics/particles/arrow-hail.xml | 23 +++ .../graphics/particles/arrow.particle.xml | 14 ++ example/clientdata/graphics/particles/arrowh.png | Bin 0 -> 1372 bytes .../graphics/particles/attack.particle.xml | 60 ++++++ .../clientdata/graphics/particles/emotes/angel.png | Bin 0 -> 1960 bytes .../clientdata/graphics/particles/emotes/blah.png | Bin 0 -> 822 bytes .../clientdata/graphics/particles/emotes/blush.png | Bin 0 -> 2038 bytes .../graphics/particles/emotes/disgust.png | Bin 0 -> 1924 bytes .../particles/emotes/emote-angel.particle.xml | 23 +++ .../particles/emotes/emote-blah.particle.xml | 23 +++ .../particles/emotes/emote-blush.particle.xml | 23 +++ .../particles/emotes/emote-disgust.particle.xml | 23 +++ .../particles/emotes/emote-evil.particle.xml | 23 +++ .../particles/emotes/emote-grin.particle.xml | 23 +++ .../particles/emotes/emote-happy.particle.xml | 23 +++ .../particles/emotes/emote-perturbed.particle.xml | 23 +++ .../particles/emotes/emote-sad.particle.xml | 23 +++ .../particles/emotes/emote-speech.particle.xml | 23 +++ .../particles/emotes/emote-surprise.particle.xml | 23 +++ .../particles/emotes/emote-tongue.particle.xml | 23 +++ .../particles/emotes/emote-upset.particle.xml | 23 +++ .../particles/emotes/emote-wink.particle.xml | 23 +++ .../clientdata/graphics/particles/emotes/evil.png | Bin 0 -> 1925 bytes .../clientdata/graphics/particles/emotes/grin.png | Bin 0 -> 2047 bytes .../clientdata/graphics/particles/emotes/happy.png | Bin 0 -> 1734 bytes .../graphics/particles/emotes/perturbed.png | Bin 0 -> 1763 bytes .../clientdata/graphics/particles/emotes/sad.png | Bin 0 -> 1918 bytes .../graphics/particles/emotes/speech.png | Bin 0 -> 796 bytes .../graphics/particles/emotes/surprise.png | Bin 0 -> 2086 bytes .../graphics/particles/emotes/tongue.png | Bin 0 -> 1753 bytes .../clientdata/graphics/particles/emotes/upset.png | Bin 0 -> 1632 bytes .../clientdata/graphics/particles/emotes/wink.png | Bin 0 -> 1680 bytes .../graphics/particles/fullbubble-16px.png | Bin 0 -> 659 bytes .../graphics/particles/green-bubbles.particle.xml | 40 ++++ .../clientdata/graphics/particles/hit.particle.xml | 59 ++++++ .../graphics/particles/levelup.particle.xml | 23 +++ .../clientdata/graphics/particles/magic.white.xml | 24 +++ .../clientdata/graphics/particles/orb-medium.png | Bin 0 -> 320 bytes .../clientdata/graphics/particles/orb-small.png | Bin 0 -> 269 bytes .../graphics/particles/skillup.particle.xml | 23 +++ example/clientdata/graphics/particles/sparkle.png | Bin 0 -> 537 bytes .../clientdata/graphics/particles/star-medium.png | Bin 0 -> 965 bytes .../clientdata/graphics/particles/star-small.png | Bin 0 -> 387 bytes .../graphics/particles/warparea.particle.xml | 24 +++ example/clientdata/graphics/skills/axe.png | Bin 0 -> 1736 bytes example/clientdata/graphics/skills/bow.png | Bin 0 -> 1791 bytes example/clientdata/graphics/skills/knife.png | Bin 0 -> 1386 bytes example/clientdata/graphics/skills/mace.png | Bin 0 -> 1838 bytes example/clientdata/graphics/skills/magic.png | Bin 0 -> 540 bytes example/clientdata/graphics/skills/polearm.png | Bin 0 -> 1823 bytes example/clientdata/graphics/skills/shooting.png | Bin 0 -> 1853 bytes example/clientdata/graphics/skills/staff.png | Bin 0 -> 1308 bytes example/clientdata/graphics/skills/sword.png | Bin 0 -> 1641 bytes example/clientdata/graphics/skills/thrown.png | Bin 0 -> 1583 bytes example/clientdata/graphics/skills/unarmed.png | Bin 0 -> 2263 bytes example/clientdata/graphics/skills/unknown.png | Bin 0 -> 540 bytes example/clientdata/graphics/skills/whip.png | Bin 0 -> 2700 bytes .../equipment/chest/chest-leather-female.png | Bin 0 -> 11692 bytes .../equipment/chest/chest-leather-female.xml | 104 ++++++++++ .../sprites/equipment/chest/chest-leather-male.png | Bin 0 -> 19688 bytes .../sprites/equipment/chest/chest-leather-male.xml | 104 ++++++++++ example/clientdata/graphics/sprites/error.png | Bin 0 -> 347 bytes example/clientdata/graphics/sprites/error.xml | 10 + .../graphics/sprites/icons/icon-feather.png | Bin 0 -> 513 bytes .../graphics/sprites/icons/icon-feather.xml | 10 + .../graphics/sprites/icons/icon-poison.png | Bin 0 -> 1832 bytes .../graphics/sprites/icons/icon-poison.xml | 18 ++ .../graphics/sprites/monsters/monster-maggot.png | Bin 0 -> 4541 bytes .../graphics/sprites/monsters/monster-maggot.xml | 66 ++++++ .../graphics/sprites/monsters/monster-scorpion.png | Bin 0 -> 7855 bytes .../graphics/sprites/monsters/monster-scorpion.xml | 70 +++++++ .../graphics/sprites/monsters/monster-slime.png | Bin 0 -> 13722 bytes .../graphics/sprites/monsters/monster-slime.xml | 55 +++++ .../graphics/sprites/weapons/weapon-bow.png | Bin 0 -> 5751 bytes .../graphics/sprites/weapons/weapon-bow.xml | 26 +++ .../graphics/sprites/weapons/weapon-fist.xml | 7 + .../graphics/sprites/weapons/weapon-sword.png | Bin 0 -> 2016 bytes .../graphics/sprites/weapons/weapon-sword.xml | 27 +++ example/clientdata/hair.xml | 15 ++ example/clientdata/items.xml | 86 +++++++- example/clientdata/mana-skills.xml | 19 ++ example/clientdata/mana-status-effect.xml | 12 ++ example/clientdata/monsters.xml | 221 +++++++++++++++++++++ example/clientdata/paths.xml | 54 +++++ example/clientdata/sfx/fist-swish.ogg | Bin 0 -> 6723 bytes .../sfx/monsters/maggot/maggot-dying1.ogg | Bin 0 -> 17448 bytes .../clientdata/sfx/monsters/maggot/maggot-hit1.ogg | Bin 0 -> 19610 bytes .../clientdata/sfx/monsters/maggot/maggot-hit2.ogg | Bin 0 -> 15514 bytes .../sfx/monsters/maggot/maggot-miss1.ogg | Bin 0 -> 14317 bytes .../sfx/monsters/scorpion/scorpion-hit1.ogg | Bin 0 -> 6626 bytes .../sfx/monsters/scorpion/scorpion-hit2.ogg | Bin 0 -> 6486 bytes .../sfx/monsters/scorpion/scorpion-hit3.ogg | Bin 0 -> 6638 bytes .../sfx/monsters/scorpion/scorpion-hit4.ogg | Bin 0 -> 7410 bytes .../sfx/monsters/scorpion/scorpion-miss1.ogg | Bin 0 -> 6692 bytes .../clientdata/sfx/monsters/slime/slime-hit1.ogg | Bin 0 -> 12943 bytes example/clientdata/specials.xml | 8 + example/clientdata/units.xml | 7 + example/serverdata/scripts/global_events.lua | 41 +++- example/serverdata/scripts/items/candy.lua | 17 ++ example/serverdata/scripts/monster/testmonster.lua | 26 +++ example/serverdata/scripts/npcs/banker.lua | 74 +++++++ example/serverdata/scripts/npcs/barber.lua | 141 +++++++++++++ example/serverdata/scripts/npcs/debugger.lua | 101 ++++++++++ example/serverdata/scripts/npcs/emotemaker.lua | 46 +++++ example/serverdata/scripts/npcs/healer.lua | 23 +++ example/serverdata/scripts/npcs/postman.lua | 31 +++ example/serverdata/scripts/npcs/seller.lua | 73 +++++++ example/serverdata/scripts/status/jump.lua | 53 +++++ example/serverdata/scripts/status/plague.lua | 28 +++ 120 files changed, 2304 insertions(+), 11 deletions(-) create mode 100644 example/clientdata/effects.xml create mode 100644 example/clientdata/emotes.xml create mode 100644 example/clientdata/graphics/items/equipment/chest/chest-leathershirt.png create mode 100644 example/clientdata/graphics/items/equipment/weapons/weapon-bow-bow.png create mode 100644 example/clientdata/graphics/items/equipment/weapons/weapon-sword-sword.png create mode 100644 example/clientdata/graphics/items/unknown.png create mode 100644 example/clientdata/graphics/items/usable/usable-candy.png create mode 100644 example/clientdata/graphics/items/usable/usable-minor-health-potion.png create mode 100644 example/clientdata/graphics/items/usable/usable-regenerative-trinket.png create mode 100644 example/clientdata/graphics/items/usable/usable-token-of-speed.png create mode 100644 example/clientdata/graphics/particles/arrow-down.png create mode 100644 example/clientdata/graphics/particles/arrow-hail.xml create mode 100644 example/clientdata/graphics/particles/arrow.particle.xml create mode 100644 example/clientdata/graphics/particles/arrowh.png create mode 100644 example/clientdata/graphics/particles/attack.particle.xml create mode 100644 example/clientdata/graphics/particles/emotes/angel.png create mode 100644 example/clientdata/graphics/particles/emotes/blah.png create mode 100644 example/clientdata/graphics/particles/emotes/blush.png create mode 100644 example/clientdata/graphics/particles/emotes/disgust.png create mode 100644 example/clientdata/graphics/particles/emotes/emote-angel.particle.xml create mode 100644 example/clientdata/graphics/particles/emotes/emote-blah.particle.xml create mode 100644 example/clientdata/graphics/particles/emotes/emote-blush.particle.xml create mode 100644 example/clientdata/graphics/particles/emotes/emote-disgust.particle.xml create mode 100644 example/clientdata/graphics/particles/emotes/emote-evil.particle.xml create mode 100644 example/clientdata/graphics/particles/emotes/emote-grin.particle.xml create mode 100644 example/clientdata/graphics/particles/emotes/emote-happy.particle.xml create mode 100644 example/clientdata/graphics/particles/emotes/emote-perturbed.particle.xml create mode 100644 example/clientdata/graphics/particles/emotes/emote-sad.particle.xml create mode 100644 example/clientdata/graphics/particles/emotes/emote-speech.particle.xml create mode 100644 example/clientdata/graphics/particles/emotes/emote-surprise.particle.xml create mode 100644 example/clientdata/graphics/particles/emotes/emote-tongue.particle.xml create mode 100644 example/clientdata/graphics/particles/emotes/emote-upset.particle.xml create mode 100644 example/clientdata/graphics/particles/emotes/emote-wink.particle.xml create mode 100644 example/clientdata/graphics/particles/emotes/evil.png create mode 100644 example/clientdata/graphics/particles/emotes/grin.png create mode 100644 example/clientdata/graphics/particles/emotes/happy.png create mode 100644 example/clientdata/graphics/particles/emotes/perturbed.png create mode 100644 example/clientdata/graphics/particles/emotes/sad.png create mode 100644 example/clientdata/graphics/particles/emotes/speech.png create mode 100644 example/clientdata/graphics/particles/emotes/surprise.png create mode 100644 example/clientdata/graphics/particles/emotes/tongue.png create mode 100644 example/clientdata/graphics/particles/emotes/upset.png create mode 100644 example/clientdata/graphics/particles/emotes/wink.png create mode 100644 example/clientdata/graphics/particles/fullbubble-16px.png create mode 100644 example/clientdata/graphics/particles/green-bubbles.particle.xml create mode 100644 example/clientdata/graphics/particles/hit.particle.xml create mode 100644 example/clientdata/graphics/particles/levelup.particle.xml create mode 100644 example/clientdata/graphics/particles/magic.white.xml create mode 100644 example/clientdata/graphics/particles/orb-medium.png create mode 100644 example/clientdata/graphics/particles/orb-small.png create mode 100644 example/clientdata/graphics/particles/skillup.particle.xml create mode 100644 example/clientdata/graphics/particles/sparkle.png create mode 100644 example/clientdata/graphics/particles/star-medium.png create mode 100644 example/clientdata/graphics/particles/star-small.png create mode 100644 example/clientdata/graphics/particles/warparea.particle.xml create mode 100644 example/clientdata/graphics/skills/axe.png create mode 100644 example/clientdata/graphics/skills/bow.png create mode 100644 example/clientdata/graphics/skills/knife.png create mode 100644 example/clientdata/graphics/skills/mace.png create mode 100644 example/clientdata/graphics/skills/magic.png create mode 100644 example/clientdata/graphics/skills/polearm.png create mode 100644 example/clientdata/graphics/skills/shooting.png create mode 100644 example/clientdata/graphics/skills/staff.png create mode 100644 example/clientdata/graphics/skills/sword.png create mode 100644 example/clientdata/graphics/skills/thrown.png create mode 100644 example/clientdata/graphics/skills/unarmed.png create mode 100644 example/clientdata/graphics/skills/unknown.png create mode 100644 example/clientdata/graphics/skills/whip.png create mode 100644 example/clientdata/graphics/sprites/equipment/chest/chest-leather-female.png create mode 100644 example/clientdata/graphics/sprites/equipment/chest/chest-leather-female.xml create mode 100644 example/clientdata/graphics/sprites/equipment/chest/chest-leather-male.png create mode 100644 example/clientdata/graphics/sprites/equipment/chest/chest-leather-male.xml create mode 100644 example/clientdata/graphics/sprites/error.png create mode 100644 example/clientdata/graphics/sprites/error.xml create mode 100644 example/clientdata/graphics/sprites/icons/icon-feather.png create mode 100644 example/clientdata/graphics/sprites/icons/icon-feather.xml create mode 100644 example/clientdata/graphics/sprites/icons/icon-poison.png create mode 100644 example/clientdata/graphics/sprites/icons/icon-poison.xml create mode 100644 example/clientdata/graphics/sprites/monsters/monster-maggot.png create mode 100644 example/clientdata/graphics/sprites/monsters/monster-maggot.xml create mode 100644 example/clientdata/graphics/sprites/monsters/monster-scorpion.png create mode 100644 example/clientdata/graphics/sprites/monsters/monster-scorpion.xml create mode 100644 example/clientdata/graphics/sprites/monsters/monster-slime.png create mode 100644 example/clientdata/graphics/sprites/monsters/monster-slime.xml create mode 100644 example/clientdata/graphics/sprites/weapons/weapon-bow.png create mode 100644 example/clientdata/graphics/sprites/weapons/weapon-bow.xml create mode 100644 example/clientdata/graphics/sprites/weapons/weapon-fist.xml create mode 100644 example/clientdata/graphics/sprites/weapons/weapon-sword.png create mode 100644 example/clientdata/graphics/sprites/weapons/weapon-sword.xml create mode 100644 example/clientdata/hair.xml create mode 100644 example/clientdata/paths.xml create mode 100644 example/clientdata/sfx/fist-swish.ogg create mode 100644 example/clientdata/sfx/monsters/maggot/maggot-dying1.ogg create mode 100644 example/clientdata/sfx/monsters/maggot/maggot-hit1.ogg create mode 100644 example/clientdata/sfx/monsters/maggot/maggot-hit2.ogg create mode 100644 example/clientdata/sfx/monsters/maggot/maggot-miss1.ogg create mode 100644 example/clientdata/sfx/monsters/scorpion/scorpion-hit1.ogg create mode 100644 example/clientdata/sfx/monsters/scorpion/scorpion-hit2.ogg create mode 100644 example/clientdata/sfx/monsters/scorpion/scorpion-hit3.ogg create mode 100644 example/clientdata/sfx/monsters/scorpion/scorpion-hit4.ogg create mode 100644 example/clientdata/sfx/monsters/scorpion/scorpion-miss1.ogg create mode 100644 example/clientdata/sfx/monsters/slime/slime-hit1.ogg create mode 100644 example/clientdata/specials.xml create mode 100644 example/clientdata/units.xml create mode 100644 example/serverdata/scripts/items/candy.lua create mode 100644 example/serverdata/scripts/monster/testmonster.lua create mode 100644 example/serverdata/scripts/npcs/banker.lua create mode 100644 example/serverdata/scripts/npcs/barber.lua create mode 100644 example/serverdata/scripts/npcs/debugger.lua create mode 100644 example/serverdata/scripts/npcs/emotemaker.lua create mode 100644 example/serverdata/scripts/npcs/healer.lua create mode 100644 example/serverdata/scripts/npcs/postman.lua create mode 100644 example/serverdata/scripts/npcs/seller.lua create mode 100644 example/serverdata/scripts/status/jump.lua create mode 100644 example/serverdata/scripts/status/plague.lua (limited to 'example') diff --git a/example/clientdata/effects.xml b/example/clientdata/effects.xml new file mode 100644 index 00000000..e0583f44 --- /dev/null +++ b/example/clientdata/effects.xml @@ -0,0 +1,29 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/example/clientdata/emotes.xml b/example/clientdata/emotes.xml new file mode 100644 index 00000000..0136b13c --- /dev/null +++ b/example/clientdata/emotes.xml @@ -0,0 +1,101 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/example/clientdata/graphics/items/equipment/chest/chest-leathershirt.png b/example/clientdata/graphics/items/equipment/chest/chest-leathershirt.png new file mode 100644 index 00000000..761b9bf6 Binary files /dev/null and b/example/clientdata/graphics/items/equipment/chest/chest-leathershirt.png differ diff --git a/example/clientdata/graphics/items/equipment/weapons/weapon-bow-bow.png b/example/clientdata/graphics/items/equipment/weapons/weapon-bow-bow.png new file mode 100644 index 00000000..2ab672dc Binary files /dev/null and b/example/clientdata/graphics/items/equipment/weapons/weapon-bow-bow.png differ diff --git a/example/clientdata/graphics/items/equipment/weapons/weapon-sword-sword.png b/example/clientdata/graphics/items/equipment/weapons/weapon-sword-sword.png new file mode 100644 index 00000000..571fb40e Binary files /dev/null and b/example/clientdata/graphics/items/equipment/weapons/weapon-sword-sword.png differ diff --git a/example/clientdata/graphics/items/unknown.png b/example/clientdata/graphics/items/unknown.png new file mode 100644 index 00000000..9201d688 Binary files /dev/null and b/example/clientdata/graphics/items/unknown.png differ diff --git a/example/clientdata/graphics/items/usable/usable-candy.png b/example/clientdata/graphics/items/usable/usable-candy.png new file mode 100644 index 00000000..e3d75c21 Binary files /dev/null and b/example/clientdata/graphics/items/usable/usable-candy.png differ diff --git a/example/clientdata/graphics/items/usable/usable-minor-health-potion.png b/example/clientdata/graphics/items/usable/usable-minor-health-potion.png new file mode 100644 index 00000000..a404d6f6 Binary files /dev/null and b/example/clientdata/graphics/items/usable/usable-minor-health-potion.png differ diff --git a/example/clientdata/graphics/items/usable/usable-regenerative-trinket.png b/example/clientdata/graphics/items/usable/usable-regenerative-trinket.png new file mode 100644 index 00000000..ba69b570 Binary files /dev/null and b/example/clientdata/graphics/items/usable/usable-regenerative-trinket.png differ diff --git a/example/clientdata/graphics/items/usable/usable-token-of-speed.png b/example/clientdata/graphics/items/usable/usable-token-of-speed.png new file mode 100644 index 00000000..25c712f9 Binary files /dev/null and b/example/clientdata/graphics/items/usable/usable-token-of-speed.png differ diff --git a/example/clientdata/graphics/particles/arrow-down.png b/example/clientdata/graphics/particles/arrow-down.png new file mode 100644 index 00000000..da94afcf Binary files /dev/null and b/example/clientdata/graphics/particles/arrow-down.png differ diff --git a/example/clientdata/graphics/particles/arrow-hail.xml b/example/clientdata/graphics/particles/arrow-hail.xml new file mode 100644 index 00000000..5372e9a3 --- /dev/null +++ b/example/clientdata/graphics/particles/arrow-hail.xml @@ -0,0 +1,23 @@ + + + + + + + + + + + + + + + + + + diff --git a/example/clientdata/graphics/particles/arrow.particle.xml b/example/clientdata/graphics/particles/arrow.particle.xml new file mode 100644 index 00000000..e19e2205 --- /dev/null +++ b/example/clientdata/graphics/particles/arrow.particle.xml @@ -0,0 +1,14 @@ + + + + + + + + + diff --git a/example/clientdata/graphics/particles/arrowh.png b/example/clientdata/graphics/particles/arrowh.png new file mode 100644 index 00000000..11826070 Binary files /dev/null and b/example/clientdata/graphics/particles/arrowh.png differ diff --git a/example/clientdata/graphics/particles/attack.particle.xml b/example/clientdata/graphics/particles/attack.particle.xml new file mode 100644 index 00000000..c8dc5f3e --- /dev/null +++ b/example/clientdata/graphics/particles/attack.particle.xml @@ -0,0 +1,60 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/example/clientdata/graphics/particles/emotes/angel.png b/example/clientdata/graphics/particles/emotes/angel.png new file mode 100644 index 00000000..043d0755 Binary files /dev/null and b/example/clientdata/graphics/particles/emotes/angel.png differ diff --git a/example/clientdata/graphics/particles/emotes/blah.png b/example/clientdata/graphics/particles/emotes/blah.png new file mode 100644 index 00000000..3eae88a2 Binary files /dev/null and b/example/clientdata/graphics/particles/emotes/blah.png differ diff --git a/example/clientdata/graphics/particles/emotes/blush.png b/example/clientdata/graphics/particles/emotes/blush.png new file mode 100644 index 00000000..22172ae0 Binary files /dev/null and b/example/clientdata/graphics/particles/emotes/blush.png differ diff --git a/example/clientdata/graphics/particles/emotes/disgust.png b/example/clientdata/graphics/particles/emotes/disgust.png new file mode 100644 index 00000000..9965f89d Binary files /dev/null and b/example/clientdata/graphics/particles/emotes/disgust.png differ diff --git a/example/clientdata/graphics/particles/emotes/emote-angel.particle.xml b/example/clientdata/graphics/particles/emotes/emote-angel.particle.xml new file mode 100644 index 00000000..a4bb1b53 --- /dev/null +++ b/example/clientdata/graphics/particles/emotes/emote-angel.particle.xml @@ -0,0 +1,23 @@ + + + + + + + + + + + + + + + + + + diff --git a/example/clientdata/graphics/particles/emotes/emote-blah.particle.xml b/example/clientdata/graphics/particles/emotes/emote-blah.particle.xml new file mode 100644 index 00000000..38cb327a --- /dev/null +++ b/example/clientdata/graphics/particles/emotes/emote-blah.particle.xml @@ -0,0 +1,23 @@ + + + + + + + + + + + + + + + + + + diff --git a/example/clientdata/graphics/particles/emotes/emote-blush.particle.xml b/example/clientdata/graphics/particles/emotes/emote-blush.particle.xml new file mode 100644 index 00000000..11d2689d --- /dev/null +++ b/example/clientdata/graphics/particles/emotes/emote-blush.particle.xml @@ -0,0 +1,23 @@ + + + + + + + + + + + + + + + + + + diff --git a/example/clientdata/graphics/particles/emotes/emote-disgust.particle.xml b/example/clientdata/graphics/particles/emotes/emote-disgust.particle.xml new file mode 100644 index 00000000..b04d18dd --- /dev/null +++ b/example/clientdata/graphics/particles/emotes/emote-disgust.particle.xml @@ -0,0 +1,23 @@ + + + + + + + + + + + + + + + + + + diff --git a/example/clientdata/graphics/particles/emotes/emote-evil.particle.xml b/example/clientdata/graphics/particles/emotes/emote-evil.particle.xml new file mode 100644 index 00000000..433aef30 --- /dev/null +++ b/example/clientdata/graphics/particles/emotes/emote-evil.particle.xml @@ -0,0 +1,23 @@ + + + + + + + + + + + + + + + + + + diff --git a/example/clientdata/graphics/particles/emotes/emote-grin.particle.xml b/example/clientdata/graphics/particles/emotes/emote-grin.particle.xml new file mode 100644 index 00000000..5c50aa98 --- /dev/null +++ b/example/clientdata/graphics/particles/emotes/emote-grin.particle.xml @@ -0,0 +1,23 @@ + + + + + + + + + + + + + + + + + + diff --git a/example/clientdata/graphics/particles/emotes/emote-happy.particle.xml b/example/clientdata/graphics/particles/emotes/emote-happy.particle.xml new file mode 100644 index 00000000..fa43997f --- /dev/null +++ b/example/clientdata/graphics/particles/emotes/emote-happy.particle.xml @@ -0,0 +1,23 @@ + + + + + + + + + + + + + + + + + + diff --git a/example/clientdata/graphics/particles/emotes/emote-perturbed.particle.xml b/example/clientdata/graphics/particles/emotes/emote-perturbed.particle.xml new file mode 100644 index 00000000..47f92e30 --- /dev/null +++ b/example/clientdata/graphics/particles/emotes/emote-perturbed.particle.xml @@ -0,0 +1,23 @@ + + + + + + + + + + + + + + + + + + diff --git a/example/clientdata/graphics/particles/emotes/emote-sad.particle.xml b/example/clientdata/graphics/particles/emotes/emote-sad.particle.xml new file mode 100644 index 00000000..0e0b7dc8 --- /dev/null +++ b/example/clientdata/graphics/particles/emotes/emote-sad.particle.xml @@ -0,0 +1,23 @@ + + + + + + + + + + + + + + + + + + diff --git a/example/clientdata/graphics/particles/emotes/emote-speech.particle.xml b/example/clientdata/graphics/particles/emotes/emote-speech.particle.xml new file mode 100644 index 00000000..7d6350b0 --- /dev/null +++ b/example/clientdata/graphics/particles/emotes/emote-speech.particle.xml @@ -0,0 +1,23 @@ + + + + + + + + + + + + + + + + + + diff --git a/example/clientdata/graphics/particles/emotes/emote-surprise.particle.xml b/example/clientdata/graphics/particles/emotes/emote-surprise.particle.xml new file mode 100644 index 00000000..29498c8f --- /dev/null +++ b/example/clientdata/graphics/particles/emotes/emote-surprise.particle.xml @@ -0,0 +1,23 @@ + + + + + + + + + + + + + + + + + + diff --git a/example/clientdata/graphics/particles/emotes/emote-tongue.particle.xml b/example/clientdata/graphics/particles/emotes/emote-tongue.particle.xml new file mode 100644 index 00000000..2796ac6c --- /dev/null +++ b/example/clientdata/graphics/particles/emotes/emote-tongue.particle.xml @@ -0,0 +1,23 @@ + + + + + + + + + + + + + + + + + + diff --git a/example/clientdata/graphics/particles/emotes/emote-upset.particle.xml b/example/clientdata/graphics/particles/emotes/emote-upset.particle.xml new file mode 100644 index 00000000..4b10d9f2 --- /dev/null +++ b/example/clientdata/graphics/particles/emotes/emote-upset.particle.xml @@ -0,0 +1,23 @@ + + + + + + + + + + + + + + + + + + diff --git a/example/clientdata/graphics/particles/emotes/emote-wink.particle.xml b/example/clientdata/graphics/particles/emotes/emote-wink.particle.xml new file mode 100644 index 00000000..b217a649 --- /dev/null +++ b/example/clientdata/graphics/particles/emotes/emote-wink.particle.xml @@ -0,0 +1,23 @@ + + + + + + + + + + + + + + + + + + diff --git a/example/clientdata/graphics/particles/emotes/evil.png b/example/clientdata/graphics/particles/emotes/evil.png new file mode 100644 index 00000000..7c417ec6 Binary files /dev/null and b/example/clientdata/graphics/particles/emotes/evil.png differ diff --git a/example/clientdata/graphics/particles/emotes/grin.png b/example/clientdata/graphics/particles/emotes/grin.png new file mode 100644 index 00000000..0c21cfe8 Binary files /dev/null and b/example/clientdata/graphics/particles/emotes/grin.png differ diff --git a/example/clientdata/graphics/particles/emotes/happy.png b/example/clientdata/graphics/particles/emotes/happy.png new file mode 100644 index 00000000..8ca2930e Binary files /dev/null and b/example/clientdata/graphics/particles/emotes/happy.png differ diff --git a/example/clientdata/graphics/particles/emotes/perturbed.png b/example/clientdata/graphics/particles/emotes/perturbed.png new file mode 100644 index 00000000..0a33e0ad Binary files /dev/null and b/example/clientdata/graphics/particles/emotes/perturbed.png differ diff --git a/example/clientdata/graphics/particles/emotes/sad.png b/example/clientdata/graphics/particles/emotes/sad.png new file mode 100644 index 00000000..3ceb3caf Binary files /dev/null and b/example/clientdata/graphics/particles/emotes/sad.png differ diff --git a/example/clientdata/graphics/particles/emotes/speech.png b/example/clientdata/graphics/particles/emotes/speech.png new file mode 100644 index 00000000..72044719 Binary files /dev/null and b/example/clientdata/graphics/particles/emotes/speech.png differ diff --git a/example/clientdata/graphics/particles/emotes/surprise.png b/example/clientdata/graphics/particles/emotes/surprise.png new file mode 100644 index 00000000..e1649a63 Binary files /dev/null and b/example/clientdata/graphics/particles/emotes/surprise.png differ diff --git a/example/clientdata/graphics/particles/emotes/tongue.png b/example/clientdata/graphics/particles/emotes/tongue.png new file mode 100644 index 00000000..0d5bc959 Binary files /dev/null and b/example/clientdata/graphics/particles/emotes/tongue.png differ diff --git a/example/clientdata/graphics/particles/emotes/upset.png b/example/clientdata/graphics/particles/emotes/upset.png new file mode 100644 index 00000000..b2f0ce2b Binary files /dev/null and b/example/clientdata/graphics/particles/emotes/upset.png differ diff --git a/example/clientdata/graphics/particles/emotes/wink.png b/example/clientdata/graphics/particles/emotes/wink.png new file mode 100644 index 00000000..13488bb8 Binary files /dev/null and b/example/clientdata/graphics/particles/emotes/wink.png differ diff --git a/example/clientdata/graphics/particles/fullbubble-16px.png b/example/clientdata/graphics/particles/fullbubble-16px.png new file mode 100644 index 00000000..93e3b57f Binary files /dev/null and b/example/clientdata/graphics/particles/fullbubble-16px.png differ diff --git a/example/clientdata/graphics/particles/green-bubbles.particle.xml b/example/clientdata/graphics/particles/green-bubbles.particle.xml new file mode 100644 index 00000000..e272d85c --- /dev/null +++ b/example/clientdata/graphics/particles/green-bubbles.particle.xml @@ -0,0 +1,40 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/example/clientdata/graphics/particles/hit.particle.xml b/example/clientdata/graphics/particles/hit.particle.xml new file mode 100644 index 00000000..c5c295fc --- /dev/null +++ b/example/clientdata/graphics/particles/hit.particle.xml @@ -0,0 +1,59 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/example/clientdata/graphics/particles/levelup.particle.xml b/example/clientdata/graphics/particles/levelup.particle.xml new file mode 100644 index 00000000..0c80626b --- /dev/null +++ b/example/clientdata/graphics/particles/levelup.particle.xml @@ -0,0 +1,23 @@ + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/example/clientdata/graphics/particles/magic.white.xml b/example/clientdata/graphics/particles/magic.white.xml new file mode 100644 index 00000000..5304b77f --- /dev/null +++ b/example/clientdata/graphics/particles/magic.white.xml @@ -0,0 +1,24 @@ + + + + + + + + + + + + + + + + + + + diff --git a/example/clientdata/graphics/particles/orb-medium.png b/example/clientdata/graphics/particles/orb-medium.png new file mode 100644 index 00000000..eb896c85 Binary files /dev/null and b/example/clientdata/graphics/particles/orb-medium.png differ diff --git a/example/clientdata/graphics/particles/orb-small.png b/example/clientdata/graphics/particles/orb-small.png new file mode 100644 index 00000000..47cf957f Binary files /dev/null and b/example/clientdata/graphics/particles/orb-small.png differ diff --git a/example/clientdata/graphics/particles/skillup.particle.xml b/example/clientdata/graphics/particles/skillup.particle.xml new file mode 100644 index 00000000..91d79e7a --- /dev/null +++ b/example/clientdata/graphics/particles/skillup.particle.xml @@ -0,0 +1,23 @@ + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/example/clientdata/graphics/particles/sparkle.png b/example/clientdata/graphics/particles/sparkle.png new file mode 100644 index 00000000..7cfbbb26 Binary files /dev/null and b/example/clientdata/graphics/particles/sparkle.png differ diff --git a/example/clientdata/graphics/particles/star-medium.png b/example/clientdata/graphics/particles/star-medium.png new file mode 100644 index 00000000..667d2334 Binary files /dev/null and b/example/clientdata/graphics/particles/star-medium.png differ diff --git a/example/clientdata/graphics/particles/star-small.png b/example/clientdata/graphics/particles/star-small.png new file mode 100644 index 00000000..4c3bf365 Binary files /dev/null and b/example/clientdata/graphics/particles/star-small.png differ diff --git a/example/clientdata/graphics/particles/warparea.particle.xml b/example/clientdata/graphics/particles/warparea.particle.xml new file mode 100644 index 00000000..f4984232 --- /dev/null +++ b/example/clientdata/graphics/particles/warparea.particle.xml @@ -0,0 +1,24 @@ + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/example/clientdata/graphics/skills/axe.png b/example/clientdata/graphics/skills/axe.png new file mode 100644 index 00000000..b2af0347 Binary files /dev/null and b/example/clientdata/graphics/skills/axe.png differ diff --git a/example/clientdata/graphics/skills/bow.png b/example/clientdata/graphics/skills/bow.png new file mode 100644 index 00000000..78c4319a Binary files /dev/null and b/example/clientdata/graphics/skills/bow.png differ diff --git a/example/clientdata/graphics/skills/knife.png b/example/clientdata/graphics/skills/knife.png new file mode 100644 index 00000000..61f834c6 Binary files /dev/null and b/example/clientdata/graphics/skills/knife.png differ diff --git a/example/clientdata/graphics/skills/mace.png b/example/clientdata/graphics/skills/mace.png new file mode 100644 index 00000000..7958d32f Binary files /dev/null and b/example/clientdata/graphics/skills/mace.png differ diff --git a/example/clientdata/graphics/skills/magic.png b/example/clientdata/graphics/skills/magic.png new file mode 100644 index 00000000..9201d688 Binary files /dev/null and b/example/clientdata/graphics/skills/magic.png differ diff --git a/example/clientdata/graphics/skills/polearm.png b/example/clientdata/graphics/skills/polearm.png new file mode 100644 index 00000000..52c8449d Binary files /dev/null and b/example/clientdata/graphics/skills/polearm.png differ diff --git a/example/clientdata/graphics/skills/shooting.png b/example/clientdata/graphics/skills/shooting.png new file mode 100644 index 00000000..e7b0806c Binary files /dev/null and b/example/clientdata/graphics/skills/shooting.png differ diff --git a/example/clientdata/graphics/skills/staff.png b/example/clientdata/graphics/skills/staff.png new file mode 100644 index 00000000..e5c071e0 Binary files /dev/null and b/example/clientdata/graphics/skills/staff.png differ diff --git a/example/clientdata/graphics/skills/sword.png b/example/clientdata/graphics/skills/sword.png new file mode 100644 index 00000000..9b6db914 Binary files /dev/null and b/example/clientdata/graphics/skills/sword.png differ diff --git a/example/clientdata/graphics/skills/thrown.png b/example/clientdata/graphics/skills/thrown.png new file mode 100644 index 00000000..3fc35de7 Binary files /dev/null and b/example/clientdata/graphics/skills/thrown.png differ diff --git a/example/clientdata/graphics/skills/unarmed.png b/example/clientdata/graphics/skills/unarmed.png new file mode 100644 index 00000000..adb139ed Binary files /dev/null and b/example/clientdata/graphics/skills/unarmed.png differ diff --git a/example/clientdata/graphics/skills/unknown.png b/example/clientdata/graphics/skills/unknown.png new file mode 100644 index 00000000..9201d688 Binary files /dev/null and b/example/clientdata/graphics/skills/unknown.png differ diff --git a/example/clientdata/graphics/skills/whip.png b/example/clientdata/graphics/skills/whip.png new file mode 100644 index 00000000..e5734e5d Binary files /dev/null and b/example/clientdata/graphics/skills/whip.png differ diff --git a/example/clientdata/graphics/sprites/equipment/chest/chest-leather-female.png b/example/clientdata/graphics/sprites/equipment/chest/chest-leather-female.png new file mode 100644 index 00000000..a6efbf9b Binary files /dev/null and b/example/clientdata/graphics/sprites/equipment/chest/chest-leather-female.png differ diff --git a/example/clientdata/graphics/sprites/equipment/chest/chest-leather-female.xml b/example/clientdata/graphics/sprites/equipment/chest/chest-leather-female.xml new file mode 100644 index 00000000..b44be8ab --- /dev/null +++ b/example/clientdata/graphics/sprites/equipment/chest/chest-leather-female.xml @@ -0,0 +1,104 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/example/clientdata/graphics/sprites/equipment/chest/chest-leather-male.png b/example/clientdata/graphics/sprites/equipment/chest/chest-leather-male.png new file mode 100644 index 00000000..bc5a3c65 Binary files /dev/null and b/example/clientdata/graphics/sprites/equipment/chest/chest-leather-male.png differ diff --git a/example/clientdata/graphics/sprites/equipment/chest/chest-leather-male.xml b/example/clientdata/graphics/sprites/equipment/chest/chest-leather-male.xml new file mode 100644 index 00000000..fd46be28 --- /dev/null +++ b/example/clientdata/graphics/sprites/equipment/chest/chest-leather-male.xml @@ -0,0 +1,104 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/example/clientdata/graphics/sprites/error.png b/example/clientdata/graphics/sprites/error.png new file mode 100644 index 00000000..108ad0e4 Binary files /dev/null and b/example/clientdata/graphics/sprites/error.png differ diff --git a/example/clientdata/graphics/sprites/error.xml b/example/clientdata/graphics/sprites/error.xml new file mode 100644 index 00000000..3504bd01 --- /dev/null +++ b/example/clientdata/graphics/sprites/error.xml @@ -0,0 +1,10 @@ + + + + + + + + + + \ No newline at end of file diff --git a/example/clientdata/graphics/sprites/icons/icon-feather.png b/example/clientdata/graphics/sprites/icons/icon-feather.png new file mode 100644 index 00000000..425fb286 Binary files /dev/null and b/example/clientdata/graphics/sprites/icons/icon-feather.png differ diff --git a/example/clientdata/graphics/sprites/icons/icon-feather.xml b/example/clientdata/graphics/sprites/icons/icon-feather.xml new file mode 100644 index 00000000..715a2f82 --- /dev/null +++ b/example/clientdata/graphics/sprites/icons/icon-feather.xml @@ -0,0 +1,10 @@ + + + + + + + + + + diff --git a/example/clientdata/graphics/sprites/icons/icon-poison.png b/example/clientdata/graphics/sprites/icons/icon-poison.png new file mode 100644 index 00000000..b7803cd9 Binary files /dev/null and b/example/clientdata/graphics/sprites/icons/icon-poison.png differ diff --git a/example/clientdata/graphics/sprites/icons/icon-poison.xml b/example/clientdata/graphics/sprites/icons/icon-poison.xml new file mode 100644 index 00000000..0a8f751a --- /dev/null +++ b/example/clientdata/graphics/sprites/icons/icon-poison.xml @@ -0,0 +1,18 @@ + + + + + + + + + + + + + + + + + + diff --git a/example/clientdata/graphics/sprites/monsters/monster-maggot.png b/example/clientdata/graphics/sprites/monsters/monster-maggot.png new file mode 100644 index 00000000..64474f94 Binary files /dev/null and b/example/clientdata/graphics/sprites/monsters/monster-maggot.png differ diff --git a/example/clientdata/graphics/sprites/monsters/monster-maggot.xml b/example/clientdata/graphics/sprites/monsters/monster-maggot.xml new file mode 100644 index 00000000..f603b8db --- /dev/null +++ b/example/clientdata/graphics/sprites/monsters/monster-maggot.xml @@ -0,0 +1,66 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/example/clientdata/graphics/sprites/monsters/monster-scorpion.png b/example/clientdata/graphics/sprites/monsters/monster-scorpion.png new file mode 100644 index 00000000..0bd693fd Binary files /dev/null and b/example/clientdata/graphics/sprites/monsters/monster-scorpion.png differ diff --git a/example/clientdata/graphics/sprites/monsters/monster-scorpion.xml b/example/clientdata/graphics/sprites/monsters/monster-scorpion.xml new file mode 100644 index 00000000..ab1986a3 --- /dev/null +++ b/example/clientdata/graphics/sprites/monsters/monster-scorpion.xml @@ -0,0 +1,70 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/example/clientdata/graphics/sprites/monsters/monster-slime.png b/example/clientdata/graphics/sprites/monsters/monster-slime.png new file mode 100644 index 00000000..ab14bbb5 Binary files /dev/null and b/example/clientdata/graphics/sprites/monsters/monster-slime.png differ diff --git a/example/clientdata/graphics/sprites/monsters/monster-slime.xml b/example/clientdata/graphics/sprites/monsters/monster-slime.xml new file mode 100644 index 00000000..220a8e25 --- /dev/null +++ b/example/clientdata/graphics/sprites/monsters/monster-slime.xml @@ -0,0 +1,55 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/example/clientdata/graphics/sprites/weapons/weapon-bow.png b/example/clientdata/graphics/sprites/weapons/weapon-bow.png new file mode 100644 index 00000000..b5f8a68e Binary files /dev/null and b/example/clientdata/graphics/sprites/weapons/weapon-bow.png differ diff --git a/example/clientdata/graphics/sprites/weapons/weapon-bow.xml b/example/clientdata/graphics/sprites/weapons/weapon-bow.xml new file mode 100644 index 00000000..7580776c --- /dev/null +++ b/example/clientdata/graphics/sprites/weapons/weapon-bow.xml @@ -0,0 +1,26 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/example/clientdata/graphics/sprites/weapons/weapon-fist.xml b/example/clientdata/graphics/sprites/weapons/weapon-fist.xml new file mode 100644 index 00000000..324dfd5b --- /dev/null +++ b/example/clientdata/graphics/sprites/weapons/weapon-fist.xml @@ -0,0 +1,7 @@ + + + + + + + \ No newline at end of file diff --git a/example/clientdata/graphics/sprites/weapons/weapon-sword.png b/example/clientdata/graphics/sprites/weapons/weapon-sword.png new file mode 100644 index 00000000..f691ef3f Binary files /dev/null and b/example/clientdata/graphics/sprites/weapons/weapon-sword.png differ diff --git a/example/clientdata/graphics/sprites/weapons/weapon-sword.xml b/example/clientdata/graphics/sprites/weapons/weapon-sword.xml new file mode 100644 index 00000000..1909aff6 --- /dev/null +++ b/example/clientdata/graphics/sprites/weapons/weapon-sword.xml @@ -0,0 +1,27 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/example/clientdata/hair.xml b/example/clientdata/hair.xml new file mode 100644 index 00000000..b24d9adb --- /dev/null +++ b/example/clientdata/hair.xml @@ -0,0 +1,15 @@ + + + + + + + + + + + + + + + diff --git a/example/clientdata/items.xml b/example/clientdata/items.xml index fbf899ac..9fd64a24 100644 --- a/example/clientdata/items.xml +++ b/example/clientdata/items.xml @@ -1,12 +1,96 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + weapons/weapon-sword.xml + + + + + + + + + + + + + + weapons/weapon-bow.xml + + + + + + + + + + + + + + equipment/chest/chest-leather-male.xml + equipment/chest/chest-leather-female.xml + diff --git a/example/clientdata/mana-skills.xml b/example/clientdata/mana-skills.xml index 118450c6..ace8b444 100644 --- a/example/clientdata/mana-skills.xml +++ b/example/clientdata/mana-skills.xml @@ -1,3 +1,22 @@ + + + + + + + + + + + + + + + + + + + diff --git a/example/clientdata/mana-status-effect.xml b/example/clientdata/mana-status-effect.xml index 650d50ff..7b613c4f 100644 --- a/example/clientdata/mana-status-effect.xml +++ b/example/clientdata/mana-status-effect.xml @@ -1,3 +1,15 @@ + + diff --git a/example/clientdata/monsters.xml b/example/clientdata/monsters.xml index 21ddc80a..70d4009f 100644 --- a/example/clientdata/monsters.xml +++ b/example/clientdata/monsters.xml @@ -1,3 +1,224 @@ + + + + + monsters/monster-maggot.xml + monsters/maggot/maggot-hit1.ogg + monsters/maggot/maggot-hit2.ogg + monsters/maggot/maggot-miss1.ogg + monsters/maggot/maggot-dying1.ogg + + + + + + + + + + 10 + + + + + + + + monsters/monster-scorpion.xml|#4d422d,826242,d8c282,ffffff + monsters/scorpion/scorpion-hit1.ogg + monsters/scorpion/scorpion-hit2.ogg + monsters/scorpion/scorpion-hit3.ogg + monsters/scorpion/scorpion-hit4.ogg + monsters/scorpion/scorpion-miss1.ogg + + + + + 20 + + + + + + + + + + + monsters/monster-scorpion.xml|#791d0a,cd5d27,f28d54,ffffff + monsters/scorpion/scorpion-hit1.ogg + monsters/scorpion/scorpion-hit2.ogg + monsters/scorpion/scorpion-hit3.ogg + monsters/scorpion/scorpion-hit4.ogg + monsters/scorpion/scorpion-miss1.ogg + + + + + + + + 50 + + + + + + + + monsters/monster-slime.xml|#72982c,ffffff + monsters/slime/slime-hit1.ogg + + + + + + + + + 60 + + + + + + diff --git a/example/clientdata/paths.xml b/example/clientdata/paths.xml new file mode 100644 index 00000000..21d1fc23 --- /dev/null +++ b/example/clientdata/paths.xml @@ -0,0 +1,54 @@ + + + + + + \ No newline at end of file diff --git a/example/clientdata/sfx/fist-swish.ogg b/example/clientdata/sfx/fist-swish.ogg new file mode 100644 index 00000000..757d0f77 Binary files /dev/null and b/example/clientdata/sfx/fist-swish.ogg differ diff --git a/example/clientdata/sfx/monsters/maggot/maggot-dying1.ogg b/example/clientdata/sfx/monsters/maggot/maggot-dying1.ogg new file mode 100644 index 00000000..e05a5235 Binary files /dev/null and b/example/clientdata/sfx/monsters/maggot/maggot-dying1.ogg differ diff --git a/example/clientdata/sfx/monsters/maggot/maggot-hit1.ogg b/example/clientdata/sfx/monsters/maggot/maggot-hit1.ogg new file mode 100644 index 00000000..695cb483 Binary files /dev/null and b/example/clientdata/sfx/monsters/maggot/maggot-hit1.ogg differ diff --git a/example/clientdata/sfx/monsters/maggot/maggot-hit2.ogg b/example/clientdata/sfx/monsters/maggot/maggot-hit2.ogg new file mode 100644 index 00000000..12d92bb9 Binary files /dev/null and b/example/clientdata/sfx/monsters/maggot/maggot-hit2.ogg differ diff --git a/example/clientdata/sfx/monsters/maggot/maggot-miss1.ogg b/example/clientdata/sfx/monsters/maggot/maggot-miss1.ogg new file mode 100644 index 00000000..a251bf97 Binary files /dev/null and b/example/clientdata/sfx/monsters/maggot/maggot-miss1.ogg differ diff --git a/example/clientdata/sfx/monsters/scorpion/scorpion-hit1.ogg b/example/clientdata/sfx/monsters/scorpion/scorpion-hit1.ogg new file mode 100644 index 00000000..d0cf8d03 Binary files /dev/null and b/example/clientdata/sfx/monsters/scorpion/scorpion-hit1.ogg differ diff --git a/example/clientdata/sfx/monsters/scorpion/scorpion-hit2.ogg b/example/clientdata/sfx/monsters/scorpion/scorpion-hit2.ogg new file mode 100644 index 00000000..04521d63 Binary files /dev/null and b/example/clientdata/sfx/monsters/scorpion/scorpion-hit2.ogg differ diff --git a/example/clientdata/sfx/monsters/scorpion/scorpion-hit3.ogg b/example/clientdata/sfx/monsters/scorpion/scorpion-hit3.ogg new file mode 100644 index 00000000..283efff2 Binary files /dev/null and b/example/clientdata/sfx/monsters/scorpion/scorpion-hit3.ogg differ diff --git a/example/clientdata/sfx/monsters/scorpion/scorpion-hit4.ogg b/example/clientdata/sfx/monsters/scorpion/scorpion-hit4.ogg new file mode 100644 index 00000000..bef67872 Binary files /dev/null and b/example/clientdata/sfx/monsters/scorpion/scorpion-hit4.ogg differ diff --git a/example/clientdata/sfx/monsters/scorpion/scorpion-miss1.ogg b/example/clientdata/sfx/monsters/scorpion/scorpion-miss1.ogg new file mode 100644 index 00000000..264fe44e Binary files /dev/null and b/example/clientdata/sfx/monsters/scorpion/scorpion-miss1.ogg differ diff --git a/example/clientdata/sfx/monsters/slime/slime-hit1.ogg b/example/clientdata/sfx/monsters/slime/slime-hit1.ogg new file mode 100644 index 00000000..decf40ae Binary files /dev/null and b/example/clientdata/sfx/monsters/slime/slime-hit1.ogg differ diff --git a/example/clientdata/specials.xml b/example/clientdata/specials.xml new file mode 100644 index 00000000..d49f12b3 --- /dev/null +++ b/example/clientdata/specials.xml @@ -0,0 +1,8 @@ + + + + + + + + diff --git a/example/clientdata/units.xml b/example/clientdata/units.xml new file mode 100644 index 00000000..265318f2 --- /dev/null +++ b/example/clientdata/units.xml @@ -0,0 +1,7 @@ + + + + + + + diff --git a/example/serverdata/scripts/global_events.lua b/example/serverdata/scripts/global_events.lua index 51047e90..90b096cd 100644 --- a/example/serverdata/scripts/global_events.lua +++ b/example/serverdata/scripts/global_events.lua @@ -18,40 +18,61 @@ ---------------------------------------------------------------------------------- - --- This function is called when the hit points of a character reach zero. +-- This function is called when the hit points of a character reach zero. function on_chr_death(ch) + mana.being_say(ch, "Noooooo!!!") end --- This function is called when the player clicks on the “OK” button after --- the death message appeared. It should be used to implement the respawn --- mechanic (for example: warp the character to the respawn location and --- bring HP above zero in some way) +-- This function is called when the player clicks on the �OK� button after +-- the death message appeared. It should be used to implement the respawn +-- mechanic (for example: warp the character to the respawn location and +-- bring HP above zero in some way) function on_chr_death_accept(ch) + mana.being_heal(ch) -- restores to full hp + -- mana.being_heal(ch, 1) --restores 1 hp (in case you want to be less nice) + -- mana.chr_warp(ch, 1, 2000, 2000) --warp the character to the respawn location end -- This function is called after chr_death_accept. The difference is that -- it is called in the context of the map the character is spawned on after --- the respawn logic has happened. +-- the respawn logic has happened. function on_chr_respawn(ch) - mana.being_heal() + -- calls the local_respawn_function of the map the character respawned + -- on when the script of the map has one + if local_respawn_function ~= nil then + local_respawn_function(ch) + end end -- This function is called when a new character enters the world for the -- first time. This can, for example, be used to give starting equipment --- to the character and/or initialize a tutorial quest. +-- to the character and/or initialize a tutorial quest. function on_chr_birth(ch) + -- this message is shown on first login. + mana.chatmessage(0, ch, "And so your adventure begins...") end -- This function is called when a character logs into the game. This can, -- for example, be utilized for a message-of-the-day or for various --- handlings of offline processing mechanics. +-- handlings of offline processing mechanics. function on_chr_login(ch) + mana.chatmessage(0, ch, "Welcome to Manasource") end -- This function is called when a character is disconnected. This could -- be useful for various handling of offline processing mechanics. function on_chr_logout(ch) + -- notifies nearby players of logout + local around = mana.get_beings_in_circle( + posX(ch), + posY(ch), + 1000) + local msg = mana.being_get_name(ch).." left the game." + for b in pairs(around) do + if mana.being_type(b) == TYPE_CHARACTER then + mana.chatmessage(0, b, msg) + end + end end diff --git a/example/serverdata/scripts/items/candy.lua b/example/serverdata/scripts/items/candy.lua new file mode 100644 index 00000000..a740ce6a --- /dev/null +++ b/example/serverdata/scripts/items/candy.lua @@ -0,0 +1,17 @@ +------------------------------------------------------------- +-- Example use script. Makes the player character say -- +-- "*munch*munch*munch*" when using this item. -- +-- The HP regeneration effect is handled separately based -- +-- on the heal value in items.xml -- +---------------------------------------------------------------------------------- +-- Copyright 2009 The Mana World Development Team -- +-- -- +-- This file is part of The Mana World. -- +-- -- +-- The Mana World is free software; you can redistribute it and/or modify it -- +-- under the terms of the GNU General Public License as published by the Free -- +-- Software Foundation; either version 2 of the License, or any later version. -- +---------------------------------------------------------------------------------- +function use(user) + mana.being_say(user, "*munch*munch*munch*") +end diff --git a/example/serverdata/scripts/monster/testmonster.lua b/example/serverdata/scripts/monster/testmonster.lua new file mode 100644 index 00000000..9938943b --- /dev/null +++ b/example/serverdata/scripts/monster/testmonster.lua @@ -0,0 +1,26 @@ +---------------------------------------------------------------------------------- +-- Copyright 2009 The Mana World Development Team -- +-- -- +-- This file is part of The Mana World. -- +-- -- +-- The Mana World is free software; you can redistribute it and/or modify it -- +-- under the terms of the GNU General Public License as published by the Free -- +-- Software Foundation; either version 2 of the License, or any later version. -- +---------------------------------------------------------------------------------- + +function update(mob) + local r = math.random(0, 200); + if r == 0 then + mana.being_say(mob, "Roar! I am a boss") + end +end + +function strike(mob, victim, hit) + if hit > 0 then + mana.being_say(mob, "Take this! "..hit.." damage!") + mana.being_say(victim, "Oh Noez!") + else + mana.being_say(mob, "Oh no, my attack missed!") + mana.being_say(victim, "Whew...") + end +end diff --git a/example/serverdata/scripts/npcs/banker.lua b/example/serverdata/scripts/npcs/banker.lua new file mode 100644 index 00000000..79d6af6d --- /dev/null +++ b/example/serverdata/scripts/npcs/banker.lua @@ -0,0 +1,74 @@ +---------------------------------------------------------- +-- Banker Function -- +---------------------------------------------------------------------------------- +-- Copyright 2008 The Mana World Development Team -- +-- -- +-- This file is part of The Mana World. -- +-- -- +-- The Mana World is free software; you can redistribute it and/or modify it -- +-- under the terms of the GNU General Public License as published by the Free -- +-- Software Foundation; either version 2 of the License, or any later version. -- +---------------------------------------------------------------------------------- + +function Banker(npc, ch) + do_message(npc, ch, "Welcome to the bank!") + local account = tonumber(get_quest_var(ch, "BankAccount")) + local result = -1 + do_wait() + + if (account == nil) then --Initial account creation, if needed + do_message(npc, ch, "Hello! Would you like to setup a bank account? There is a sign-on bonus right now!") + result = do_choice(npc, ch, "Yes", "No") + if (result == 1) then + mana.chr_set_quest(ch, "BankAccount", 5) + do_message(npc, ch, "Your account has been made. Your sign-on bonus is 5GP.") + account = 5 + end + end + + if (account ~= nil) then --If the player has an account + local money = 0 + local input = 0 + result = 1 + while (result < 3) do --While they've choosen a valid option that isn't "Never mind" + account = tonumber(get_quest_var(ch, "BankAccount")) --Why do I need to convert this? + do_message(npc, ch, "Your balance: " .. account .. ".\nYour money: " .. mana.chr_money(ch) .. ".") + result = do_choice(npc, ch, "Deposit", "Withdraw", "Never mind") + if (result == 1) then --Deposit + money = mana.chr_money(ch); + if (money > 0) then --Make sure they have money to deposit + do_message(npc, ch, "How much would you like to deposit? (0 will cancel)") + input = do_ask_integer(npc, ch, 0, money, 1) + do_wait() + money = mana.chr_money(ch) + if (input > 0 and input <= money) then --Make sure something weird doesn't happen and they try to deposit more than they have + mana.chr_money_change(ch, -input) + mana.chr_set_quest(ch, "BankAccount", account + input) + do_message(npc, ch, input .. " GP deposited.") + elseif (input > money) then --Chosen more than they have + do_message(npc, ch, "You don't have that much money. But you just did....") + end + else + do_message(npc, ch, "You don't have any money to deposit!") + end + elseif (result == 2) then --Withdraw + if (account > 0) then --Make sure they have money to withdraw + do_message(npc, ch, "How much would you like to withdraw? (0 will cancel)") + input = do_ask_integer(npc, ch, 0, account, 1) + if (input > 0 and input <= account) then --Make sure something weird doesn't happen and they try to withdraw more than they have + mana.chr_money_change(ch, input) + mana.chr_set_quest(ch, "BankAccount", account - input) + do_message(npc, ch, input .. " GP withdrawn.") + elseif (input > account) then --Chosen more than they have + do_message(npc, ch, "You don't have that much in your account. But you just did....") + end + else + do_message(npc, ch, "Your account is empty!") + end + end + end --This ends the while loop + end + + do_message(npc, ch, "Thank you. Come again!") + do_npc_close(npc, ch) +end diff --git a/example/serverdata/scripts/npcs/barber.lua b/example/serverdata/scripts/npcs/barber.lua new file mode 100644 index 00000000..24ad8c9b --- /dev/null +++ b/example/serverdata/scripts/npcs/barber.lua @@ -0,0 +1,141 @@ +---------------------------------------------------------- +-- Barber Function -- +---------------------------------------------------------------------------------- +-- Copyright 2009 The Mana World Development Team -- +-- -- +-- This file is part of The Mana World. -- +-- -- +-- The Mana World is free software; you can redistribute it and/or modify it -- +-- under the terms of the GNU General Public License as published by the Free -- +-- Software Foundation; either version 2 of the License, or any later version. -- +---------------------------------------------------------------------------------- + +local barber_styles = {"Flat ponytail", "Bowl cut","Combed back", "Emo", "Mohawk", + "Pompadour", "Center parting/Short and slick", "Long and slick", "Short and curly", + "Pigtails", "Long and curly", "Parted", "Perky ponytail", "Wave", "Mane", "Bun"} + +local barber_colors = {"Brunette", "Green", "Dark red", "Light purple", "Gray", "Blonde", + "Teal", "Light red", "Blue", "Dark purple", "Black"} + +function Barber(npc, ch, data) + local style_ids = nil + local color_ids = nil + + -- If extra data was passed, let's have a look at it + if data ~= nil then + style_ids = data[1] + if #data > 1 then + color_ids = data[2] + end + end + + -- Setup up default styles (if needed) + if style_ids == nil then + style_ids = {} + for i = 1, 13 do + style_ids[i] = i + end + end + + -- Setup up default colors (if needed) + if color_ids == nil then + color_ids = {} + for i = 1, 11 do + color_ids[i] = i + end + end + + -- Nothing to show? Then we can return + if #color_ids == 0 and #style_ids == 0 then + return -- Since we haven't shown any windows, we can safely + -- return without a do_npc_close + end + + local result = 0 + + local styles = {} + + -- If we have style IDs, lets get their names + if #style_ids > 0 then + for i = 1, #style_ids do + styles[i] = barber_styles[style_ids[i]] + end + result = 1 + end + + local colors = {} + + -- If we have color style IDs, lets get their names + if #color_ids > 0 then + for i = 1, #color_ids do + colors[i] = barber_colors[color_ids[i]] + end + + if result == 0 then + result = 2 + else + result = 3 + end + end + + -- Choose an appropriate message + if result == 1 then + do_message(npc, ch, "Hello! What style would you like today?") + elseif result == 2 then + do_message(npc, ch, "Hello! What color would you like today?") + else + do_message(npc, ch, "Hello! What can I do for you today?") + end + + print("#styles ==", #styles) + + -- Repeat until the user selects nothing + repeat + if (result == 1) then -- Do styles + result = do_choice(npc, ch, "Bald", styles, "Supprise me", "Never mind") + + result = result -1 + + --Random + if (result == #styles + 1) then + result = math.random(#styles + 1) - 1 + print("Random") + end + + print("Style ==", result) + + if (result == 0) then + mana.chr_set_hair_style(ch, 0) + result = 1 + elseif (result <= #styles) then + mana.chr_set_hair_style(ch, style_ids[result]) + result = 1 + else --"Never mind" + result = 3 + end + elseif (result == 2) then -- Do colors + result = do_choice(npc, ch, colors, "Supprise me", "Never mind") + + --Random + if (result == #colors + 1) then + result = math.random(#colors) + end + + if (result <= #colors) then + mana.chr_set_hair_color(ch, color_ids[result - 1]) + result = 2 + else --"Never mind" + result = 3 + end + end + + -- If we have both styles and colors, show the main menu + if #styles > 0 and #colors > 0 then + result = do_choice(npc, ch, "Change my style", "Change my color", "Never mind") + end + until result >= 3 --While they've choosen a valid option that isn't "Never mind" + + -- Let's close up + do_message(npc, ch, "Thank you. Come again!") + do_npc_close(npc, ch) +end diff --git a/example/serverdata/scripts/npcs/debugger.lua b/example/serverdata/scripts/npcs/debugger.lua new file mode 100644 index 00000000..6bb86d0a --- /dev/null +++ b/example/serverdata/scripts/npcs/debugger.lua @@ -0,0 +1,101 @@ +---------------------------------------------------------- +-- Seller Function Sample -- +---------------------------------------------------------------------------------- +-- Copyright 2009-2010 The Mana World Development Team -- +-- -- +-- This file is part of The Mana World. -- +-- -- +-- The Mana World is free software; you can redistribute it and/or modify it -- +-- under the terms of the GNU General Public License as published by the Free -- +-- Software Foundation; either version 2 of the License, or any later version. -- +---------------------------------------------------------------------------------- + +function npc1_talk(npc, ch) + on_remove(ch, function() print "Player has left the map." end); + do_message(npc, ch, "Hello! I am the testing NPC.") + local rights = mana.chr_get_rights(ch); + + if (rights >= 128) then + do_message(npc, ch, "Oh mighty server administrator, how can I avoid your wrath?") + elseif (rights >= 8) then + do_message(npc, ch, "How can I be of assistance, sir gamemaster?") + elseif (rights >= 4) then + do_message(npc, ch, "What feature would you like to debug, developer?") + elseif (rights >= 2) then + do_message(npc, ch, "How can I assist you in your testing duties?") + elseif (rights >= 1) then + do_message(npc, ch, "What do you want, lowly player?") + else + do_message(npc, ch, "...aren't you supposed to be banned??") + end + + local v = do_choice(npc, ch, "Guns! Lots of guns!", + "A Christmas party!", + "To make a donation.", + "Slowly count from one to ten.", + "Tablepush Test") + if v == 1 then + do_message(npc, ch, "Sorry, this is a heroic-fantasy game, I do not have any gun.") + + elseif v == 2 then + local n1, n2 = mana.chr_inv_count(ch, 524, 511) + if n1 == 0 or n2 ~= 0 then + do_message(npc, ch, "Yeah right...") + else + do_message(npc, ch, "I can't help you with the party. But I see you have a fancy hat. I could change it into Santa's hat. Not much of a party, but it would get you going.") + v = do_choice(npc, ch, "Please do.", "No way! Fancy hats are classier.") + if v == 1 then + mana.chr_inv_change(ch, 524, -1, 511, 1) + end + end + + elseif v == 3 then + if mana.chr_money_change(ch, -100) then + do_message(npc, ch, string.format("Thank you for you patronage! You are left with %d GP.", mana.chr_money(ch))) + local g = tonumber(get_quest_var(ch, "001_donation")) + if not g then g = 0 end + g = g + 100 + mana.chr_set_quest(ch, "001_donation", g) + do_message(npc, ch, string.format("As of today, you have donated %d GP.", g)) + else + do_message(npc, ch, "I would feel bad taking money from someone that poor.") + end + + elseif v == 4 then + mana.being_say(npc, "As you wish...") + schedule_in(2, function() mana.being_say(npc, "One") end) + schedule_in(4, function() mana.being_say(npc, "Two") end) + schedule_in(6, function() mana.being_say(npc, "Three") end) + schedule_in(8, function() mana.being_say(npc, "Four") end) + schedule_in(10, function() mana.being_say(npc, "Five") end) + schedule_in(12, function() mana.being_say(npc, "Six") end) + schedule_in(14, function() mana.being_say(npc, "Seven") end) + schedule_in(16, function() mana.being_say(npc, "Eight") end) + schedule_in(18, function() mana.being_say(npc, "Nine") end) + schedule_in(20, function() mana.being_say(npc, "Ten") end) + + elseif v == 5 then + function printTable (t) + for k,v in pairs(t) do + print (k, ":", v) + end + end + local t1, t2, t3, t4, t5 = mana.test_tableget(); + print("---------------"); + print ("Table 1:"); + printTable (t1) + print ("Table 2:"); + printTable (t2) + print ("Table 3:"); + printTable (t3) + print ("Table 4:"); + printTable (t4) + print ("Table 5:"); + printTable (t5) + print("---------------"); + end + + do_message(npc, ch, "See you later!") + do_npc_close(npc, ch) +end + diff --git a/example/serverdata/scripts/npcs/emotemaker.lua b/example/serverdata/scripts/npcs/emotemaker.lua new file mode 100644 index 00000000..2e68aa2c --- /dev/null +++ b/example/serverdata/scripts/npcs/emotemaker.lua @@ -0,0 +1,46 @@ +---------------------------------------------------------- +-- Emote use Function Sample -- +---------------------------------------------------------------------------------- +-- Copyright 2009-2010 The Mana World Development Team -- +-- -- +-- This file is part of The Mana World. -- +-- -- +-- The Mana World is free software; you can redistribute it and/or modify it -- +-- under the terms of the GNU General Public License as published by the Free -- +-- Software Foundation; either version 2 of the License, or any later version. -- +---------------------------------------------------------------------------------- + +emo_count = 0 +emo_state = EMOTE_SURPRISE + +function emote_talk(npc, ch) + if emo_state == EMOTE_SURPRISE then + state = "confused" + elseif emo_state == EMOTE_SAD then + state = "sad" + elseif emo_state == EMOTE_HAPPY then + state = "happy" + end + do_message(npc, ch, string.format("The emotional palm seems %s.", state)) + v = do_choice(npc, ch, + "Stupid palm, you are ugly and everyone hates you!", + "You are such a nice palm, let me give you a hug.", + "Are you a cocos nucifera or a syagrus romanzoffiana?") + + if (v == 1) then + emo_state = EMOTE_SAD + elseif (v == 2) then + emo_state = EMOTE_HAPPY + elseif (v == 3) then + emo_state = EMOTE_SURPRISE + end + do_npc_close(npc, ch) +end + +function emote_update(npc) + emo_count = emo_count + 1 + if emo_count > 50 then + emo_count = 0 + mana.effect_create(emo_state, npc) + end +end diff --git a/example/serverdata/scripts/npcs/healer.lua b/example/serverdata/scripts/npcs/healer.lua new file mode 100644 index 00000000..96d29111 --- /dev/null +++ b/example/serverdata/scripts/npcs/healer.lua @@ -0,0 +1,23 @@ +---------------------------------------------------------- +-- Healer Function Sample -- +---------------------------------------------------------------------------------- +-- Copyright 2009-2010 The Mana World Development Team -- +-- -- +-- This file is part of The Mana World. -- +-- -- +-- The Mana World is free software; you can redistribute it and/or modify it -- +-- under the terms of the GNU General Public License as published by the Free -- +-- Software Foundation; either version 2 of the License, or any later version. -- +---------------------------------------------------------------------------------- + +function Healer(npc, ch) + do_message(npc, ch, "Do you need healing?") + local c = do_choice(npc, ch, "Heal me fully", "Heal 100 HP", "Don't heal me") + if c == 1 then + mana.being_heal(ch) + elseif c == 2 then + mana.being_heal(ch, 100) + end + + do_npc_close(npc, ch) +end diff --git a/example/serverdata/scripts/npcs/postman.lua b/example/serverdata/scripts/npcs/postman.lua new file mode 100644 index 00000000..68546bf8 --- /dev/null +++ b/example/serverdata/scripts/npcs/postman.lua @@ -0,0 +1,31 @@ +---------------------------------------------------------- +-- Postman Function Sample -- +---------------------------------------------------------------------------------- +-- Copyright 2009-2010 The Mana World Development Team -- +-- -- +-- This file is part of The Mana World. -- +-- -- +-- The Mana World is free software; you can redistribute it and/or modify it -- +-- under the terms of the GNU General Public License as published by the Free -- +-- Software Foundation; either version 2 of the License, or any later version. -- +---------------------------------------------------------------------------------- + +function post_talk(npc, ch) + do_message(npc, ch, "Hello " .. mana.being_get_name(ch)) + local strength = mana.being_get_attribute(ch, ATTR_STRENGTH) + do_message(npc, ch, "You have " .. tostring(strength) .. " strength") + do_message(npc, ch, "What would you like to do?") + local answer = do_choice(npc, ch, "View Mail", "Send Mail", "Nothing") + if answer == 1 then + local sender, post = getpost(ch) + if sender == "" then + do_message(npc, ch, "No Post right now, sorry") + else + do_message(npc, ch, tostring(sender) .. " sent you " .. tostring(post)) + end + end + if answer == 2 then + do_post(npc, ch) + end + do_npc_close(npc, ch) +end diff --git a/example/serverdata/scripts/npcs/seller.lua b/example/serverdata/scripts/npcs/seller.lua new file mode 100644 index 00000000..c809f3e2 --- /dev/null +++ b/example/serverdata/scripts/npcs/seller.lua @@ -0,0 +1,73 @@ +---------------------------------------------------------- +-- Seller Function Sample -- +---------------------------------------------------------------------------------- +-- Copyright 2009-2010 The Mana World Development Team -- +-- -- +-- This file is part of The Mana World. -- +-- -- +-- The Mana World is free software; you can redistribute it and/or modify it -- +-- under the terms of the GNU General Public License as published by the Free -- +-- Software Foundation; either version 2 of the License, or any later version. -- +---------------------------------------------------------------------------------- + +function Seller(npc, ch) + do_message(npc, ch, "Hello! What can I provide you today?") + local rights = mana.chr_get_rights(ch); + + if (rights >= 128) then + do_message(npc, ch, "Oh mighty server administrator, how can I avoid your wrath?") + elseif (rights >= 8) then + do_message(npc, ch, "How can I be of assistance, sir gamemaster?") + elseif (rights >= 4) then + do_message(npc, ch, "What feature would you like to debug, developer?") + elseif (rights >= 2) then + do_message(npc, ch, "How can I assist you in your testing duties?") + elseif (rights >= 1) then + do_message(npc, ch, "What do you want, lowly player?") + else + do_message(npc, ch, "...Aren't you supposed to be banned??") + end + + local v = do_choice(npc, ch, "To buy...", + "To sell stuff...", + "Can you make me a price for what I have?") + if v == 1 then + -- "To buy." + local buycase = mana.npc_trade(npc, ch, false, { {1, 10, 20}, {2, 10, 30}, {3, 10, 50} }) + if buycase == 0 then + do_message(npc, ch, "What do you want to buy?") + elseif buycase == 1 then + do_message(npc, ch, "I've got no items to sell.") + else + do_message(npc, ch, "Hmm, something went wrong... Ask a scripter to fix the buying mode!") + end + + elseif v == 2 then + + -- "To sell stuff..." + local sellcase = mana.npc_trade(npc, ch, true) + if sellcase == 0 then + do_message(npc, ch, "Ok, what do you want to sell?") + elseif sellcase == 1 then + do_message(npc, ch, "I'm not interested by any of your items.") + else + do_message(npc, ch, "Hmm, something went wrong... Ask a scripter to fix this!") + end + + elseif v == 3 then + + -- "Can you make me a price for what I have?" + local sellcase = mana.npc_trade(npc, ch, true, { {4, 10, 20}, {5, 10, 30}, {6, 10, 200}, {7, 10, 300} }) + if sellcase == 0 then + do_message(npc, ch, "Here we go:") + elseif sellcase == 1 then + do_message(npc, ch, "I'm not that interested in any of your items.") + else + do_message(npc, ch, "Hmm, something went wrong... Ask a scripter to fix me!") + end + + end + do_message(npc, ch, "See you later!") + do_npc_close(npc, ch) +end + diff --git a/example/serverdata/scripts/status/jump.lua b/example/serverdata/scripts/status/jump.lua new file mode 100644 index 00000000..3410747a --- /dev/null +++ b/example/serverdata/scripts/status/jump.lua @@ -0,0 +1,53 @@ +------------------------------------------------------------- +-- This status jumps from being to being -- +-- Thats all it does. -- +---------------------------------------------------------------------------------- +-- Copyright 2009 The Mana World Development Team -- +-- -- +-- This file is part of The Mana World. -- +-- -- +-- The Mana World is free software; you can redistribute it and/or modify it -- +-- under the terms of the GNU General Public License as published by the Free -- +-- Software Foundation; either version 2 of the License, or any later version. -- +---------------------------------------------------------------------------------- + + +function tick(target, ticknumber) + if (ticknumber % 10 == 0) then + mana.being_say(target, "I have the jumping bug!") + end + + if (mana.being_get_status_time(target, 2) < 2000) then + mana.being_set_status_time(target, 2, 6000) + end + + if (ticknumber % 50 ~= 0) then return end + + local victims = mana.get_beings_in_circle(mana.posX(target), mana.posY(target), 64) + local count = #victims + + if i == 0 then return end + + local i + local remaining = 1000 + local victim = nil + + repeat + remaining = remaining - 1 + i = math.random(count) + victim = victims[i] + if (victim == target) then + victim = nil + i = -1 + else + i = mana.being_type(victim) + end + until (i == TYPE_MONSTER or i == TYPE_CHARACTER or remaining == 0) + + if (victim == nil) then return end + + mana.being_remove_status(target, 2) + + mana.being_apply_status(victim, 2, 6000) + mana.being_say(victim, "Now I have the jumping bug") +end diff --git a/example/serverdata/scripts/status/plague.lua b/example/serverdata/scripts/status/plague.lua new file mode 100644 index 00000000..5f98268e --- /dev/null +++ b/example/serverdata/scripts/status/plague.lua @@ -0,0 +1,28 @@ +------------------------------------------------------------- +-- This when applied to a being will spread from one being -- +-- to another -- +-- Thats all it does. -- +---------------------------------------------------------------------------------- +-- Copyright 2009 The Mana World Development Team -- +-- -- +-- This file is part of The Mana World. -- +-- -- +-- The Mana World is free software; you can redistribute it and/or modify it -- +-- under the terms of the GNU General Public License as published by the Free -- +-- Software Foundation; either version 2 of the License, or any later version. -- +---------------------------------------------------------------------------------- + +function tick(target, ticknumber) + if (ticknumber % 10 == 0) then + mana.being_say(target, "I have the plague! :( = " .. ticknumber) + end + local victims = mana.get_beings_in_circle(mana.posX(target), mana.posY(target), 64) + local i = 1 + while (victims[i]) do + if (mana.being_has_status(victims[i], 1) == false) then + mana.being_apply_status(victims[i], 1, 6000) + mana.being_say(victims[i], "I don't feel so good") + end + i = i + 1 + end +end -- cgit v1.2.3-60-g2f50