You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: resources.rs
    path of file: ./repos/veloren/common/src
    
    the code of the file until where you have to start completion: use crate::comp::Pos;
use serde::{Deserialize, Serialize};
use specs::Entity;
use std::ops::{Mul, MulAssign};
use vek::Vec3;

/// A resource that stores the time of day.
#[derive(Copy, Clone, Debug, Serialize, Deserialize, Default)]
pub struct TimeOfDay(pub f64);
impl TimeOfDay {
    pub fn new(t: f64) -> Self { TimeOfDay(t) }

    fn get_angle_rad(self) -> f32 {
 
    
    pub fn new(t: f64) -> Self { TimeOfDay(t) }

    fn get_angle_rad(self) -> f32 {
        const TIME_FACTOR: f64 = (std::f64::consts::PI * 2.0) / (3600.0 * 24.0);
        ((self.0 * TIME_FACTOR) % (std::f64::consts::PI * 2.0)) as f32
    }

    /// Computes the direction of light from the sun based on the time of day.
    pub fn get_sun_dir(self) -> Vec3<f32> {
        let angle_rad = self.get_angle_rad();
        Vec3::new(-angle_rad.sin(), 0.0, angle_rad.cos())
    }

    /// Computes the direction of light from the moon based on the time of day.
    pub fn get_moon_dir(self) -> Vec3<f32> {
        let angle_rad = self.get_angle_rad();
        -Vec3::new(-angle_rad.sin(), 0.0, angle_rad.cos() - 0.5).normalized()
    }
}