mail[Wesnoth-commits] r20418 - /trunk/data/campaigns/Under_the_Burning_Suns/scenarios/02_Harsh_Sands.cfg


Others Months | Index by Date | Thread Index
>>   [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Header


Content

Posted by ravanrooke on September 16, 2007 - 00:45:
Author: rhuvaen
Date: Sun Sep 16 00:44:56 2007
New Revision: 20418

URL: http://svn.gna.org/viewcvs/wesnoth?rev=20418&view=rev
Log:
Across the Harsh Sands: fixing the mobilization and dialogue of the bandit 
and ogre encounter. Partial fix to the Lost Souls' appearance.

Modified:
    trunk/data/campaigns/Under_the_Burning_Suns/scenarios/02_Harsh_Sands.cfg

Modified: 
trunk/data/campaigns/Under_the_Burning_Suns/scenarios/02_Harsh_Sands.cfg
URL: 
http://svn.gna.org/viewcvs/wesnoth/trunk/data/campaigns/Under_the_Burning_Suns/scenarios/02_Harsh_Sands.cfg?rev=20418&r1=20417&r2=20418&view=diff
==============================================================================
--- trunk/data/campaigns/Under_the_Burning_Suns/scenarios/02_Harsh_Sands.cfg 
(original)
+++ trunk/data/campaigns/Under_the_Burning_Suns/scenarios/02_Harsh_Sands.cfg 
Sun Sep 16 00:44:56 2007
@@ -109,6 +109,7 @@
     [/side]
 
     #Random monster side: ogres, scorpions
+    # they target side 1 much more than side 2
     [side]
         no_leader=yes
         side=3
@@ -130,7 +131,7 @@
 
             [target]
                 side=1
-                value=4
+                value=16
             [/target]
             
             [target]
@@ -299,6 +300,21 @@
             description=Kaleh
             message= _ "Well, the sooner we reach Pinnacle Rock, the better. 
Onwards!"
         [/message]
+        
+        # setup ghost difficulty
+#ifdef EASY
+             {VARIABLE max_ghosts 6}
+             {VARIABLE max_per_turn 2}
+#endif
+#ifdef MEDIUM
+             {VARIABLE max_ghosts 7}
+             {VARIABLE max_per_turn 3}
+#endif
+#ifdef HARD
+             {VARIABLE max_ghosts 8}
+             {VARIABLE max_per_turn 4}
+#endif
+        
     [/event]
 
     #!***Scraped clock-> This can be achieved without dedicated event***
@@ -335,10 +351,31 @@
   [/store_unit]
   {FOREACH enemy i}
      {CLEAR_VARIABLE enemy[$i].ai_special}
-     [unstore_unit]
-       variable=enemy[$i]
-       find_vacant=no
-     [/unstore_unit]
+     [unit]
+       side={SIDE}
+       type=$enemy[$i].type
+       user_description=$enemy[$i].user_description
+       facing=$enemy[$i].facing
+       gender=$enemy[$i].gender
+       x=$enemy[$i].x
+       y=$enemy[$i].y
+       hitpoints=$enemy[$i].hitpoints
+       random_traits=no
+       canrecruit=$enemy[$i].canrecruit
+       experience=$enemy[$i].experience
+       role=$enemy[$i].role
+       moves=$enemy[$i].moves
+       attacks_left=$enemy[$i].attacks_left
+       [status]
+         slowed=$enemy[$i].status.slowed
+         poisoned=$enemy[$i].status.poisoned
+       [/status]
+       [variables]
+         dehydrated=$enemy[$i].variables.dehydrated
+         full_hitpoints=$enemy[$i].variables.full_hitpoints
+         max_hitpoints=$enemy[$i].variables.max_hitpoints
+       [/variables]
+     [/unit]
   {NEXT i}
 #enddef
 
@@ -584,18 +621,28 @@
     #Easy: 1 ogre, 4 young ogres
 
     {RANDOM_PLACEMENT 17 49 2 ({CREATE_UNIT 3 "Ogre" 1 1 "Hunting Ogre" 
(user_description=_"Hunting Ogre"
-    ai_special="guardian")})}
+      role="Hunting Ogre"
+      random_traits="no"
+      ai_special="guardian")})}
     {RANDOM_PLACEMENT 17 49 2 ({CREATE_UNIT 3 "Young Ogre" 1 1 "Hunting 
Ogre" (user_description=_"Hunting Ogre"
-    ai_special="guardian")})}
+      role="Hunting Ogre"
+      random_traits="no"
+      ai_special="guardian")})}
     {RANDOM_PLACEMENT 17 49 2 ({CREATE_UNIT 3 "Young Ogre" 1 1 "Hunting 
Ogre" (user_description=_"Hunting Ogre"
-    ai_special="guardian")})}
+      role="Hunting Ogre"
+      random_traits="no"
+      ai_special="guardian")})}
     {RANDOM_PLACEMENT 17 49 2 ({CREATE_UNIT 3 "Young Ogre" 1 1 "Hunting 
Ogre" (user_description=_"Hunting Ogre"
-    ai_special="guardian")})}
+      role="Hunting Ogre"
+      random_traits="no"
+      ai_special="guardian")})}
 
 #ifdef EASY
 
     {RANDOM_PLACEMENT 17 49 2 ({CREATE_UNIT 3 "Young Ogre" 1 1 "Hunting 
Ogre" (user_description=_"Hunting Ogre"
-    ai_special="guardian")})}
+      role="Hunting Ogre"
+      random_traits="no"
+      ai_special="guardian")})}
 
 #endif
 
@@ -604,7 +651,9 @@
     #Medium: 2 ogres, 3 young ogres
 
     {RANDOM_PLACEMENT 17 49 2 ({CREATE_UNIT 3 "Ogre" 1 1 "Hunting Ogre" 
(user_description=_"Hunting Ogre"
-    ai_special="guardian")})}
+      role="Hunting Ogre"
+      random_traits="no"
+      ai_special="guardian")})}
 
 #endif
 
@@ -613,7 +662,9 @@
 #ifdef HARD
 
     {RANDOM_PLACEMENT 17 49 2 ({CREATE_UNIT 3 "Ogre" 1 1 "Hunting Ogre" 
(user_description=_"Hunting Ogre"
-    ai_special="guardian")})}
+      role="Hunting Ogre"
+      random_traits="no"
+      ai_special="guardian")})}
 
 #endif
 
@@ -696,13 +747,13 @@
             name=die
             first_time_only=no
             [filter]
-                description=Hunting Ogre
+                role="Hunting Ogre"
             [/filter]
 
             [if]
                 [not]
                     [have_unit]
-                        description=Hunting Ogre
+                        role="Hunting Ogre"
                     [/have_unit]
                 [/not]
 
@@ -768,31 +819,40 @@
                         description=Garak
                         message=_"It's a dust devil, but I have never seen 
one so small before."
                     [/message]
-
-                    {VARIABLE fake[0].x $x1}
-                    {VARIABLE fake[1].x $x1}
-                    {VARIABLE fake[2].x $x1}
-
-                    {VARIABLE fake[0].y $x1}
-                    {VARIABLE fake[1].y $x1}
-                    {VARIABLE fake[2].y $x1}
-
-                    {ADD fake[0].x 1}
-                    {ADD fake[1].x 0}
-                    {ADD fake[2].x -1}
-
-                    {ADD fake[0].y 1}
-                    {ADD fake[1].y 0}
-                    {ADD fake[2].y -1}
+                    
+                    [store_locations]
+                      variable=move
+                      x=$x1
+                      y=$y1
+                      radius=1
+                      [not]
+                        [filter]
+                        [/filter]
+                      [/not]
+                    [/store_locations]
+                    
+                    {VARIABLE i 0}
+                    [while]
+                      [variable]
+                        name=i
+                        less_than=4
+                      [/variable]
+                      [do]
+                        {RANDOM 1..move.length}
+                        {VARIABLE moves[$i].x $move[$random].x}
+                        {VARIABLE moves[$i].y $move[$random].y}
+                      [/do]
+                    [/while]
+                    #{CLEAR_VARIABLE move}
 
                     [move_unit_fake]
                         type=Dust Devil
                         side=1
-                        x=$fake[0].x,$fake[1].x,$fake[2].x
-                        y=$fake[1].y,$fake[2].y,$fake[0].y
+                        
x=$moves[0].x,$x1,$moves[1].x,$x1,$moves[2].x,$x1,$moves[3].x,$x1
+                        
y=$moves[0].y,$y1,$moves[1].y,$y1,$moves[2].y,$y1,$moves[3].y,$y1
                     [/move_unit_fake]
 
-                    {CLEAR_VARIABLE fake}
+                    #{CLEAR_VARIABLE moves}
 
                     [message]
                         description=Kaleh
@@ -804,9 +864,6 @@
                         message=_"No buts, girl, I told you not to open it. 
Let's go; I'd really like to get to an oasis soon."
                     [/message]
                 [/then]
-
-                [else]
-                [/else]
             [/if]
         [/event]
 
@@ -837,21 +894,29 @@
         #Hard: 2 trappers, 2 bandits, 2 thugs, 2 poachers
 
         {RANDOM_PLACEMENT 6 43 3 ({CREATE_UNIT 2 "Trapper" 1 1 "Black 
Lieutenant" (user_description=_"Black Lieutenant"
+          role="Black Lieutenant"
+          random_traits="no"
           ai_special="guardian")})}
         {RANDOM_PLACEMENT 6 43 3 ({CREATE_UNIT 2 "Thug" 1 1 "Patrol Bandit" 
(user_description=_"Black Hand Bandit"
+          random_traits="no"
           ai_special="guardian")})}
-        {RANDOM_PLACEMENT 6 43 3 ({CREATE_UNIT 2 "Thug" 1 1 "Patrol Bandit" 
(user_description=_"Black Hand Bandit" 
+        {RANDOM_PLACEMENT 6 43 3 ({CREATE_UNIT 2 "Thug" 1 1 "Patrol Bandit" 
(user_description=_"Black Hand Bandit"
+          random_traits="no"
           ai_special="guardian")})}
         {RANDOM_PLACEMENT 6 43 3 ({CREATE_UNIT 2 "Poacher" 1 1 "Patrol 
Bandit" (user_description=_"Black Hand Bandit"
+          random_traits="no"
           ai_special="guardian")})}
         {RANDOM_PLACEMENT 6 43 3 ({CREATE_UNIT 2 "Poacher" 1 1 "Patrol 
Bandit" (user_description=_"Black Hand Bandit"
+          random_traits="no"
           ai_special="guardian")})}
 
 #ifdef EASY
 
         {RANDOM_PLACEMENT 6 43 3 ({CREATE_UNIT 2 "Thug" 1 1 "Patrol Bandit" 
(user_description=_"Black Hand Bandit"
+          random_traits="no"
           ai_special="guardian")})}
         {RANDOM_PLACEMENT 6 43 3 ({CREATE_UNIT 2 "Poacher" 1 1 "Patrol 
Bandit" (user_description=_"Black Hand Bandit"
+          random_traits="no"
           ai_special="guardian")})}
 
 #endif
@@ -859,10 +924,13 @@
 #ifdef MEDIUM
 
         {RANDOM_PLACEMENT 6 43 3 ({CREATE_UNIT 2 "Bandit" 1 1 "Patrol 
Bandit" (user_description=_"Black Hand Bandit"
+          random_traits="no"
           ai_special="guardian")})}
         {RANDOM_PLACEMENT 6 43 3 ({CREATE_UNIT 2 "Thug" 1 1 "Patrol Bandit" 
(user_description=_"Black Hand Bandit"
+          random_traits="no"
           ai_special="guardian")})}
         {RANDOM_PLACEMENT 6 43 3 ({CREATE_UNIT 2 "Poacher" 1 1 "Patrol 
Bandit" (user_description=_"Black Hand Bandit"
+          random_traits="no"
           ai_special="guardian")})}
 
 #endif
@@ -870,14 +938,18 @@
 #ifdef HARD
 
         {RANDOM_PLACEMENT 6 43 3 ({CREATE_UNIT 2 "Trapper" 1 1 "Patrol 
Bandit" (user_description=_"Black Hand Bandit"
+          random_traits="no"
           ai_special="guardian")})}
         {RANDOM_PLACEMENT 6 43 3 ({CREATE_UNIT 2 "Bandit" 1 1 "Patrol 
Bandit" (user_description=_"Black Hand Bandit"
+          random_traits="no"
           ai_special="guardian")})}
         {RANDOM_PLACEMENT 6 43 3 ({CREATE_UNIT 2 "Bandit" 1 1 "Patrol 
Bandit" (user_description=_"Black Hand Bandit"
+          random_traits="no"
           ai_special="guardian")})}
 
 #endif
         {SETUP_ENEMY_THIRST 2}
+        {VARIABLE ogres_killed 0}
         [if]
             [have_unit]
                 side=1
@@ -908,7 +980,7 @@
                     [/filter]
 
                     [filter_second]
-                        description=Patrol Bandit
+                        role=Black Lieutenant
                     [/filter_second]
                     
                     [if]
@@ -919,7 +991,7 @@
                       [then]
 
                         [message]
-                            description=Black Lieutenant
+                            role=Black Lieutenant
                             message= _ "We don't know who you are, and we 
don't much care. Tremble before the might of the Black Hand!"
                         [/message]
 
@@ -947,7 +1019,7 @@
                   {MOBILIZE_SIDE 2}
                 [/event]
                 [event]
-                  name=attack
+                  name=sighted
                   [filter]
                     side=2
                   [/filter]
@@ -962,7 +1034,7 @@
                     [then]
                     
                         [message]
-                            description=Black Lieutenant
+                            role=Black Lieutenant
                             message= _ "We don't know who you are, and we 
don't much care. Tremble before the might of the Black Hand!"
                         [/message]
 
@@ -979,6 +1051,7 @@
                 # a player unit being killed by an ogre
                 [event]
                   name=die
+                  first_time_only=no
                   [filter]
                     side=1
                   [/filter]
@@ -988,7 +1061,18 @@
                        type=Giant Scorpion
                      [/not]
                   [/filter_second]
-                  {MOBILIZE_SIDE 2}
+                  [if]
+                    [variable]
+                      name=ogres_killed
+                      equals=3
+                    [/variable]
+                    [then]
+                      {MOBILIZE_SIDE 2}
+                    [/then]
+                    [else]
+                      {VARIABLE_OP ogres_killed add 1}
+                    [/else]
+                  [/if]
                  [/event]
                  # an ogre being killed by a player unit
                  [event]
@@ -1371,27 +1455,35 @@
 
                 #in all 3 difficulties, there are at least 1 ogre and 1 
young ogre
 
-                {RANDOM_PLACEMENT 34 27 3 ({CREATE_UNIT 3 "Ogre" 1 1 "Ogre 
Nomad" (user_description=_"Ogre Nomad")})}
-                {RANDOM_PLACEMENT 34 27 3 ({CREATE_UNIT 3 "Young Ogre" 1 1 
"Ogre Nomad" (user_description=_"Ogre Nomad")})}
+                {RANDOM_PLACEMENT 34 27 3 ({CREATE_UNIT 3 "Ogre" 1 1 "Ogre 
Nomad" (user_description=_"Ogre Nomad"
+                  random_traits="no")})}
+                {RANDOM_PLACEMENT 34 27 3 ({CREATE_UNIT 3 "Young Ogre" 1 1 
"Ogre Nomad" (user_description=_"Ogre Nomad"
+                  random_traits="no")})}
 
 #ifdef EASY
 
-                {RANDOM_PLACEMENT 34 27 3 ({CREATE_UNIT 3 "Young Ogre" 1 1 
"Ogre Nomad" (user_description=_"Ogre Nomad")})}
-                {RANDOM_PLACEMENT 34 27 3 ({CREATE_UNIT 3 "Young Ogre" 1 1 
"Ogre Nomad" (user_description=_"Ogre Nomad")})}
+                {RANDOM_PLACEMENT 34 27 3 ({CREATE_UNIT 3 "Young Ogre" 1 1 
"Ogre Nomad" (user_description=_"Ogre Nomad"
+                  random_traits="no")})}
+                {RANDOM_PLACEMENT 34 27 3 ({CREATE_UNIT 3 "Young Ogre" 1 1 
"Ogre Nomad" (user_description=_"Ogre Nomad"
+                  random_traits="no")})}
 
 #endif
 
 #ifdef MEDIUM
 
-                {RANDOM_PLACEMENT 34 27 3 ({CREATE_UNIT 3 "Young Ogre" 1 1 
"Ogre Nomad" (user_description=_"Ogre Nomad")})}
-                {RANDOM_PLACEMENT 34 27 3 ({CREATE_UNIT 3 "Ogre" 1 1 "Ogre 
Nomad" (user_description=_"Ogre Nomad")})}
+                {RANDOM_PLACEMENT 34 27 3 ({CREATE_UNIT 3 "Young Ogre" 1 1 
"Ogre Nomad" (user_description=_"Ogre Nomad"
+                  random_traits="no")})}
+                {RANDOM_PLACEMENT 34 27 3 ({CREATE_UNIT 3 "Ogre" 1 1 "Ogre 
Nomad" (user_description=_"Ogre Nomad"
+                  random_traits="no")})}
 
 #endif
 
 #ifdef HARD
 
-                {RANDOM_PLACEMENT 34 27 3 ({CREATE_UNIT 3 "Ogre" 1 1 "Ogre 
Nomad" (user_description=_"Ogre Nomad")})}
-                {RANDOM_PLACEMENT 34 27 3 ({CREATE_UNIT 3 "Ogre" 1 1 "Ogre 
Nomad" (user_description=_"Ogre Nomad")})}
+                {RANDOM_PLACEMENT 34 27 3 ({CREATE_UNIT 3 "Ogre" 1 1 "Ogre 
Nomad" (user_description=_"Ogre Nomad"
+                  random_traits="no")})}
+                {RANDOM_PLACEMENT 34 27 3 ({CREATE_UNIT 3 "Ogre" 1 1 "Ogre 
Nomad" (user_description=_"Ogre Nomad"
+                  random_traits="no")})}
 
 #endif
 
@@ -1795,9 +1887,9 @@
     [/variable]
     [then]
       {VARIABLE_OP thirst add 1}
-      {VARIABLE green -25}
+      {VARIABLE green -30}
       {VARIABLE_OP green multiply $thirst}
-      {VARIABLE_OP green add 265}
+      {VARIABLE_OP green add 280}
       [if]
         [variable]
           name=green
@@ -2082,10 +2174,10 @@
         {NEXT i}
       [/then]
     [/if]
-    # event on next select
+    # event on next turn refresh
     # that reapplies max hitpoints - for representational purposes
     [event]
-      name=select
+      name=turn refresh
       [store_unit]
         variable=player_unit
         kill=no
@@ -2227,12 +2319,6 @@
                   numerical_equals=7
               [/variable]
           [/or]
-          [or]
-              [variable]
-                 name=ghosts_already_spawned
-                 greater_than_equal_to=$max_ghosts
-              [/variable]
-          [/or]
           [then]
              # reset the ghosts spawned counter
              {VARIABLE ghosts_already_spawned 0}
@@ -2242,7 +2328,13 @@
                   fire_event=no
               [/kill]
           [/then]
-          [else]
+      [/if]
+      [if]
+          [variable]
+            name=ghosts_already_spawned
+            less_than=$max_ghosts
+          [/variable]
+          [then]
                 
           # store "exposed" units - those surrounded by a lot of desert      
    
           [store_locations]
@@ -2278,23 +2370,17 @@
              {VARIABLE_OP ghosts add $added_ghosts}
              {VARIABLE_OP ghosts add 2}
              {VARIABLE_OP ghosts divide 4}
-             {VARIABLE max_ghosts 6}
-             {VARIABLE max_per_turn 2}
 #endif
 #ifdef MEDIUM
              # 1 ghost per 2 exposed units (roughly) per turn
              {VARIABLE_OP ghosts add $added_ghosts}
              {VARIABLE_OP ghosts divide 2}
-             {VARIABLE max_ghosts 7}
-             {VARIABLE max_per_turn 3}
 #endif
 #ifdef HARD
              # 1 ghost per 1.5 exposed units (roughly) per turn
              {VARIABLE_OP ghosts multiply 2}
              {VARIABLE_OP ghosts add $added_ghosts}
              {VARIABLE_OP ghosts divide 3}
-             {VARIABLE max_ghosts 8}
-             {VARIABLE max_per_turn 4}
 #endif
              {CLEAR_VARIABLE added_ghosts}
              # limit ghost appearance rate
@@ -2374,7 +2460,7 @@
              {CLEAR_VARIABLE ghost_spawn}
            [/then]
          [/if]
-        [/else]
+        [/then]
       [/if] 
       {CLEAR_VARIABLE turn_temp}
     [/event]




Related Messages


Powered by MHonArc, Updated Sun Sep 16 06:41:50 2007