Changin player graphic

All development conversation and discussion takes place here

Moderator: Moderator

Post Reply
Message
Author
Herojuana182
Posts: 1
Joined: Fri Apr 22, 2011 3:19 pm

Changin player graphic

#1 Post by Herojuana182 »

Hey there guys,

Stumbled accross this gem of an engine and have been playing around with various things.

one thing i cant seem to work out is to change the player graphic, ive messed with addind image= etc to descriptor/copy field
but this crashes the engine.

Any help would be awsome.

Cheers

Canderel
Sher'Tul
Posts: 1252
Joined: Mon Nov 24, 2003 2:31 pm
Location: South Africa

Re: Changin player graphic

#2 Post by Canderel »

t-engine4-windows-1.0.0beta25\game\modules\tome\data\birth\descriptors.lua lines 31-87 has how it's assigned:

Code: Select all

make_tile = function(e)
	e.image = "player/"..e.descriptor.subrace:lower().."_"..e.descriptor.sex:lower()..".png"
end,
Though I'd suggest examining that code more closely.

daftigod
Archmage
Posts: 300
Joined: Fri Feb 18, 2011 6:15 am

Re: Changin player graphic

#3 Post by daftigod »

depending on which tileset you are using, you can very easily add player tiles. if you are using the shockbolt tileset, they already exist!

load a player in ToME then go to the main menu -> graphic mode -> select style -> shockbolt. now you have player tiles.

then, take a look at t-engine\game\modules\tome\data\gfx\shockbolt\player\ within your OS

these are the file names you will need to work with (cornac_male.png, higher_female.png, etc.)

if you like, you can use that tileset and edit the png files to something of your tastes. if you want to use the default Mushroom tileset and add player tiles, you'll need to create a folder called "player" in the data\gfx\ dir since default player tiles don't exist. after that, you need to create new files according to the naming structure in the shockbolt/player/ dir. good luck!

Post Reply