A little girl loves problems on trees very much. Here's one of them.

A tree is an undirected connected graph, not containing cycles. The degree of node x in the tree is the number of nodes y of the tree, such that each of them is connected with node x by some edge of the tree. 

Let's consider a tree that consists of n nodes. We'll consider the tree's nodes indexed from 1 to n. The cosidered tree has the following property: each node except for node number 1 has the degree of at most 2.

Initially, each node of the tree contains number 0. Your task is to quickly process the requests of two types:

  * Request of form: 0 v x d. In reply to the request you should add x to all numbers that are written in the nodes that are located at the distance of at most d from node v. The distance between two nodes is the number of edges on the shortest path between them. 
  * Request of form: 1 v. In reply to the request you should print the current number that is written in node v. 

Input

The first line contains integers n (2 ≤ n ≤ 105) and q (1 ≤ q ≤ 105) — the number of tree nodes and the number of requests, correspondingly.

Each of the next n - 1 lines contains two integers ui and vi (1 ≤ ui, vi ≤ n, ui ≠ vi), that show that there is an edge between nodes ui and vi. Each edge's description occurs in the input exactly once. It is guaranteed that the given graph is a tree that has the property that is described in the statement.

Next q lines describe the requests.

  * The request to add has the following format: 0 v x d (1 ≤ v ≤ n, 1 ≤ x ≤ 104, 1 ≤ d < n). 
  * The request to print the node value has the following format: 1 v (1 ≤ v ≤ n). 



The numbers in the lines are separated by single spaces.

Output

For each request to print the node value print an integer — the reply to the request.

Examples

Input

3 6
1 2
1 3
0 3 1 2
0 2 3 1
0 1 5 2
1 1
1 2
1 3


Output

9
9
6


Input

6 11
1 2
2 5
5 4
1 6
1 3
0 3 1 3
0 3 4 5
0 2 1 4
0 1 5 5
0 4 6 2
1 1
1 2
1 3
1 4
1 5
1 6


Output

11
17
11
16
17
11
import java.awt.Point;
import java.io.BufferedReader;
import java.io.BufferedWriter;
import java.io.IOException;
import java.io.InputStreamReader;
import java.io.OutputStreamWriter;
import java.io.PrintWriter;
import java.util.ArrayList;
import java.util.StringTokenizer;


public class E {
    
    static StringTokenizer st;
    static BufferedReader in;
    static ArrayList<Integer>[]ages;
    static int n;
    
    public static void main(String[] args) throws IOException {
        in = new BufferedReader(new InputStreamReader(System.in));
        PrintWriter pw = new PrintWriter(new BufferedWriter(new OutputStreamWriter(System.out)));
        n = nextInt();
        int q = nextInt();
        ages = new ArrayList[n+1];
        for (int i = 1; i <= n; i++) {
            ages[i] = new ArrayList<Integer>();
        }
        for (int i = 1; i < n; i++) {
            int v1 = nextInt();
            int v2 = nextInt();
            ages[v1].add(v2);
            ages[v2].add(v1);
        }
        int root = 1;
        int[][]t = new int[2][4*n];
        int[][][]tr = new int[ages[root].size()][2][];
        boolean[]used = new boolean[n+1];
        int[]path = new int[n+1];
        int[]dis = new int[n+1];
        used[root] = true;
        int[]size = new int[ages[root].size()];
        for (int i = 0; i < ages[root].size(); i++) {
            int to = ages[root].get(i);
            used[to] = true;
            size[i] = 2;
            int v = to;
            path[to] = i;
            dis[to] = 1;
            while (true) {
                if (ages[v].size()==1)
                    break;
                for (int j : ages[v]) {
                    if (!used[j]) {
                        used[j] = true;
                        dis[j] = dis[v]+1;
                        path[j] = i;
                        v = j;
                        size[i]++;
                    }
                }
            }
            tr[i][0] = new int[4*size[i]];
            tr[i][1] = new int[4*size[i]];
        }
        for (int i = 1; i <= q; i++) {
            int tip = nextInt();
            if (tip==0) {
                int v = nextInt();
                int x = nextInt();
                int d = nextInt();
                if (v==1) {
                    inc(t, 1, 1, n, 1, d+1, x);
                }
                else {
                    int path_ = path[v];
                    inc(tr[path_], 1, 1, size[path_], Math.max(2, dis[v]+1-d), Math.min(size[path_], dis[v]+1+d), x);
                    if (dis[v] <= d)  {
                        inc(t, 1, 1, n, 1, d-dis[v]+1, x);
                        inc(tr[path_], 1, 1, size[path_], 2, d-dis[v]+1, -x);
                    }
                }
            }
            else {
                int v = nextInt();
                if (v==1)
                    pw.println(get(t, 1, 1, n, 1, 0));
                else {
                    int ans = get(tr[path[v]], 1, 1, size[path[v]], dis[v]+1, 0);
                    ans += get(t, 1, 1, n, dis[v]+1, 0);
                    pw.println(ans);
                }
            }
        }
        pw.close();
    }
    private static int get(int[][] t1, int v, int tl, int tr, int ind, int sum) {
        if (tl==tr)
            return t1[0][v]+sum;
        int tm = (tl+tr) >> 1;
        if (ind <= tm)
            return get(t1, 2*v, tl, tm, ind, sum+t1[1][v]);
        return get(t1, 2*v+1, tm+1, tr, ind, sum+t1[1][v]);
    }
    private static void inc(int[][] t1, int v, int tl, int tr, int L, int R, int delta) {
        if (L > R)
            return;
        if (tl==L && tr==R) {
            t1[1][v] += delta;
            t1[0][v] += delta*(tr-tl+1);
            return;
        }
        int tm = (tl+tr) >> 1;
        if (2*v < t1[0].length) {
            t1[0][2*v] += t1[1][v]*(tm-tl+1);
            t1[1][2*v] += t1[1][v];
        }
        if (2*v+1 < t1[0].length) {
            t1[0][2*v+1] += t1[1][v]*(tr-tm);
            t1[1][2*v+1] += t1[1][v];
        }
        t1[1][v] = 0;
        if (2*v < t1[0].length)
            inc(t1, 2*v, tl, tm, L, Math.min(R, tm), delta);
        if (2*v+1 < t1[0].length)
            inc(t1, 2*v+1, tm+1, tr, Math.max(L, tm+1), R, delta);
        t1[0][v] = 0;
        if (2*v < t1[0].length)
            t1[0][v] += t1[0][2*v];
        if (2*v+1 < t1[0].length)
            t1[0][v] += t1[0][2*v+1];
    }
    
    private static int nextInt() throws IOException{
        return Integer.parseInt(next());
    }
    
    private static long nextLong() throws IOException{
        return Long.parseLong(next());
    }
    
    private static double nextDouble() throws IOException{
        return Double.parseDouble(next());
    }
    
    private static String next() throws IOException {
        while (st == null || !st.hasMoreTokens()) {
            st = new StringTokenizer(in.readLine());
        }
        return st.nextToken();
    }
}