add first targeted affect (ally)
This commit is contained in:
parent
3648b6ba16
commit
e9b81f7ea9
@ -29,8 +29,13 @@ func AddEffect(c *Card, e *Effect) {
|
||||
//can't apply effect to empty card
|
||||
return
|
||||
}
|
||||
if e.Target == uuid.Nil {
|
||||
log.Println("trying to apply targeted effect before target set")
|
||||
return
|
||||
}
|
||||
if c.Position < 0 || c.Position > 3 {
|
||||
log.Println("trying to apply effect to card not on the board")
|
||||
return
|
||||
}
|
||||
for _, v := range c.Effects {
|
||||
if v.Owner == e.Owner && v.ID == e.ID && v.Target == e.Target {
|
||||
|
Loading…
Reference in New Issue
Block a user