Aller au contenu

Photo

trying to get the player to not die after one 4 hp hit


  • Veuillez vous connecter pour répondre
13 réponses à ce sujet

#1
gordonbrown82

gordonbrown82
  • Members
  • 544 messages
i wonder how to set the player level in your module. the standard start thing seems to be a very weak player and i need to kill an enemy to see if a script is working!

#2
Taltherion

Taltherion
  • Members
  • 335 messages
When I got my module finally running, there was no character creation bit but a zero level char was standing at the start point of the module (I assume, I would have to add a script in the module properties to go through char-generation).



This lvl. 0 char has 0 stats - 0 strength, 0 dex etc and NO skills and talents.

#3
gordonbrown82

gordonbrown82
  • Members
  • 544 messages
do you know of any tutorial on how to do that?

#4
Taltherion

Taltherion
  • Members
  • 335 messages
maybe this here helps:



http://social.biowar...in_a_new_module

#5
Tikigod60

Tikigod60
  • Members
  • 48 messages
Why don't you replace the current monster with a much weaker one such as a lvl 1 rat with 1hp. And assign the script to that.



Kill the rat, and if the script works, then just change the monster back again



Otherwise won't you be jumping around constantly using differant types of characters each time you want to test a differant script that requires harder monsters?


#6
gordonbrown82

gordonbrown82
  • Members
  • 544 messages
i put a squirrel in the game Tikigod60 but he obliterated me with one punch.



here is a script



void main()

{

event ev = GetCurrentEvent();

int nEventType = GetEventType(ev);



switch(nEventType)

{

case EVENT_TYPE_MODULE_START

{

PreloadCharGen();

StartCharGen(GetHero(),0);



break;

}

}



}



not sure what header files to include and where the script is supposed to be loaded. any ideas?


#7
FalloutBoy

FalloutBoy
  • Members
  • 580 messages
Is there a way via script to add stats and levels to the player? If so you could make a Level Up lever. That would be much quicker than going through chargen every time you load.


#8
gordonbrown82

gordonbrown82
  • Members
  • 544 messages
true dat

#9
Suikoden

Suikoden
  • Members
  • 158 messages
put the chargen part of your script in the module_core script - add it under the caseeventmodulestart

part of module_core. Make sure you then use module_core as the main script for your module via managemodules -- Then switch your main characters script to the player_core script which is located in the core_scripts folder. This should give you a starting player with around 115hp at level 1.

#10
gordonbrown82

gordonbrown82
  • Members
  • 544 messages
i can't write in the module_core script. can i change that somehow?

#11
gordonbrown82

gordonbrown82
  • Members
  • 544 messages
i copied and pasted the core_script code into a new script and then added PreloadCharGen(); and

StartCharGen(GetHero(),0); to that one and then put that script in the module thing. i don't know how i assign the player_core script to the main character though.

#12
gordonbrown82

gordonbrown82
  • Members
  • 544 messages
it seemed to worked without changing the main character script.

#13
Tikigod60

Tikigod60
  • Members
  • 48 messages
Gordon, right click on 'Module_core script' in the viewer on the right and select 'check out'. You can then edit the contents of the script.

With that said what I did for my own stuff was the following:

After loading the toolset do the following:

Click on file.

Go to 'Manage Modules'.

Select your module and click 'Properties'.

Find the field 'Script'.

Click in the field to the right of it and click on the '...' button.

Select the script where you have the chargen call on module load.

Click ok.
------------

Works a treat for me so far and haven't encountered any unusual behaviour in my modules from not using module_core. *shrugs*

Guess I will find out once I start getting into combat and such, though I do have afew scripts I use on a case by case basis rather then having it all preloaded. :blush:

Modifié par Tikigod60, 29 novembre 2009 - 11:13 .


#14
gordonbrown82

gordonbrown82
  • Members
  • 544 messages
as long as it's functional.