Author
|
Topic: Changing Dink's graphics
|
Drakeman |
posted 03-16- 03:22 AM CT (US)
I've been trying out changing Dink's graphics... associated with an item. What I'm after is having one item that changes Dink, and let's him use other items in his new changed state.So I thought a global to tract if Dink is in his special state or not should do it, but then comes the question of loading the new graphics when you load a saved game. And since it seems that the arm() procedure of whatever item is &cur_weapon dictates the graphics I need to go into every item script and place the 'if' checking statement there. Kinda boring. There has to be a better way. I'm using a spawn command in arm() at the moment, which spawns the checking script and loads new graphics. Is there another more succinct way of doing this?
|
redink1
|
posted 03-16- 05:59 PM CT (US)
Probably not... but kind of :)If you're going to have normal saving (i.e. you save at a savebot), then you could modify savebot.c and do your checks and changes there to cover the load game question. Not sure if that helps with everything else tho... probably not. |
FF4LIFE
|
posted 03-17- 02:01 AM CT (US)
Ya, I just use the load button in the startup screen to spawn all my crap..god my game's gonna be horendous for people with slow comps..That would work to just check when you load... Uh...an if statement would work...but what it sounds like is some of your items just don't change your graphics, then what would it load when you start your game....bah, i suppose nothing unless you have those typical load the regular graphics stuff...which i should really go make sure i have..heh.. A quick question for you dinkers.. Since its a little more of a hassle in my game to change weapons (Hit S, click on the weapons box, select weapon) I'm thinking that i'll rip Diablo 2 yet again and have you select 2 weapons at once, then you have two in the first two slots of your inv and you can change between those two at normal. I was also thinking on a button that would do a quick switch between the two. Then you could have a bow and sword for instance...People like this idea? What should the switch key be?
I understand that a lot of people don't like my using many extra key...but to put it simply: bleh. Thats just the way my game is. And I plan on including a bat file that prompts you and asks you what key you would like assigned, then changes the names of the key files. So as of now, i have a button for: your status screen (s) using a belt item (b - potions scrolls and bombs) magic (as of now its /, but i'm trying to find a way to go back to shift...maybe alt) quick switch on magic ( < and > ) drop item (d) quick weapon switch ( something easy..who knows ) it seems overwhelming...but i think it won't be too bad... sorry for getting off topic and rambling :D |
Drakeman
|
posted 03-17- 02:18 AM CT (US)
Hmm I guess it's gonna be the item-scripts. It seems that the arm() procedure of the &cur_weapon is 'round about the last thing to load when a saved game is loaded.Mind you, there is the speed bug I had in SOB, which I should fix. Sometimes Dink would be sped up when he wasn't wearing the herb boots. Can't remember what caused that. As for all your keys, FF4... just do what you want to do. I defy anyone to make a dmod that pleases everyone completely. (Oh, I have a 'S' button for stats too. I was going to use a 'B' for boat - Dink goes sailing in Pilgrim's Quest - but have opted for it being an item which you can use only at a wharf. Hence my problem with graphics and loading...) I give myself another couple of months before I'm ready for beta testing, assuming I don't get busy at work again. ;-) |
redink1
|
posted 03-17- 06:43 AM CT (US)
FF4Life, putting anything in the Load wouldn't work. In order to tell when to load between the different graphics (i.e. between boat and Dink), you need access to the variables (&boat or what have you). However, you can only access the variables once you load the game. Yet when you load the game, it kills the load script. Hence, it be impossible. I've tried it dozens of times. And remember, you'd have to change it with the load button as well as the Escape menu.As for the Dink speed up bug, its caused when item-bt isn't disarmed (or dropped), and when the previous save game has a different weapon. An easy fix would be to edit start-2.c (if you use that format) and escape.c, adding in: set_dink_speed(3); sp_frame_delay(1, 0); whenever it right before it loads the game. |
redink1
|
posted 03-17- 06:44 AM CT (US)
Oh, and how does Dink fit a boat in his backpack? Is it one of those yellow inflatable ones? :) |
redink1
|
posted 03-17- 08:51 AM CT (US)
Almost forgot about dinfo.c. You use dinfo.c to load the game as well, so put the speed fix in there as well. |
Drakeman
|
posted 03-17- 03:38 PM CT (US)
The Boat is now at the wharf. Dink leaves it there and can come back to it later. ;-) He has an item of it in his backpack - sort of like an ownership title. Works fine as long as he can only get between 2 wharfs by sea and not land and sea.When does dinfo.c load? On Dink dieing or somewheres else? |
FF4LIFE
|
posted 03-18- 12:30 AM CT (US)
Dinfo.c is run when you die. I messed with it a lot, it was fun :)So ya, you can load there, from esc.c, and from the load button at start up. Redink, for my needs of doing stuff in the load button it does work because there's no variables, it just spawns a couple of scripts. And that speed bug in SoB was great! I had a saved game back when i had the boots, then whenever i'd start, i'd load that then load my current, and i'd be sped up :) |
Tyrsis
|
posted 03-19- 04:06 AM CT (US)
That speed bug is in every single DMod I've played :) |
FF4LIFE
|
posted 03-19- 05:43 PM CT (US)
Ya, like redink said, its not hard to fix at all. You can do the thing at the start, or you can put it in every items arm proc. Putting it at the start would be easier. |
joshriot
|
posted 04-05- 01:13 PM CT (US)
how is a new weapon armed when the boots wasnt dropped? |
FF4LIFE
|
posted 04-05- 09:10 PM CT (US)
You arm the boots, save it to slot 1 for example. Then you arm something else, save it to slot 2. Load game 1, you arm the boots, load game 2 you arm the sword or whatever, but the disarm proc of the boots was never run :D |