Jump to content

Y6GST

+Premium Members
  • Posts

    33
  • Joined

  • Last visited

Posts posted by Y6GST

  1.  

    Not sure why this is happening in your code, but I always add a few extra/redundant "make zone active/visible" statements to make sure my code is executed.

     

    No code involved as such here, I simply set the zone distance property value to be 25 (feet), rather than the default value of -1 (always visible). As I understand it the zone should then only be visible when the player is within 25 feet of it. To remove device specific issues I have decided to make these zones invisible all of the time, it won't affect the player.

     

    By the way, we're familiar with an issue regarding the iOS app's Wherigo.VectorToPoint function not returning a precise measurement. The reason behind this is it's more expensive to run the precise calculation than it is to do a shorthand calculation. The error starts showing up when you use Wherigo.VectorToPoint on longer distances, particularly when you use move all zones within a cartridge to around the user's current location, most notably to create a type of Play Anywhere cartridge. In this example, if the distance between the original cartridge's start position and the user's current position is 700 miles (1100 km), you might end up with a cartridge where the zones are around 100 miles (160 km) away.

     

    As I noted, we're aware of this and have a good idea how to fix it. I do not have an estimated date when the iOS app will be updated.

     

    On a side note, if you move a zone, it must be reactivated for the new coordinates to take effect.

     

    Thanks for this, I have not planned on moving zones around, or making the cartridge play anywhere, but this information is good to know before I come across it in the future :)

  2. I have used this code for the first time today and all went well using the both the Groundspeak emulator, and the WebWigo emulator, it also worked fine in the field on a Garmin Oregon 450, however the iPhone 5 running the Wherigo app only showed the last message in the sequence, none of the dialog messages were shown.

     

    Has an update to the iPhone app meant this script no longer works within it?

  3. In my Distance / Bearing code I was using Wherigo.VectorToZone, I have now changed this to Wherigo VectorToPoint, this small change means that the code now works in the Groundspeak Emulator, the WebWigo Emulator and playing the cartridge on the Garmin Oregon and also the iPhone. Now to work out why zones that should not be visible are visible on the iPhone.

  4. I have managed to get my Distance / Bearing code to work by testing against the Active Zone, I am happy that this is working fine having tested it within the emulator and all is working fine.

     

    I have created my gwz file and uploaded it to Wherigo.com and downloaded a copy of the cartridge for my Oregon 450 and also downloaded a PocketPC file via the Wherigo app on the iPhone, this is where odd things now happen:

     

    The first active and visible zone has the distance range set to 25 feet as I don't want this visible until the player is in close proximity to the zone, on the Oregon this is what is happening, the zone is not visible until then, but on the iPhone I can see the zone despite not being anywhere near the required 25 feet away.

     

    Another issue is with my Distance Checker, in the emulator this works as expected, showing the distance in feet and bearing in degrees to the next active zone, this also works on the Oregon, on the iPhone however I simply get an error message of 'Wherigo VectorToZone not found' followed by 'Lua Alert - Don't know how to call <null>', this message fires twice before I get the message which should show the distance and bearing, however both values are zero.

     

    Has anyone else came across such an error message?

  5. This is my first attempt at branching out from what the Earwigo menu options allow me to do, so I may be making it a bit long winded.

     

    If I pass the zone object itself it all works fine, I have tried to explain what I have done so far below:

     

    I have the function above in my Author Script, I then have an Earwigo function that calls this function and stores the distance/bearing string in a variable. The player has an item that sits in their inventory named Distance Checker, this item has an event attached to it named Show Distance, the user clicks this button which calls the above Earwigo function, passing the zone name (currently hard coded to the zone object), it then shows a message that simply shows the value of the variable, this does exactly what I want.

     

    However the cartridge has multiple zones which only one will be active at any time (but not visible) so I was hoping that I could assign the next zone into a variable so I could reuse the above code by simply passing the variable.

     

    I guess I could do more within the Author Script itself, but only just getting to grips with the syntax.

     

    For me to view the functions you have written in your battleship cartridge do I simply download it and open it up in a text editor?

     

    Thanks for all your help so far, much appreciated.

  6. I have got it working by adding a function to the Author Script part of Earwigo.

     

    function getDistanceBearing(input)
    
     current = Player.ObjectLocation;
     distance, bearing = Wherigo.VectorToZone(current,input);
    
     feet = distance:GetValue"ft";
     feet = math.floor(feet);
     degrees = math.floor(bearing);
    
     if # Player.InsideOfZones > 0 then 
       varZone = "You are inside the zone"
     else
       varZone = "The next zone is " .. feet .. " feet away on a bearing of " .. degrees .. " degrees.";
     end
    
     return varZone;
    
    end
    

     

    This works fine when passing a 'Zone' for the parameter named 'input', however so the code can be reused I would like to pass in a variable which is set to the zone name, however when I do this I get an error of 'Second argument must be a Zone object.' which makes sense as I am passing in a string variable, but I cannot see anyway of converting it to a Zone object.

  7. The Church Micro stat image on the individual cache listing page isn't working correctly if the cache has been set by someone with a space in their geocaching name, the image shows the name with the space replaced with a plus sign, followed by the message "hasn't got any Church Micro finds in the database yet."

  8. The bad news is that you'll have to wait until the weekend! I want to take the opportunity to put in a panel that will list the names and GC numbers of all the caches on the map...

     

    Thank you, it is only when things break you realise how much you use them. Looking forward to the other updates too.

  9. Since the recent site update the map on the cache page underneath 'View Larger Map' will no longer show the map if Bing Maps, Bing Ariel View or Ordnance Survey is selected, the three Google options do work fine however.

     

    I have no such problem on the main map page where you view all geocaches, here all the maps work fine.

     

    Just wondering if anyone else has this issue?

  10. I am the idiot in question, probably a deserved comment, although I do object to being called a liar! I'm not posting for an argument or any such drama, just to give my side.

     

    My log, which has been posted by someone else earlier in this thread is my story of what happened, I did come across the archer twice, once he told me I was going the wrong way around a course and he asked me where I was going, I said about 120 feet 'that way' I did say that I had seen the signs, but they only warned of the 3rd Sunday of each month, given it was a Saturday I thought it safe to proceed into the wooded area, after finding the cache I then found the archer again. He asked me if I was Geocaching, I said Yes, he said his kids do that and was there one in the woods, i said yes and he told me that members can practice at all times of all days, so he would like the geocache removed, I said I would contact the CO asking them to do so when I got home, i then asked if i should go out the way i came, he said yes. When i got home i emailed the CO and they archived the cache after receiving my email.

     

    In hindsight perhaps I should have asked for the archers contact details, so I could report the progress back to him, but I never, that is hindsight for you.

     

    So in summary the end result is thankfully no-one got hurt, the cache has been archived and no geocachers will risk injury from the archers, a good result all round I think.

     

    A lesson learned for me too, just because a geocache is there doesn't mean you have to look for it, I will also report, without fail, geocache placements that I feel are dangerous, as I did in this case, I would also like to thank the CO for their prompt action in archiving this cache.

     

    The End

     

    Edited for dodgy spelling.

  11. But it seems that the finders were pre-warned of its publication,, making it look like it was set up purely to provide them with FTFs (there were 26 joint FTFs - some didn't even leave the curry house but had the cache brought to them :blink: )

     

    Kind of devalues those who keep stats on months of consecutive FTF's, I wonder who was FTBHTC (First to be handed the cache)?

     

    A bit of fun, but clearly against the rules, I guess this is a downside of having caches published at a particular time...

  12. Hi gas_zippy Thanks a lot that is exactaly what I wanted Fantastic!!!!!!

    I will be able to play for hours A realy big THANK YOU

    Regards David :P :P :D

     

    No problem, glad you found it useful, it was good for me to revisit the Cassandy blog post as there is more things listed that I forgot it does as well!

×
×
  • Create New...