equal
deleted
inserted
replaced
410 TeamNameEdit->setText(team.name()); |
410 TeamNameEdit->setText(team.name()); |
411 CBTeamLvl->setCurrentIndex(team.difficulty()); |
411 CBTeamLvl->setCurrentIndex(team.difficulty()); |
412 |
412 |
413 for(int i = 0; i < HEDGEHOGS_PER_TEAM; i++) |
413 for(int i = 0; i < HEDGEHOGS_PER_TEAM; i++) |
414 { |
414 { |
415 HWHog hh = team.hedgehog(i); |
415 HHNameEdit[i]->setText(team.hedgehogName(i)); |
416 |
416 |
417 HHNameEdit[i]->setText(hh.Name); |
417 QString hat = team.hedgehogHat(i); |
418 |
418 if (hat.startsWith("Reserved")) |
419 if (hh.Hat.startsWith("Reserved")) |
419 hat = "Reserved " + hat.mid(40); |
420 hh.Hat = "Reserved "+hh.Hat.remove(0,40); |
420 |
421 |
421 HHHats[i]->setCurrentIndex(HHHats[i]->findData(hat, Qt::DisplayRole)); |
422 HHHats[i]->setCurrentIndex(HHHats[i]->findData(hh.Hat, Qt::DisplayRole)); |
|
423 } |
422 } |
424 |
423 |
425 CBGrave->setCurrentIndex(CBGrave->findText(team.grave())); |
424 CBGrave->setCurrentIndex(CBGrave->findText(team.grave())); |
426 CBFlag->setCurrentIndex(CBFlag->findData(team.flag())); |
425 CBFlag->setCurrentIndex(CBFlag->findData(team.flag())); |
427 |
426 |
445 HWTeam team(TeamNameEdit->text()); |
444 HWTeam team(TeamNameEdit->text()); |
446 team.setDifficulty(CBTeamLvl->currentIndex()); |
445 team.setDifficulty(CBTeamLvl->currentIndex()); |
447 |
446 |
448 for(int i = 0; i < HEDGEHOGS_PER_TEAM; i++) |
447 for(int i = 0; i < HEDGEHOGS_PER_TEAM; i++) |
449 { |
448 { |
450 HWHog hh; |
449 QString hat = HHHats[i]->currentText(); |
451 hh.Name = HHNameEdit[i]->text(); |
450 |
452 hh.Hat = HHHats[i]->currentText(); |
451 if (hat.startsWith("Reserved")) |
453 |
452 hat = "Reserved" + m_playerHash + hat.mid(9); |
454 if (hh.Hat.startsWith("Reserved")) |
453 |
455 hh.Hat = "Reserved"+m_playerHash+hh.Hat.remove(0,9); |
454 team.setHedgehogName(i, HHNameEdit[i]->text()); |
456 |
455 team.setHedgehogHat(i, hat); |
457 team.setHedgehog(i,hh); |
|
458 } |
456 } |
459 |
457 |
460 team.setGrave(CBGrave->currentText()); |
458 team.setGrave(CBGrave->currentText()); |
461 team.setFort(CBFort->currentText()); |
459 team.setFort(CBFort->currentText()); |
462 team.setVoicepack(CBVoicepack->currentText()); |
460 team.setVoicepack(CBVoicepack->currentText()); |