WesPets

Discussion and development of scenarios and campaigns for the game.

Moderator: Forum Moderators

User avatar
Gambit
Loose Screw
Posts: 3266
Joined: August 13th, 2008, 3:00 pm
Location: Dynamica
Contact:

WesPets

Post by Gambit »

Some additional information.
Original idea
http://www.wesnoth.org/forum/viewtopic.php?f=12&t=25869
Coding questions and a bit of fleshing on the concept
http://www.wesnoth.org/forum/viewtopic.php?f=21&t=26195


This is primarily a pet raising game with a bit of rpg. Think of it as tamagachi for wesnoth.

There is only one map so far and that is the single player one. It is about half done. Basically its a world filled with little dragons. You have your own little dragon. You start at a place called the Nexus. It has 6 arms. 4 of them lead to the outside world in 4 different regions (grassland, arctic, badlands, desert). One leads to the breeding caves. The other leads to the lab.
There are 2 ways to get exp for your little dragon. But killing other dragons or by eating flowers that grow in the forests.

This is where it gets interesting. There are 29 other dragons of all different colors. The colors are randomly generated each game. It could be any html color that there is. When you find a dragon that has a shade you like you can right click on it and click "Steal Color". Then right click on your dragon and choose paint.

You can also befriend other dragons (Right click and choose bribe) so that they won't attack you. After they're befriended you can get them to join your pack.

Eventually your dragon will get very strong. But his experience meter will be very large. It will take a long time to level up. This is where the breeding caves come in. Teleport back to the nexus and head to the breeding caves. There are two nests here. Put a dragon you own on both nests and then click breed. A baby will be created back at the lab with a mixture of the parents traits. And it's exp will be reset to 4. So you get the strength, without the massive exp.

Eventually you'll get tired of raising your creature offline and will want to go to multiplayer. Right click on it and choose Code. This will give you a code. Write it down.

There will be a multiplayer map eventually that will be a battle arena. All four side will type in their codes to battle their creatures.

In single player you can also go down to the lab and choose Enter Code. You can use this to bring old creatures into your new world, or even share your code with friends.

Here is everything that is done so far. Consider this a beta.

Here are some sample codes to get you started:
20,4,4,0,Egarl,4,3,80,3,60,1,50,2,2cabed
25,8,54,29,Jermy,7,5,80,3,50,1,40,2,e2ba03
16,14,43,21,Mar,6,4,80,3,60,3,60,1,3b3821
25,9,12,10,Grelnick,5,3,80,3,50,1,40,2,9d1ad1


If you have any questions, comments, bugs, suggestions, or anything like that please post here :)
A little more information on colors. Mostly for the geeks:
Attachments
WesPets.zip
(25.34 KiB) Downloaded 305 times
Exasperation
Posts: 462
Joined: June 8th, 2006, 3:25 am

Re: WesPets

Post by Exasperation »

Suggestion: have a free movement mode when in the nexus - have a moveto event that resets your critter's move if a variable is set to 1, and set the variable to 1 when entering the nexus (and at the start of the scenario), and to 0 when leaving the nexus (although you could probably just leave it on in the lab/breeding caves).
User avatar
Gambit
Loose Screw
Posts: 3266
Joined: August 13th, 2008, 3:00 pm
Location: Dynamica
Contact:

Re: WesPets

Post by Gambit »

Breeding caves have a small exit to the outside world but yes I will do that for the nexus.
Exasperation
Posts: 462
Joined: June 8th, 2006, 3:25 am

Re: WesPets

Post by Exasperation »

What version of BfW is this intended for? I've tried it with 1.6.4 and 1.7.1 - in 1.6.4, attempting to breed a pair of critters causes a crash, and 1.7.1 just doesn't let me start a game with the scenario.
User avatar
Gambit
Loose Screw
Posts: 3266
Joined: August 13th, 2008, 3:00 pm
Location: Dynamica
Contact:

Re: WesPets

Post by Gambit »

Hmmm it was developed on 1.6.0a Windows Vista
No crashes here...

I just tried it on my 1.7.1 and it doesn't even show up on the map list...
It's not showing up for 1.7 because the cfg file was referencing a campaigns folder rather than an add-ons folder :)

But yeah its for 1.6 anyway. I don't deal with the dev version.
Also what kind of crash? A WML thing like unknown unit type or a C++ thing like an assertion or a magic voodoo thing like no error message period?
Exasperation
Posts: 462
Joined: June 8th, 2006, 3:25 am

Re: WesPets

Post by Exasperation »

Yeah, that's the same thing I got in 1.7.1. I started a new game in 1.6.4 - we'll see if the problem happens again.
User avatar
Gambit
Loose Screw
Posts: 3266
Joined: August 13th, 2008, 3:00 pm
Location: Dynamica
Contact:

Re: WesPets

Post by Gambit »

Alright. Use the copy command to quickly get over to the breeding caves.
It won't be there in the final game but it comes in massive handy for debugging :)

I'm going to go dl the latest stable to see if I can get the same crash. I probably won't be able to. Fran never crashes on me. Speaking of which... How are the AI turns on your computer? Is it too long with 29 teams? I know thats a problem for a lot of people but again I've got Fran so I don't notice...

That was one of the reasons I took it down from 200 AI to just 29. The AI turns were taking up to like 2 minutes and I knew that would be problematic for some.

Feedback I really need
1. How is the wait time on the AI turns?
2. Do you get attached enough to your little guy to actually bother with saving his code?
3. What would be the best way to go about giving income?
4. When you enter a friends code in the machine should it spawn on your team, or wild?
5. What kind of "mini-games" would you like to see for this? (Ideas so far are a race and a battle arena)
Exasperation
Posts: 462
Joined: June 8th, 2006, 3:25 am

Re: WesPets

Post by Exasperation »

Hmmm...this time, no crash - but I had made a small change in the code that I thought might fix it. So, if you also get the crash in 1.6.4, I already have a fix for you.

1) Wait time is a little long, but tolerable. I think that cutting back from 200 was probably a good idea, and putting in the free-move code in the nexus will cut down significantly on the number of turns where you don't really do anything between waits.
2) Not sure yet - my previous attempt crashed fairly early, so I haven't gotten a chance at getting attached.
3) Maybe have items that appear on mountains like flowers do in woods, and have a 'dig' command that uses up your critter's attack & moves to pick up the item for a random amount of gold? (You could even add a digging skill that affects how much you get.)
4) I would say that entering a code should give you a choice between spawning the creature wild, or paying a fixed amount (25, maybe?) to have it on your team.
5) I'll have to think about this.

I did have a thought about heredity - you could go with partial heredity on things like # of attacks and attack damage. It wouldn't really be more complicated then the current version, either. Just define something like this:

Code: Select all

#define HEREDITARY_NUMERIC_TRAIT TRAIT_NAME
	[if]
		[variable]
			name=p_2.{TRAIT_NAME}
			greater_than=p_1.{TRAIT_NAME}
		[/variable]
		[then]
			{VARIABLE_OP coded2.{TRAIT_NAME} rand $p_1.{TRAIT_NAME} $p_2.{TRAIT_NAME}}
		[/then]
		[else]
			{VARIABLE_OP coded2.{TRAIT_NAME} rand $p_2.{TRAIT_NAME} $p_1.{TRAIT_NAME}}
		[/else]
	[/if]
#enddef
and put calls to that macro for all the traits you wanted to do that way

Code: Select all

    {HEREDITARY_NUMERIC_TRAIT attack[0].damage}
    {HEREDITARY_NUMERIC_TRAIT attack[0].number}
User avatar
Gambit
Loose Screw
Posts: 3266
Joined: August 13th, 2008, 3:00 pm
Location: Dynamica
Contact:

Re: WesPets

Post by Gambit »

Having it check which is greater won't work for defense and movecosts. But I can just make another that works the other way. I'd like it to split the colors into Red Green and Blue again and then pick a random parent for each. Though I'm not sure I like the idea of getting the best of the both parents every time.
Exasperation
Posts: 462
Joined: June 8th, 2006, 3:25 am

Re: WesPets

Post by Exasperation »

The idea isn't to get the best of each parent every time, it's to generate a random number in the range defined by the two parents. So, if you had one parent with 7-5 attacks, and another with 10-3, you could get 8-4, or 9-3, or anything else from 7-3 to 10-5, instead of being limited to one of the extreme results.
Whoops...left out the .. in between the numbers. Silly me.

Code: Select all

#define HEREDITARY_NUMERIC_TRAIT TRAIT_NAME
   [if]
      [variable]
         name=p_2.{TRAIT_NAME}
         greater_than=p_1.{TRAIT_NAME}
      [/variable]
      [then]
         {VARIABLE_OP coded2.{TRAIT_NAME} rand $p_1.{TRAIT_NAME}|..$p_2.{TRAIT_NAME}}
      [/then]
      [else]
         {VARIABLE_OP coded2.{TRAIT_NAME} rand $p_2.{TRAIT_NAME}|..$p_1.{TRAIT_NAME}}
      [/else]
   [/if]
#enddef
That's better.
Blarumyrran
Art Contributor
Posts: 1700
Joined: December 7th, 2006, 8:08 pm

Re: WesPets

Post by Blarumyrran »

I gave it a brief try; i thought ooh, there is something vaguely resembling a hash at the end of the; but its not, its just color. Which means i can just have as many 2900,29,5,0,Murdjamustukene,590,3,10,1,10,1,f1dd04 dragons as i want because once youve seen one code, the meanings of the fields are obvious; which makes multiplayer silly. Like, who can type in the biggest numbers. If you want to have multiplayer that rewards the players for spening a lot of time in sp, you should add a hash of all the previous numbers (it doesnt feel like cheating if there is a right-click option that encourages it like that); but that kind of multiplayer would be inherently silly anyway.

Anyways. Not my kind of game, but it looks nice.
BigRed
Posts: 5
Joined: May 14th, 2009, 4:56 am

Re: WesPets

Post by BigRed »

Where do you extract the files in order for this to work?
User avatar
Gambit
Loose Screw
Posts: 3266
Joined: August 13th, 2008, 3:00 pm
Location: Dynamica
Contact:

Re: WesPets

Post by Gambit »

Syntax_Error wrote:I gave it a brief try; i thought ooh, there is something vaguely resembling a hash at the end of the; but its not, its just color. Which means i can just have as many 2900,29,5,0,Murdjamustukene,590,3,10,1,10,1,f1dd04 dragons as i want because once youve seen one code, the meanings of the fields are obvious; which makes multiplayer silly. Like, who can type in the biggest numbers. If you want to have multiplayer that rewards the players for spening a lot of time in sp, you should add a hash of all the previous numbers (it doesnt feel like cheating if there is a right-click option that encourages it like that); but that kind of multiplayer would be inherently silly anyway.

Anyways. Not my kind of game, but it looks nice.
I do plan to add some encryption :)
I'm open to suggestions there too btw. Preferably in a PM so that my encryption technique isn't visible to all forum readers :lol2:


Breeding does not crash for me. 1.6.4 Vista 64bit Fog and Shroud.
Exasperation
Posts: 462
Joined: June 8th, 2006, 3:25 am

Re: WesPets

Post by Exasperation »

I think I've figured it out - it looks like the breeding crash has to do with attempting to inherit a color from a parent that doesn't have a color mod.
User avatar
Gambit
Loose Screw
Posts: 3266
Joined: August 13th, 2008, 3:00 pm
Location: Dynamica
Contact:

Re: WesPets

Post by Gambit »

Elaborate please? They should all have color mods?
Post Reply