Nicotine and smoke system

Started by askiplop, June 15, 2010, 03:15:07 pm

Previous topic - Next topic

askiplop

Hi everyone!

I'm looking for an event system that will allow my player to smoke cigarette and get more addict if he smoke too much cigarette.

I found this topic : http://forum.chaos-project.com/index.php/topic,3667.0.html but no one published an event system for that...

I'm using RMVX by the way..

Anyone know where i can get a system like that?

Thank you very much ;)

WhiteRose

I've never used VX, but I could make an event system for you in XP, which would probably be simple enough to translate.

askiplop

Hi WhiteRose...

I purchased both XP and VX so if you want to create it under XP i can easily convert it for VX...

I'm hapy to see a person ready to help me, thank you very much! :)

I didnt say it, but the cigarette will be an item in the inventory, to smoke the cigarette, you need to go in the item menu...

Thank you very much, very nice from you ;)

(French canadian, sorry for mistakes...)

WhiteRose

June 17, 2010, 11:50:38 am #3 Last Edit: June 17, 2010, 11:51:44 am by WhiteRose
Alright, here's a demo with the event system:
http://www.mediafire.com/?0mjevjjjwmm

You can just copy the common events from the demo or see how I did it and make it yourself. If you copy them, make sure you modify which variables are used, as I'm guessing the variables I used in the demo (1 and 2) are probably already used in your game. You were a little vague on the specifications, so if you'd like anything changed, either you can do it or I can help you with that. One limitation to using events is that it only works if your game involves a single character. If your game uses a full party, the event system would have to do modified to the point where it would be easier to just write a script. Anyway, I hope this about covers it for you. Let me know if you have questions and I'll see what I can do to help.

askiplop

Thank you very much, ill try it as soon as RMXP is reinstalled, since a malware screwed up all my softwares this morning :(

askiplop

June 17, 2010, 09:38:00 pm #5 Last Edit: June 17, 2010, 11:22:31 pm by askiplop
Woww! Thanks a lot WhiteRose! I'm soo happy :P

Is it possible to show a bar at the bottom right of the screen showing the nicotine.. im explaining :

When you smoke a cigarette, the bar is 100% and drop with times... at 40% (exemple) a message say : You need a cigarette, or you will lost 25% of Spirit and Defense..
And if its near the 100% and you smoke another cigarette, it will stay at 100% but it will be based on the new value of nicotine not the one before... and at 45% (because the guy is more addicted) he lost 27% of SPI and DEF... for exemple..

I dont know if you understand (but i wish) and more the guy is addict more he lost stats points...

I wish you could help me or suggest me more features.. :plz:
:bow:
thanks a lot WhiteRose,
Have a nice evening!  

EDIT:
Sorry for double post  :shy:

WhiteRose

Quote from: askiplop on June 17, 2010, 09:38:00 pm
Woww! Thanks a lot WhiteRose! I'm soo happy :P

Is it possible to show a bar at the bottom right of the screen showing the nicotine.. im explaining :

When you smoke a cigarette, the bar is 100% and drop with times... at 40% (exemple) a message say : You need a cigarette, or you will lost 25% of Spirit and Defense..
And if its near the 100% and you smoke another cigarette, it will stay at 100% but it will be based on the new value of nicotine not the one before... and at 45% (because the guy is more addicted) he lost 27% of SPI and DEF... for exemple..

I dont know if you understand (but i wish) and more the guy is addict more he lost stats points...

I wish you could help me or suggest me more features.. :plz:
:bow:
thanks a lot WhiteRose,
Have a nice evening!  

EDIT:
Sorry for double post  :shy:

Alright, I understand what you're asking for. I'll be able to make it so the addiction affects stats like you say. As for the bar, that's not something that can be done via events, but it should be very easy for scripting. I might be able to code something for you. In the meantime, I'll finish the event system the way you want it. It'll probably be a few days, though; I'm a little busy tomorrow.

askiplop

Thanks for your reply, its okay if your busy, take your time, at least someone (you) is making it :)

when i want to show a bar, i use "show picture" in event... loll

Thank you very much and dont forget me please :)

Thanks again ;)

WhiteRose

June 18, 2010, 11:47:33 pm #8 Last Edit: June 19, 2010, 10:43:53 am by WhiteRose
Here's the latest version:
http://www.mediafire.com/?wgzy3djcte1

In this version, cigarette withdrawl affects stats instead of killing you. Also, the more you smoke, the stronger your addiction becomes, so you'll need to smoke more in order to maintain your status. Right now, there's no way to get over your addiction, because you didn't request it, but I can add it if you'd like. There's also no bar at the moment; I didn't have time to try and make one yet.

EDIT: I forgot to mention, I haven't done much debugging on this version, so there might be an error or two. Unlikely, but there's a chance.

askiplop

Thanks WhiteRose, for this demo and your suggestion..! You can add any features you'll like if you want and if you have the time.

For the bar, its okay im dont need it right now its just cause i want to deploy this in my game and include it soon.

Thanks a lot for all your suggestions and your work, i'll vcretid you for sure in my game ;)

Have a nice day!
PS: sorry i was working from thursday to sunday :S

ForeverZer0

you should make it for smoking crack. :naughty:
I am done scripting for RMXP. I will likely not offer support for even my own scripts anymore, but feel free to ask on the forum, there are plenty of other talented scripters that can help you.

askiplop

@ForeverZero  :
Yeah right! LOL