share/hedgewars/Data/Scripts/Multiplayer/Racer.lua
changeset 11925 7123bfc9643c
parent 11924 ce277e51b603
child 11926 ace20b1d8d53
equal deleted inserted replaced
11924:ce277e51b603 11925:7123bfc9643c
   278                 NR = (48/100*wpRad)/2
   278                 NR = (48/100*wpRad)/2
   279 
   279 
   280                 if dist < (NR*NR) then
   280                 if dist < (NR*NR) then
   281                 --if dist < (wpRad*wpRad) then
   281                 --if dist < (wpRad*wpRad) then
   282                         --AddCaption("howdy")
   282                         --AddCaption("howdy")
   283                         wpActive[i] = true
       
   284                         wpCol[i] = GetClanColor(GetHogClan(CurrentHedgehog)) -- new                             --GetClanColor(1)
   283                         wpCol[i] = GetClanColor(GetHogClan(CurrentHedgehog)) -- new                             --GetClanColor(1)
   285                         SetVisualGearValues(wpCirc[i], wpX[i], wpY[i], 20, 100, 1, 10, 0, wpRad, 5, wpCol[i])
   284                         SetVisualGearValues(wpCirc[i], wpX[i], wpY[i], 20, 100, 1, 10, 0, wpRad, 5, wpCol[i])
   286 
   285 
   287                         wpRem = 0
   286                         wpRem = 0
   288                         for k = 0, (wpCount-1) do
   287                         for k = 0, (wpCount-1) do
   289                                 if wpActive[k] == false then
   288                                 if wpActive[k] == false then
   290                                         wpRem = wpRem + 1
   289                                         wpRem = wpRem + 1
   291                                 end
   290                                 end
   292                         end
   291                         end
   293 
   292 
   294                         AddCaption(string.format(loc("Waypoints remaining: %d"), wpRem),0xffba00ff,capgrpAmmoinfo)
   293                         if wpActive[i] == false then
       
   294                                 AddCaption(string.format(loc("Waypoints remaining: %d"), wpRem-1),0xffba00ff,capgrpGameState)
       
   295                         end
       
   296                         wpActive[i] = true
   295 
   297 
   296                 end
   298                 end
   297 
   299 
   298                 if wpActive[i] == false then
   300                 if wpActive[i] == false then
   299                         trackFinished = false
   301                         trackFinished = false