mirror of
https://github.com/overte-org/overte.git
synced 2025-08-19 23:24:48 +02:00
Update gridTool to not use clone
This commit is contained in:
parent
135c8c1bdf
commit
55f41eb452
1 changed files with 1 additions and 12 deletions
|
@ -292,7 +292,6 @@ GridTool = function(opts) {
|
|||
];
|
||||
|
||||
// Add all overlays from spritesheet
|
||||
var baseOverlay = null;
|
||||
var x = 0;
|
||||
for (var i = 0; i < UI_SPRITE_LIST.length; i++) {
|
||||
var info = UI_SPRITE_LIST[i];
|
||||
|
@ -306,17 +305,7 @@ GridTool = function(opts) {
|
|||
visible: false,
|
||||
};
|
||||
|
||||
var overlay;
|
||||
if (baseOverlay == null) {
|
||||
overlay = Overlays.addOverlay("image", {
|
||||
imageURL: UI_URL,
|
||||
});
|
||||
baseOverlay = overlay;
|
||||
} else {
|
||||
overlay = Overlays.cloneOverlay(baseOverlay);
|
||||
}
|
||||
|
||||
Overlays.editOverlay(overlay, props);
|
||||
var overlay = Overlays.addOverlay("image", props);
|
||||
|
||||
addUIOverlay(info.name, overlay, x, 0, info.width, UI_HEIGHT);
|
||||
|
||||
|
|
Loading…
Reference in a new issue