只想绘制两个平行平面,并在其上放置分组元素。您能帮忙对平面上的分组提供一些帮助吗?
\begin{tikzpicture}[scale=2,every node/.style={minimum size=1cm},on grid]
\begin{scope}[
yshift=-100,xshift=-100,every node/.append style={
yslant=0.5,xslant=-1.0},yslant=0.5,xslant=-1.0
]
\fill[white,fill opacity=0.9] (0,0) rectangle (2,2);
\draw[step=2mm, thin, gray] (0,0) grid (2,2); %defining grids
\draw[black,very thick] (0,0) rectangle (2,2);%marking borders
\end{scope}
\begin{scope}[
yshift=-160,every node/.append style={
yslant=0.5,xslant=-1.3},yslant=0.5,xslant=-1.3
]
%marking border
\draw[black,very thick] (0,0) rectangle (2,2);
\end{scope} %end of drawing grids
\end{tikzpicture}
想要拥有这样的东西:
多谢!
答案1
像这样吗?
在部分完成您的 MWE(不完整的猜测 - 没有全部起作用)后,我删除了未定义的内容和不起作用的内容。
\documentclass[border=10pt,multi,tikz]{standalone}
\begin{document}
\begin{tikzpicture}
\begin{scope}[
xshift=-200,
yslant=0.5,
xslant=-1
]
\draw [step=5mm, thin, gray] (0,0) grid (5,5); %defining grids
\draw [black, thick] (0,0) rectangle (5,5);%marking borders
\draw [red, ultra thick] (0,0) |- (3,3) |- (1.5,1.5) |- cycle;
\draw [yellow, ultra thick] (2,0) |- (1,1.5) |- (4,4) |- cycle;
\filldraw (4.75,0.25) coordinate (a) circle (1.5pt);
\end{scope}
\begin{scope}[
yshift=-120,
yslant=0.5,
xslant=-1.3
]
%marking border
\draw[black,thick] (0,0) rectangle (5,5);
\draw [red, ultra thick] (0,0) |- (3,3) |- (1.5,1.5) |- cycle;
\draw [yellow, ultra thick] (2,0) |- (1,1.5) |- (4,4) |- cycle;
\filldraw (4.75,0.25) coordinate (b) circle (1.5pt);
\end{scope} %end of drawing grids
\draw [->, ultra thick, shorten >=2.5pt, shorten <=2.5pt] (a) -- (b);
\end{tikzpicture}
\end{document}