set map early when creating new events because some types need map info for defaults

This commit is contained in:
garak 2022-10-16 22:15:48 -04:00
parent c3a5e05f49
commit 33014830cd

View file

@ -2125,6 +2125,7 @@ DraggablePixmapItem *Editor::addNewEvent(Event::Type type) {
}
if (!event) return nullptr;
event->setMap(this->map);
event->setDefaultValues(this->project);
map->editHistory.push(new EventCreate(this, map, event));