Feature In-Game Compass #27
@ -388,7 +388,7 @@
|
||||
|
||||
// update the compass
|
||||
const heading = Game.panorama.getPov().heading;
|
||||
document.getElementById("compass").style.transform = "rotate(" + heading + "deg)";
|
||||
document.getElementById("compass").style.transform = "translateY(-50%) rotate(" + heading + "deg)";
|
||||
},
|
||||
|
||||
handleErrorResponse: function (error) {
|
||||
@ -867,7 +867,7 @@
|
||||
Game.rewriteGoogleLink();
|
||||
|
||||
|
||||
const heading = Game.panorama.getPov().heading;
|
||||
document.getElementById("compass").style.transform = "rotate(" + heading + "deg)";
|
||||
document.getElementById("compass").style.transform = "translateY(-50%) rotate(" + heading + "deg)";
|
||||
});
|
||||
|
||||
if (COOKIES_CONSENT) {
|
||||
|
@ -60,12 +60,12 @@
|
||||
</div>
|
||||
</div>
|
||||
<div id="navigation">
|
||||
<div id="compass" class="navigationItem">
|
||||
<div class="navigationItem">
|
||||
<span>
|
||||
<img src="<?= $_ENV['STATIC_ROOT'] ?>/img/circle_background.svg?rev=<?= REVISION ?>" alt="Circle Background" class="circleBackground" />
|
||||
bence
commented
So I meant here that this should have the id: It is not a practical issue but for me it seems to be better if not the whole parent div rotates. So I meant [here](https://gitea.e5tv.hu/esoko/mapguesser/pulls/27/files#issuecomment-201) that this should have the id: `<img id="compass" ...`
It is not a practical issue but for me it seems to be better if not the whole parent div rotates.
|
||||
</span>
|
||||
<span>
|
||||
<img src="<?= $_ENV['STATIC_ROOT'] ?>/img/compass.svg?rev=<?= REVISION ?>" alt="compass icon" class="navigationIcon" />
|
||||
<img id="compass" src="<?= $_ENV['STATIC_ROOT'] ?>/img/compass.svg?rev=<?= REVISION ?>" alt="compass icon" class="navigationIcon" />
|
||||
</span>
|
||||
</div>
|
||||
<div id="returnToStart" class="navigationItem">
|
||||
|
Loading…
Reference in New Issue
Block a user
I would give the id
compass
to the compassimg
itself so only the compass graphic would rotate. But then this line should look like this to keep the default translate of the image: