*Author

Offline XenocidiusTopic starter

  • Legendary Member
  • ******
  • Posts: 2696
  • Reputation Power: 49
  • Xenocidius is towering like an Amethyst Dragon over their peers.Xenocidius is towering like an Amethyst Dragon over their peers.Xenocidius is towering like an Amethyst Dragon over their peers.Xenocidius is towering like an Amethyst Dragon over their peers.Xenocidius is towering like an Amethyst Dragon over their peers.Xenocidius is towering like an Amethyst Dragon over their peers.Xenocidius is towering like an Amethyst Dragon over their peers.Xenocidius is towering like an Amethyst Dragon over their peers.Xenocidius is towering like an Amethyst Dragon over their peers.
  • Fear the Darkness ...
  • Awards: Slice of Elements 3rd Birthday CakeFavorite Community Member of 2011Weekly Tournament WinnerWinner of Design a Competition Competition
Re: Game Coding Q&A https://elementscommunity.org/forum/index.php?topic=32442.msg410288#msg410288
« Reply #12 on: October 15, 2011, 01:00:24 pm »
AI questions: Miracle usage? Nightmare usage? Buff usage? Twin Universe usage?
Miracle usage:

It casts Miracle when:

Current health - damage monitor < 10 + (random number between 0 and 1)*12

0 is inclusive, 1 is not.

In other words, it may cast it when current health - damage monitor is anywhere from 11 to 21.

Current health - damage monitor could even be 10 without it casting, but this is very, VERY unlikely.
Nightmare uses this formula to get the score of a creature:

Score = ((cost + 0.2) / (amount of quanta player has in the quanta pool of the creature's cost + 1)) + 0.2 / (number of cards in player hand * number of cards in player hand * 5 + 1)

However, if the creature belongs to the AI and has the passive skill Obsession, its score automatically becomes 1.

So it will cast Nightmare on high-cost creatures, and will try to cast it on a creature costing quanta of which you have little. It also prefers to cast it when you have few cards in your hand. However, it will cast it on its Ghost of the Past regardless.

Blessing, Plate Armor, Heavy Armor, Quintessence, Chaos Power, Momentum and Twin Universe have the same sort of targeting. Note that all but Twin Universe will only ever be cast on the AI's own creature.

Each have different estimates. Estimates for Blessing, Plate Armor, Heavy Armor, Quintessence and Chaos Power is 3. Momentum is 1. Twin Universe is 0.

Targeting scores on the AI's creatures are as follows:

First the creature is given a skillscore. If the creature has any skill skillscore is 3, otherwise it is 0. However, if the creature has skill deja vu, devour or has 0 HP, skillscore is set to 10.

Then it uses this to determine the score:

Score = (current ATK + skillscore - turns frozen - turns delayed) / 10

However, score is set to 0 if the spell is Momentum and creature already has momentum, creature has skill hatch, or if the spell is Parallel Universe and the creature is a Chimera.

Parallel Universe also scans the player's creatures.

If creature has a skill, skillscore = 3. Other than that it is the same as the above formula:

Score = (current ATK + skillscore - turns frozen - turns delayed) / 10

So to summarize, buffs will be played on high ATK creatures, preferably with skills, and will give high priority to its creatures with deja vu, devour or with 0 HP.

How are you getting the answers to the questions?
The game source.
Don't cry because it's over, smile because it happened.

Offline bored_ninja777

  • Hero Member
  • *****
  • Posts: 1080
  • Reputation Power: 13
  • bored_ninja777 is taking their first peeks out of the Antlion's burrow.bored_ninja777 is taking their first peeks out of the Antlion's burrow.
Re: Game Coding Q&A https://elementscommunity.org/forum/index.php?topic=32442.msg410353#msg410353
« Reply #13 on: October 15, 2011, 03:26:10 pm »
how did you get the game source? I thought Zanz was only one with access to that?
~McPasty was here~

Offline Jenkar

  • Legendary Member
  • ******
  • Posts: 4199
  • Country: fr
  • Reputation Power: 58
  • Jenkar is truly a Titan, worthy of respect and acknowledgement.Jenkar is truly a Titan, worthy of respect and acknowledgement.Jenkar is truly a Titan, worthy of respect and acknowledgement.Jenkar is truly a Titan, worthy of respect and acknowledgement.Jenkar is truly a Titan, worthy of respect and acknowledgement.Jenkar is truly a Titan, worthy of respect and acknowledgement.Jenkar is truly a Titan, worthy of respect and acknowledgement.Jenkar is truly a Titan, worthy of respect and acknowledgement.Jenkar is truly a Titan, worthy of respect and acknowledgement.Jenkar is truly a Titan, worthy of respect and acknowledgement.Jenkar is truly a Titan, worthy of respect and acknowledgement.
  • Heart's made of shadows
  • Awards: Slice of Elements 8th Birthday CakeSlice of Elements 7th Birthday CakeChampionship League 2/2013 WinnerSlice of Elements 4th Birthday Cake6th Trials - Master of AirWinner of Revive the Archive 2!Slice of Elements 3rd Birthday CakeBeginners League 1/2012 WinnerWeekly Tournament Winner5th Trials - Master of AirAvatar of Patience - Winner of the 7 Heavenly Virtues Deck CompetitionBeginners League 3/2011 3rd PlaceC-C-C-Combo Maker Winner!
Re: Game Coding Q&A https://elementscommunity.org/forum/index.php?topic=32442.msg410418#msg410418
« Reply #14 on: October 15, 2011, 05:58:17 pm »
I've sent someone a more detailed explanation but I don't have the message anymore, maybe he can post it here if he recognize himself.
Enjoy frenchdom. Also, Miracle can't be spun by oracle x)

Salut, je voulais savoir si tu avais examiné la partie du code relative a l'oracle?
Non, pourquoi, tu veux savoir quelque chose de précis ?
Yup. D'aprés une petite étude que j'avais fais, on voyait pas la carte miracle apparaitre dans l'oracle, je voulais savoir si c'était juste une anomalie, ou un bug.
J’ai jeté un ptit coup d’oeil vite fait, alors y’a deux pool pour la carte de l’oracle :
pool 1
Code: [Select]
Abomination         
Acceleration         
Adrenaline           
Aether Pendulum     
Aether Pillar       
Aflatoxin           
Air Pendulum         
Amethyst Pillar     
Antimatter           
Antlion             
Anubis               
Arctic Squid         
Armagio             
Arsenic             
Ash Eater           
Azure Dragon         
Basilisk Blood       
Black Dragon         
Black Hole           
Blessing             
Blue Crawler         
Bone Dragon         
Bone Pillar         
Bone Wall           
Boneyard             
Burning Pillar       
Butterfly Effect     
Catapult             
Chaos Seed           
Chimera             
Chrysaora           
Cloak               
Cockatrice           
Colossal Dragon     
Crimson Dragon       
Crusader             
Dagger               
Dark Pendulum       
Death Pendulum       
Deathstalker         
Deflagration         
Deja Vu             
Devonian Dragon     
Devourer             
Dimensional Shield   
Discord             
Dissipation Shield   
Dragonfly           
Drain Life           
Druidic Staff       
Dune Scorpion       
Dusk Mantle         
Earth Pendulum       
Earthquake           
Emerald Dragon       
Emerald Pillar       
Emerald shield       
Empathic Bond       
Enchant Artifact     
Entropy Pendulum     
Eternity             
Fahrenheit           
Fallen Elf           
Fate Egg             
Fire Bolt           
Fire Pendulum       
Fire Shield         
Fire Spirit         
Firefly             
Firefly Queen       
Flesh Spider         
Flooding             
Flying Weapon       
Fog Shield           
Forest Scorpion     
Forest Spirit       
Fractal             
Freeze               
Gargoyle             
Ghost of the Past   
Gnome Rider         
Golden Dragon       
Golden Hourglass     
Graboid             
Graviton Fire Eater 
Graviton Mercenary   
Gravity Pendulum     
Gravity Pillar       
Gravity Pull         
Gravity Shield       
Guardian Angel       
Hammer               
Heal                 
Hematite Golem       
Holy Light           
Hope                 
Horned Frog         
Ice Bolt             
Ice Dragon           
Ice Shield           
Immolation           
Immortal             
Iridium Warden       
Lava Golem           
Life Pendulum       
Light Pendulum       
Light Pillar         
Lightning           
Liquid Shadow       
Lobotomizer         
Luciferin           
Lycanthrope         
Maxwell's Demon     
Mind Flayer         
Mindgate             
Minor Vampire       
Mitosis             
Momentum             
Morning Star         
Mummy               
Mutation             
Nightfall           
Nightmare           
Nova                 
Nymph's Tears       
Obsidian Pillar     
Otyugh               
Owl's Eye           
Pandemonium         
Parallel Universe   
Parasite             
Pegasus             
Pharaoh             
Phase Dragon         
Phase Spider         
Phoenix             
Photon               
Plague               
Plate Armor         
Poison               
Precognition         
Procrastination     
Pulverizer           
Purify               
Purple Dragon       
Quantum Pillar       
Quintessence         
Rage Potion         
Rain of fire         
Reflective Shield   
Reverse Time         
Rustler             
Sanctuary           
Sapphire Charger     
Scarab               
Schrödinger's Cat   
Shield               
Shockwave           
Short Bow           
Short Sword         
Shrieker             
Silence             
Skeleton             
Skull Shield         
Sky Blitz           
Solar Shield         
Soul Catcher         
Spark               
Steal               
Steam Machine       
Stone Dragon         
Stone Pillar         
Stone skin           
Sundial             
Thorn Carapace       
Thuderstorm         
Time Factory         
Time Pendulum       
Titan               
Titanium Shield     
Toadfish             
Trident             
Unstable Gas         
Vampire Stiletto     
Virus               
Voodoo Doll         
Vulture             
Water Pendulum       
Water Pillar         
Wind Pillar         
Wings               
Wyrm                 
pool 2
Code: [Select]
Amber Nymph     
Auburn Nymph     
Black Nymph     
Blue Nymph       
Golden Nymph     
Green Nymph     
Grey Nymph       
Light Nymph     
Nymph Queen     
Purple Nymph     
Red Nymph       
Turquoise Nymph 
Une carte est tirée au sort parmi les 2 pools réunis. Si elle fait partie de la pool 2 (c’est une nymphe) alors on a 50% chances de retirer une carte au hasard, ensuite on garde la carte quelle qu’elle soit.
Si la carte est une nymphe (pool 2), alors on la gagne sinon on a 10% chances de la gagner.
En gros y’a 3.1 % chances de gagner une nymphe et 9.7 % chances de gagner une autre carte.

Et pour répondre à ta question, non il n’y a pas de miracle ^^.
The madness is in each of us. Close your eyes, sing, and open your webbed wings to the silent winds.
Beautiful art : http://i.imgur.com/eUhyYCC.png

Offline XenocidiusTopic starter

  • Legendary Member
  • ******
  • Posts: 2696
  • Reputation Power: 49
  • Xenocidius is towering like an Amethyst Dragon over their peers.Xenocidius is towering like an Amethyst Dragon over their peers.Xenocidius is towering like an Amethyst Dragon over their peers.Xenocidius is towering like an Amethyst Dragon over their peers.Xenocidius is towering like an Amethyst Dragon over their peers.Xenocidius is towering like an Amethyst Dragon over their peers.Xenocidius is towering like an Amethyst Dragon over their peers.Xenocidius is towering like an Amethyst Dragon over their peers.Xenocidius is towering like an Amethyst Dragon over their peers.
  • Fear the Darkness ...
  • Awards: Slice of Elements 3rd Birthday CakeFavorite Community Member of 2011Weekly Tournament WinnerWinner of Design a Competition Competition
Re: Game Coding Q&A https://elementscommunity.org/forum/index.php?topic=32442.msg410619#msg410619
« Reply #15 on: October 15, 2011, 11:11:10 pm »
Yep, I can confirm that Miracle is indeed missing from the Oracle card list. Thankfully, it's an easy bug to fix.

how did you get the game source? I thought Zanz was only one with access to that?
SWF decompilation.
Don't cry because it's over, smile because it happened.

Offline nerd1

  • Hero Member
  • *****
  • Posts: 1137
  • Country: us
  • Reputation Power: 15
  • nerd1 is a Blue Crawler starting to think about his first run.nerd1 is a Blue Crawler starting to think about his first run.nerd1 is a Blue Crawler starting to think about his first run.
  • kind of active
Re: Game Coding Q&A https://elementscommunity.org/forum/index.php?topic=32442.msg410645#msg410645
« Reply #16 on: October 15, 2011, 11:54:57 pm »
Yep, I can confirm that Miracle is indeed missing from the Oracle card list. Thankfully, it's an easy bug to fix.

how did you get the game source? I thought Zanz was only one with access to that?
SWF decompilation.
can you copy/paste the code onto a text file so others can see it? (make sure to make some fairly innocuous edits that totally kill the game so people cant just steal it)
The laziest elements player this side of one thousand posts.

Offline XenocidiusTopic starter

  • Legendary Member
  • ******
  • Posts: 2696
  • Reputation Power: 49
  • Xenocidius is towering like an Amethyst Dragon over their peers.Xenocidius is towering like an Amethyst Dragon over their peers.Xenocidius is towering like an Amethyst Dragon over their peers.Xenocidius is towering like an Amethyst Dragon over their peers.Xenocidius is towering like an Amethyst Dragon over their peers.Xenocidius is towering like an Amethyst Dragon over their peers.Xenocidius is towering like an Amethyst Dragon over their peers.Xenocidius is towering like an Amethyst Dragon over their peers.Xenocidius is towering like an Amethyst Dragon over their peers.
  • Fear the Darkness ...
  • Awards: Slice of Elements 3rd Birthday CakeFavorite Community Member of 2011Weekly Tournament WinnerWinner of Design a Competition Competition
Re: Game Coding Q&A https://elementscommunity.org/forum/index.php?topic=32442.msg410653#msg410653
« Reply #17 on: October 16, 2011, 12:18:55 am »
No. That would be a massive security breach as you pointed out, even with innocuous edits. The code is also almost 30000 lines long and uncommented, and of no use to most people.

What I will do though is rewrite chriskang's sandbox (http://elementsthegame.wikia.com/wiki/User:Chriskang/Sandbox/10) on the new Wiki. That should satiate the curiosity of anyone who's interested.

We're getting off-topic, though. Back to the questions.
Don't cry because it's over, smile because it happened.

Offline BluePriest

  • Legendary Member
  • ******
  • Posts: 3771
  • Reputation Power: 46
  • BluePriest is towering like an Amethyst Dragon over their peers.BluePriest is towering like an Amethyst Dragon over their peers.BluePriest is towering like an Amethyst Dragon over their peers.BluePriest is towering like an Amethyst Dragon over their peers.BluePriest is towering like an Amethyst Dragon over their peers.BluePriest is towering like an Amethyst Dragon over their peers.BluePriest is towering like an Amethyst Dragon over their peers.BluePriest is towering like an Amethyst Dragon over their peers.BluePriest is towering like an Amethyst Dragon over their peers.
  • Entropy Has You
  • Awards: Slice of Elements 5th Birthday Cake
Re: Game Coding Q&A https://elementscommunity.org/forum/index.php?topic=32442.msg410686#msg410686
« Reply #18 on: October 16, 2011, 01:20:38 am »
what cards can NOT be optained through SoSe
This sig was interrupted by Joe Biden

Offline Jenkar

  • Legendary Member
  • ******
  • Posts: 4199
  • Country: fr
  • Reputation Power: 58
  • Jenkar is truly a Titan, worthy of respect and acknowledgement.Jenkar is truly a Titan, worthy of respect and acknowledgement.Jenkar is truly a Titan, worthy of respect and acknowledgement.Jenkar is truly a Titan, worthy of respect and acknowledgement.Jenkar is truly a Titan, worthy of respect and acknowledgement.Jenkar is truly a Titan, worthy of respect and acknowledgement.Jenkar is truly a Titan, worthy of respect and acknowledgement.Jenkar is truly a Titan, worthy of respect and acknowledgement.Jenkar is truly a Titan, worthy of respect and acknowledgement.Jenkar is truly a Titan, worthy of respect and acknowledgement.Jenkar is truly a Titan, worthy of respect and acknowledgement.
  • Heart's made of shadows
  • Awards: Slice of Elements 8th Birthday CakeSlice of Elements 7th Birthday CakeChampionship League 2/2013 WinnerSlice of Elements 4th Birthday Cake6th Trials - Master of AirWinner of Revive the Archive 2!Slice of Elements 3rd Birthday CakeBeginners League 1/2012 WinnerWeekly Tournament Winner5th Trials - Master of AirAvatar of Patience - Winner of the 7 Heavenly Virtues Deck CompetitionBeginners League 3/2011 3rd PlaceC-C-C-Combo Maker Winner!
Re: Game Coding Q&A https://elementscommunity.org/forum/index.php?topic=32442.msg410688#msg410688
« Reply #19 on: October 16, 2011, 01:26:47 am »
what cards can NOT be optained through SoSe
I would say that specific, large info should be either PMed or spoilered in first post. Prefferably earlier.
The madness is in each of us. Close your eyes, sing, and open your webbed wings to the silent winds.
Beautiful art : http://i.imgur.com/eUhyYCC.png

Offline bored_ninja777

  • Hero Member
  • *****
  • Posts: 1080
  • Reputation Power: 13
  • bored_ninja777 is taking their first peeks out of the Antlion's burrow.bored_ninja777 is taking their first peeks out of the Antlion's burrow.
Re: Game Coding Q&A https://elementscommunity.org/forum/index.php?topic=32442.msg410770#msg410770
« Reply #20 on: October 16, 2011, 04:00:35 am »
so you managed to get the source.. 30k lines or not anyone with some programming can pick it up.. Zanz is ok with you having his source code? and then you denying to display any just makes it more suspicious, saying it is a security breach.. If you got to it, what keeps others from doing the same and then abusing that. I can understand wanting to get information to help people in the forum etc with the code, but unless Zanz okays this and GAVE you access to it, I really dont see how this thread is even still unlocked..
~McPasty was here~

Offline BluePriest

  • Legendary Member
  • ******
  • Posts: 3771
  • Reputation Power: 46
  • BluePriest is towering like an Amethyst Dragon over their peers.BluePriest is towering like an Amethyst Dragon over their peers.BluePriest is towering like an Amethyst Dragon over their peers.BluePriest is towering like an Amethyst Dragon over their peers.BluePriest is towering like an Amethyst Dragon over their peers.BluePriest is towering like an Amethyst Dragon over their peers.BluePriest is towering like an Amethyst Dragon over their peers.BluePriest is towering like an Amethyst Dragon over their peers.BluePriest is towering like an Amethyst Dragon over their peers.
  • Entropy Has You
  • Awards: Slice of Elements 5th Birthday Cake
Re: Game Coding Q&A https://elementscommunity.org/forum/index.php?topic=32442.msg410775#msg410775
« Reply #21 on: October 16, 2011, 04:07:29 am »
so you managed to get the source.. 30k lines or not anyone with some programming can pick it up.. Zanz is ok with you having his source code? and then you denying to display any just makes it more suspicious, saying it is a security breach.. If you got to it, what keeps others from doing the same and then abusing that. I can understand wanting to get information to help people in the forum etc with the code, but unless Zanz okays this and GAVE you access to it, I really dont see how this thread is even still unlocked..
Anyone can use a program to decompile game code for flash games. Its not hard. If you think theres a problem then all you have to do is hit the report to moderator button, and if a moderator has a problem with this thread, then they will lock it.
This sig was interrupted by Joe Biden

Offline furballdn

  • Legendary Member
  • ******
  • Posts: 7573
  • Reputation Power: 86
  • furballdn is a mythical and divine giver of immortality, one of the Turquoise Nymphs.furballdn is a mythical and divine giver of immortality, one of the Turquoise Nymphs.furballdn is a mythical and divine giver of immortality, one of the Turquoise Nymphs.furballdn is a mythical and divine giver of immortality, one of the Turquoise Nymphs.furballdn is a mythical and divine giver of immortality, one of the Turquoise Nymphs.furballdn is a mythical and divine giver of immortality, one of the Turquoise Nymphs.furballdn is a mythical and divine giver of immortality, one of the Turquoise Nymphs.furballdn is a mythical and divine giver of immortality, one of the Turquoise Nymphs.furballdn is a mythical and divine giver of immortality, one of the Turquoise Nymphs.furballdn is a mythical and divine giver of immortality, one of the Turquoise Nymphs.furballdn is a mythical and divine giver of immortality, one of the Turquoise Nymphs.furballdn is a mythical and divine giver of immortality, one of the Turquoise Nymphs.furballdn is a mythical and divine giver of immortality, one of the Turquoise Nymphs.furballdn is a mythical and divine giver of immortality, one of the Turquoise Nymphs.furballdn is a mythical and divine giver of immortality, one of the Turquoise Nymphs.
  • Facetious trollnotmod
  • Awards: Epic 3 Card Winner - Clockwork GolemBest Recruiter of FriendsBest JournalistBest Chat PainterBattle - Slayer of The Great ChimeraBest Crafted Relic of Other
Re: Game Coding Q&A https://elementscommunity.org/forum/index.php?topic=32442.msg410778#msg410778
« Reply #22 on: October 16, 2011, 04:11:42 am »
What's the AI priority with permanents? I noticed the AI tends to hate my hourglass more than my arsenic more than my fog shield.

Offline XenocidiusTopic starter

  • Legendary Member
  • ******
  • Posts: 2696
  • Reputation Power: 49
  • Xenocidius is towering like an Amethyst Dragon over their peers.Xenocidius is towering like an Amethyst Dragon over their peers.Xenocidius is towering like an Amethyst Dragon over their peers.Xenocidius is towering like an Amethyst Dragon over their peers.Xenocidius is towering like an Amethyst Dragon over their peers.Xenocidius is towering like an Amethyst Dragon over their peers.Xenocidius is towering like an Amethyst Dragon over their peers.Xenocidius is towering like an Amethyst Dragon over their peers.Xenocidius is towering like an Amethyst Dragon over their peers.
  • Fear the Darkness ...
  • Awards: Slice of Elements 3rd Birthday CakeFavorite Community Member of 2011Weekly Tournament WinnerWinner of Design a Competition Competition
Re: Game Coding Q&A https://elementscommunity.org/forum/index.php?topic=32442.msg410780#msg410780
« Reply #23 on: October 16, 2011, 04:15:26 am »
What's the AI priority with permanents? I noticed the AI tends to hate my hourglass more than my arsenic more than my fog shield.
For permanents, this formula is used for score. Destroy and steal both have an estimate of -1.

Score = (permanent cost + 1)  * -estimate / 20

That means that the permanent with the highest cost will get targeted. If two permanents have the same cost the one with a lower slot number will be targeted.

so you managed to get the source.. 30k lines or not anyone with some programming can pick it up.. Zanz is ok with you having his source code? and then you denying to display any just makes it more suspicious, saying it is a security breach.. If you got to it, what keeps others from doing the same and then abusing that. I can understand wanting to get information to help people in the forum etc with the code, but unless Zanz okays this and GAVE you access to it, I really dont see how this thread is even still unlocked..
Correct, I'm using this information to help people. Suspicious? How? Chriskang told us everything he knew about the code back in the day, and zanz was okay with that. Any moderator is free to lock this, but I don't see why.

And I am going to display some code, in the form of a remade version of chriskang's sandbox, as I mentioned before.

'Massive security breach' was probably a poor choice of words, but making a game's source code publicly available like that isn't a great idea.
Don't cry because it's over, smile because it happened.

 

anything
blarg: