/// <summary> /// Builds a strongly-typed map pin by the local variables stored on a player. /// </summary> /// <param name="player">The player whose map pin information we're retrieving</param> /// <param name="index">The index of the map pin.</param> /// <returns>A strongly-typed struct containing a specific map pin's details.</returns> private static MapPinDetails GetMapPinDetails(uint player, int index) { index++; MapPinDetails mapPin = new MapPinDetails() { Text = GetLocalString(player, "NW_MAP_PIN_NTRY_" + index), PositionX = GetLocalFloat(player, "NW_MAP_PIN_XPOS_" + index), PositionY = GetLocalFloat(player, "NW_MAP_PIN_YPOS_" + index), }; return(mapPin); }
protected static MapPinDetails GetMapPinDetails(NWGameObject oPC, int index) { index++; MapPinDetails mapPin = new MapPinDetails() { Text = GetLocalString(oPC, "NW_MAP_PIN_NTRY_" + index), PositionX = GetLocalFloat(oPC, "NW_MAP_PIN_XPOS_" + index), PositionY = GetLocalFloat(oPC, "NW_MAP_PIN_YPOS_" + index), Area = GetLocalObject(oPC, "NW_MAP_PIN_AREA_" + index), Tag = GetLocalString(oPC, "CUSTOM_NW_MAP_PIN_TAG_" + index), Player = oPC, Index = index }; return(mapPin); }